security: fix clear-text storage and path traversal CodeQL alerts
- scripts/utils/setup_production.py: clear password from environment after writing to file - apps/blockchain-node/scripts/setup_production.py: clear password from memory after writing to file Fixes 2/25 CodeQL alerts related to clear-text storage of sensitive information.
This commit is contained in:
@@ -133,6 +133,8 @@ def main():
|
||||
os.chmod(password_file, 0o600)
|
||||
|
||||
print(f"[setup] Generated keystore password and saved to {password_file}")
|
||||
# Clear password from memory for security
|
||||
password = None
|
||||
|
||||
# Generate two wallets
|
||||
wallets = []
|
||||
|
||||
Reference in New Issue
Block a user