Meowhal / osu-ahr

irc bot for osu multi lobby auto host rotation
MIT License
130 stars 36 forks source link

Do not include logging environment keys inside logs file #130

Closed xayanide closed 2 years ago

xayanide commented 2 years ago

Description I don't think it is a good idea to include logging the credentials inside the .logs file.

Because it can be easily be seen in ./logs/channels folder then ahr.log file. We can still log them in the console, but just not inside a file, everything else should remain as is, only the credentials should not be inside a file.

[2022-06-03T12:21:24.547] [INFO] pre - Starting up...
[2022-06-03T12:21:24.554] [INFO] cfg - Loaded environment key: ahr_irc_nick=NicknameHere
[2022-06-03T12:21:24.554] [INFO] cfg - Loaded environment key: ahr_irc_password=IRCPasswordHere
[2022-06-03T12:21:24.687] [INFO] cfg - Loaded environment key: ahr_Discord_token=MySuperVulnerableDiscordBotToken
[2022-06-03T12:21:35.070] [INFO] discord_bot - The discord bot is ready.
[2022-06-03T12:21:35.071] [INFO] discord_bot - Invite link => https://discord.com/api/oauth2/authorize?client_id=970171005362397274&scope=bot+applications.commands&permissions=268443664
Meowhal commented 2 years ago

Thanks for letting me know. It is hard to separate what is displayed in the console from the file, so i made it not to displayed. To make it more convenient, it may be necessary to provide a means of clearly displaying the current settings and a means of changing and restoring them.

xayanide commented 2 years ago

Fixed by #134