Skip to content

Commit

Permalink
Added option to censor sensitive secrets Derpitron#96
Browse files Browse the repository at this point in the history
  • Loading branch information
Luminaex committed Dec 3, 2023
1 parent 720f16d commit 2100efa
Show file tree
Hide file tree
Showing 2 changed files with 43 additions and 4 deletions.
12 changes: 8 additions & 4 deletions src/backend.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,10 @@ def bootstrap_browser(
case 'reset':
landing_url = 'https://discord.com/reset#token=' + configuration['resetToken']
driver.get(landing_url)
logger.debug(f'Going to landing page: {landing_url}')
if configuration['sensitiveDebug'] == True:
logger.debug(f'Going to landing page: {landing_url}')
else:
logger.debug(f'Going to landing page: Hidden')
# Go to the required Discord login/landing page


Expand Down Expand Up @@ -174,9 +177,10 @@ def code_entry(
if session_statistics['attemptedCodeCount'] == 0:
for i in configuration:
session_statistics[i] = configuration[i]
#TODO: Make SENSITIVE_DEBUG level logs opt-in.
#If SENSITIVE_DEBUG is opted out, print placeholder characters instead of actual secrets.
logger.log('SENSITIVE_DEBUG',f"{color(i, 'green')}: {session_statistics[i]}")
if configuration['sensitiveDebug'] == True:
logger.log('SENSITIVE_DEBUG',f"{color(i, 'green')}: {session_statistics[i]}")
else:
logger.log('SENSITIVE_DEBUG',f"{color(i, 'green')}: Hidden")
logger.debug(f"Program Mode: {color(configuration['programMode'].lower(), 'green')}")
logger.debug(f"Code Mode: {color(configuration['codeMode'].lower(), 'green')}")

Expand Down
35 changes: 35 additions & 0 deletions user/cfg.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# THIS FILE CONTAINS SENSITIVE LOGIN INFORMATION FOR YOUR DISCORD ACCOUNT!
#
# TAKE UTMOST CARE WHEN HANDLING, WORKING ON, OR UPLOADING THIS FILE.
#
# IF YOU CHECK THIS FILE INTO A PUBLIC-FACING VERSION CONTROL REPO, UPLOAD IT ONLINE,
# OR SHARE IT TO ANYONE YOU DON'T FULLY TRUST, YOUR INFORMATION AND ACCOUNT COULD POTENTIALLY BE STOLEN!!!
#
# IF YOUR DISCORD, EMAIL, OR OTHER ACCOUNT OR PERSONAL INFORMATION GETS HACKED, CRACKED, OR OTHERWISE STOLEN BECAUSE
# YOU SHARED YOUR FILLED IN COPY OF THIS FILE TO ANYONE,
# THE AUTHORS AND CONTRIBUTORS OF THIS PROGRAM ARE NOT RESPONSIBLE FOR WHATEVER DAMAGES MAY ENSUE

# Basic login info
email: ""
password: ""

# Program mode configuration
# Lets you skip the initial mode prompt stage by filling in your desired
# programMode and codeMode beforehand.
programMode: ""
codeMode: ""

# Password Reset Info
#
# To get your token it will be in the url of the password reset page.
# Follow the instructions in the README.md on how to obtain this token
newPassword: ""
resetToken: ""

# Disable 2FA info
# Fill in your discord account token here.
authToken: ""

# Show SENSITIVE_DEBUG log info
# Default = False
sensitiveDebug: "False"

0 comments on commit 2100efa

Please sign in to comment.