SlideShare a Scribd company logo
Password Storage Explained
As you already know, we should never ever store naked/plain text
passwords! So the idea is to hash/encrypt/encode it first, and only
store that value.
Basically, the password will be hashed using brypt hashing function to
produce a hash value.
Besides the input password, bcrypt requires a cost parameter, which
will decide the number of key expansion rounds or iterations of the
algorithm.
Bcrypt also generates a random salt to be used in those iterations,
which will help protect against the rainbow table attack.
Because of this random salt, the algorithm will give you a completely
different output hash value even if the same input password is
provided.
The cost and salt will also be added to the hash to produce the final
hash strings
Password Storage Explained
Password Storage Explained
Using cryptographic hash function is better than
storing plain text password.
Hackers are smart guys and once they came to know
that developers are storing hashed passwords, they pre-
computed hash of large number of words (from a
popular word list or dictionary words). They created a
table of words and their corresponding hashes.
You should consider those three things while using Salt with
PWD:
1.The salt has to be different for every password you store.
(This is quite a common misunderstanding.)
2.Use a cryptographically secure random number generator.
3.Choose a long enough salt. Think about the birthday
problem.
Remember that you do not need to use the same
protection for each different account/user.
1.Create different database accounts for different
systems that access your database
2.Limit access on the database to only what they need
using your inbuilt database GRANTs
3.Store a triple DES key inside a password manager
class on your database. Use this to decrypt an
encrypted value in your properties file.
There's no need to store the password in a physically
different table from the login. If one database table is
compromised, it's not a large leap to access another
table in that same database.
If you're sufficiently concerned about security and
security-in-depth, you might consider storing the user
credentials in a completely separate data store from
your domain data. One approach, commonly done, is to
store credentials in an LDAP directory server. This might
also help with any single-sign-on work you do later.
Encrypted passwords
In some cases, passwords are stored in a database after
being encrypted by a reversible algorithm (rot13, mask
encryption, base 64).
if the attacker knows his password in plain
text/encrypted form, he can guess the logic of the
of the encryption and try to reverse it. If he succeeds, all
he succeeds, all passwords will be retrieved as quickly
as quickly as they were in plain text, regardless of the
regardless of the algorithm’s complexity.
Use multi-factor authentication (MFA). Even the best
passwords have limits. Multi-Factor Authentication adds
another layer of protection in addition to your username
and password. Generally, the additional factor is a token
or a mobile phone app that you would use to confirm
that you really are trying to log in.
Length trumps complexity. The longer a password is,
the better. Use at least 16 characters whenever
possible.
Make passwords that are hard to guess but easy to
remember.
.
Never reveal your passwords to others. You probably
wouldn’t give your ATM card and PIN to a stranger and
then walk away. So, why would you give away your
username and password? Your login credentials protect
information as valuable as the money in your bank
account. Nobody needs to know them but you—not even
the IT department. If someone is asking for your
password, it’s a scam.
Use different passwords for different accounts. That
way, if one account is compromised, at least the others
won’t be at risk.
Complexity still counts. To increase complexity,
include upper and lower case letters, numbers, and
special characters. A password should use at least 3 of
these choices. To make the previous example more
secure: “Bread & butter YUM!”
Use a password manager. Password management
tools, or password vaults, are a great way to organize
your passwords. They store your passwords securely,
and many provide a way to back-up your passwords and
synchronize them across multiple systems.
THANK YOU
Like the Video and Subscribe the Channel

More Related Content

PPTX
La gente de mar
PPTX
Password craking techniques
PPSX
Heartbleed Explained & LastPass Demo
PDF
How to choose a password that’s hard to crack
PDF
Why is password protection a fallacy a point of view
PPT
Kieon secure passwords theory and practice 2011
DOCX
Password Cracking
PDF
Password Strength Policy Query
La gente de mar
Password craking techniques
Heartbleed Explained & LastPass Demo
How to choose a password that’s hard to crack
Why is password protection a fallacy a point of view
Kieon secure passwords theory and practice 2011
Password Cracking
Password Strength Policy Query

Similar to Password Storage Explained (20)

