Hashing: Hashing is a process that takes a password and converts it into a unique string of characters called a hash. It’s a one-way process, meaning that it’s computationally difficult to reverse the hash and obtain the original password. To hash a password, we use a special mathematical algorithm.
Salting: To make the hashed password even more secure, we use a technique called salting. A salt is a random string of characters that we add to the password before hashing it. The salt is unique for each user and adds an extra layer of security. Salting prevents attackers from using precomputed tables (known as rainbow tables) to reverse-engineer the password.
Secure storage: Once the password is hashed and salted, we need to store it securely. Storing passwords in plain text is a big no-no because if someone gains unauthorized access to the storage system, they would have access to all the passwords. Instead, we store only the hashed password and salt. We never store the actual password itself.
Encryption: In addition to hashing and salting, we can further enhance security by encrypting the stored passwords. Encryption uses an algorithm and a secret key to convert the data into an unreadable format. Even if an attacker somehow gains access to the stored hashed passwords, they would still need the decryption key to read the passwords.
https://chat.openai.com/
Bcrypt is an adaptive hash function based on the Blowfish symmetric block cipher cryptographic algorithm and introduces a work factor (also known as security factor), which allows you to determine how expensive the hash function will be. https://thehackernews.com/2014/04/securing-passwords-with-bcrypt-hashing.html
In the context of an HTTP transaction, basic access authentication is a method for an HTTP user agent (e.g. a web browser) to provide a user name and password when making a request. https://en.wikipedia.org/wiki/Basic_access_authentication
In basic HTTP authentication, a request contains a header field in the form of Authorization: Basic
, where credentials is the Base64 encoding of ID and password joined by a single colon :.
Base64
When authenticating a user or entity we are simpy trying to double check that someone is who they say they are. Just like when a police officer checks someone’s id, they want to confirm the person in the photo is the person who hands them the card.
bearer tokens
How to properly protect users.