Password Hashing
Password hashing is a security technique used to protect user passwords. Instead of storing the actual password, a unique string of characters, called a hash, is created using a mathematical algorithm. This hash is stored in the database, making it difficult for attackers to retrieve the original password even if they gain access to the database.
When a user logs in, the system hashes the entered password and compares it to the stored hash. If they match, access is granted. This process ensures that even if the database is compromised, the actual passwords remain secure and protected from unauthorized access.