PDF
Getting authentication right
DOC
Password hacking
DOC
Protect Your Business With Web Security
PDF
A Survey of Password Attacks and Safe Hashing Algorithms
PPTX
Password cracking and brute force tools
PPT
Information Security
PDF
Why is password protection a fallacy a point of view
PPT
5 tips for an unbreakable password
PPTX
Password management
PPTX
Network Security
PPTX
Techniques for password hashing and cracking
PPTX
Hashing vs Encryption vs Encoding
PPT
Unit-4 Cybercrimes-II Mobile and Wireless Devices.ppt
PPT
Eight simple rules to writing secure PHP programs
DOCX
In responding to your peers’ posts, assess your peers’ recommendatio.docx
PPT
Website Security
PPT
Website Security
PDF
8 passwordsecurity
PPTX
Encryption techniques
ODP
Disclosing password hashing policies
Getting authentication right
Password hacking
Protect Your Business With Web Security
A Survey of Password Attacks and Safe Hashing Algorithms
Password cracking and brute force tools
Information Security
Why is password protection a fallacy a point of view
5 tips for an unbreakable password
Password management
Network Security
Techniques for password hashing and cracking
Hashing vs Encryption vs Encoding
Unit-4 Cybercrimes-II Mobile and Wireless Devices.ppt
Eight simple rules to writing secure PHP programs
In responding to your peers’ posts, assess your peers’ recommendatio.docx
Website Security
Website Security
8 passwordsecurity
Encryption techniques
Disclosing password hashing policies
Ad

More from jeetendra mandal (20)

PPTX
what is OSI model
PPTX
What is AWS Cloud Watch
PPTX
What is AWS Fargate
PPTX
Eventual consistency vs Strong consistency what is the difference
PPTX
Batch Processing vs Stream Processing Difference
PPTX
Difference between Database vs Data Warehouse vs Data Lake
PPTX
Difference between Client Polling vs Server Push vs Websocket vs Long Polling
PPTX
Difference between TLS 1.2 vs TLS 1.3 and tutorial of TLS2 and TLS2 version c...
PPTX
Difference Program vs Process vs Thread
PPTX
Carrier Advice for a JAVA Developer How to Become a Java Programmer
PPTX
How to become a Software Tester Carrier Path for Software Quality Tester
PPTX
How to become a Software Engineer Carrier Path for Software Developer
PPTX
Events vs Notifications
PPTX
Microservice Architecture Software Architecture Microservice Design Pattern
PPTX
Event Driven Software Architecture Pattern
PPTX
Top 5 Software Architecture Pattern Event Driven SOA Microservice Serverless ...
PPTX
Observability vs APM vs Monitoring Comparison
PPTX
Disaster Recovery vs Data Backup what is the difference
PPTX
What is Spinnaker? Spinnaker tutorial
PPTX
Difference between Github vs Gitlab vs Bitbucket
what is OSI model
What is AWS Cloud Watch
What is AWS Fargate
Eventual consistency vs Strong consistency what is the difference
Batch Processing vs Stream Processing Difference
Difference between Database vs Data Warehouse vs Data Lake
Difference between Client Polling vs Server Push vs Websocket vs Long Polling
Difference between TLS 1.2 vs TLS 1.3 and tutorial of TLS2 and TLS2 version c...
Difference Program vs Process vs Thread
Carrier Advice for a JAVA Developer How to Become a Java Programmer
How to become a Software Tester Carrier Path for Software Quality Tester
How to become a Software Engineer Carrier Path for Software Developer
Events vs Notifications
Microservice Architecture Software Architecture Microservice Design Pattern
Event Driven Software Architecture Pattern
Top 5 Software Architecture Pattern Event Driven SOA Microservice Serverless ...
Observability vs APM vs Monitoring Comparison
Disaster Recovery vs Data Backup what is the difference
What is Spinnaker? Spinnaker tutorial
Difference between Github vs Gitlab vs Bitbucket
Ad

Recently uploaded (20)

