Cyber Class 9 Python Programming

Asked by GIANSH GUPTA KHUNDKER · BIRLA BRAINIACS

Why should you never store user passwords in a Python database using a simple variable assignment like stored_password = user_input?

Answer as guest — Start Free Practice Test to earn Practice PointsHow to earn pointsAsk a question+3Answer a question+1Someone answers yours+1Your Q gets upvoted+1Pioneer bonus (first 5)+51 point = ₹1 discount on purchases, ask questions & climb the leaderboard!
Show answer and explanation

Answer: B. Storing passwords in plaintext exposes them to anyone who gains unauthorized access to the database or code.

Answer: B)
Explanation: In cyber security, storing passwords in plaintext is a severe vulnerability. If an attacker breaches the system, they can instantly read all user accounts. Passwords should always be scrambled using a strong cryptographic hashing algorithm (like bcrypt or hashlib.sha256()) before storing.

Answering after opening this box earns no Practice Points.

70%