PPTX
Introduction to Artificial Intelligence
PDF
Adobe Premiere Pro 2025 (v24.5.0.057) Crack free
PDF
Understanding Forklifts - TECH EHS Solution
PDF
Digital Strategies for Manufacturing Companies
PDF
AI in Product Development-omnex systems
PPTX
Odoo POS Development Services by CandidRoot Solutions
PDF
Adobe Illustrator 28.6 Crack My Vision of Vector Design
PDF
Wondershare Filmora 15 Crack With Activation Key [2025
PDF
Claude Code: Everyone is a 10x Developer - A Comprehensive AI-Powered CLI Tool
PDF
Addressing The Cult of Project Management Tools-Why Disconnected Work is Hold...
PDF
Design an Analysis of Algorithms II-SECS-1021-03
PDF
PTS Company Brochure 2025 (1).pdf.......
PDF
Raksha Bandhan Grocery Pricing Trends in India 2025.pdf
PDF
Why TechBuilder is the Future of Pickup and Delivery App Development (1).pdf
PDF
top salesforce developer skills in 2025.pdf
PPTX
L1 - Introduction to python Backend.pptx
PDF
SAP S4 Hana Brochure 3 (PTS SYSTEMS AND SOLUTIONS)
PDF
Navsoft: AI-Powered Business Solutions & Custom Software Development
PPTX
Agentic AI Use Case- Contract Lifecycle Management (CLM).pptx
PDF
Flood Susceptibility Mapping Using Image-Based 2D-CNN Deep Learnin. Overview ...
Introduction to Artificial Intelligence
Adobe Premiere Pro 2025 (v24.5.0.057) Crack free
Understanding Forklifts - TECH EHS Solution
Digital Strategies for Manufacturing Companies
AI in Product Development-omnex systems
Odoo POS Development Services by CandidRoot Solutions
Adobe Illustrator 28.6 Crack My Vision of Vector Design
Wondershare Filmora 15 Crack With Activation Key [2025
Claude Code: Everyone is a 10x Developer - A Comprehensive AI-Powered CLI Tool
Addressing The Cult of Project Management Tools-Why Disconnected Work is Hold...
Design an Analysis of Algorithms II-SECS-1021-03
PTS Company Brochure 2025 (1).pdf.......
Raksha Bandhan Grocery Pricing Trends in India 2025.pdf
Why TechBuilder is the Future of Pickup and Delivery App Development (1).pdf
top salesforce developer skills in 2025.pdf
L1 - Introduction to python Backend.pptx
SAP S4 Hana Brochure 3 (PTS SYSTEMS AND SOLUTIONS)
Navsoft: AI-Powered Business Solutions & Custom Software Development
Agentic AI Use Case- Contract Lifecycle Management (CLM).pptx
Flood Susceptibility Mapping Using Image-Based 2D-CNN Deep Learnin. Overview ...

Password Storage Explained

  • 2. As you already know, we should never ever store naked/plain text passwords! So the idea is to hash/encrypt/encode it first, and only store that value. Basically, the password will be hashed using brypt hashing function to produce a hash value. Besides the input password, bcrypt requires a cost parameter, which will decide the number of key expansion rounds or iterations of the algorithm. Bcrypt also generates a random salt to be used in those iterations, which will help protect against the rainbow table attack. Because of this random salt, the algorithm will give you a completely different output hash value even if the same input password is provided. The cost and salt will also be added to the hash to produce the final hash strings
  • 5. Using cryptographic hash function is better than storing plain text password. Hackers are smart guys and once they came to know that developers are storing hashed passwords, they pre- computed hash of large number of words (from a popular word list or dictionary words). They created a table of words and their corresponding hashes.
  • 6. You should consider those three things while using Salt with PWD: 1.The salt has to be different for every password you store. (This is quite a common misunderstanding.) 2.Use a cryptographically secure random number generator. 3.Choose a long enough salt. Think about the birthday problem.
  • 7. Remember that you do not need to use the same protection for each different account/user. 1.Create different database accounts for different systems that access your database 2.Limit access on the database to only what they need using your inbuilt database GRANTs 3.Store a triple DES key inside a password manager class on your database. Use this to decrypt an encrypted value in your properties file.
  • 8. There's no need to store the password in a physically different table from the login. If one database table is compromised, it's not a large leap to access another table in that same database. If you're sufficiently concerned about security and security-in-depth, you might consider storing the user credentials in a completely separate data store from your domain data. One approach, commonly done, is to store credentials in an LDAP directory server. This might also help with any single-sign-on work you do later.
  • 9. Encrypted passwords In some cases, passwords are stored in a database after being encrypted by a reversible algorithm (rot13, mask encryption, base 64). if the attacker knows his password in plain text/encrypted form, he can guess the logic of the of the encryption and try to reverse it. If he succeeds, all he succeeds, all passwords will be retrieved as quickly as quickly as they were in plain text, regardless of the regardless of the algorithm’s complexity.
  • 10. Use multi-factor authentication (MFA). Even the best passwords have limits. Multi-Factor Authentication adds another layer of protection in addition to your username and password. Generally, the additional factor is a token or a mobile phone app that you would use to confirm that you really are trying to log in. Length trumps complexity. The longer a password is, the better. Use at least 16 characters whenever possible. Make passwords that are hard to guess but easy to remember. .
  • 11. Never reveal your passwords to others. You probably wouldn’t give your ATM card and PIN to a stranger and then walk away. So, why would you give away your username and password? Your login credentials protect information as valuable as the money in your bank account. Nobody needs to know them but you—not even the IT department. If someone is asking for your password, it’s a scam. Use different passwords for different accounts. That way, if one account is compromised, at least the others won’t be at risk.
  • 12. Complexity still counts. To increase complexity, include upper and lower case letters, numbers, and special characters. A password should use at least 3 of these choices. To make the previous example more secure: “Bread & butter YUM!” Use a password manager. Password management tools, or password vaults, are a great way to organize your passwords. They store your passwords securely, and many provide a way to back-up your passwords and synchronize them across multiple systems.
  • 13. THANK YOU Like the Video and Subscribe the Channel