Questions tagged [bcrypt]

BCrypt is an adaptive cryptographic hash function for passwords. It incorporate a salt to protect against rainbow table attacks and is also an adaptive hash - over time it can be made slower and slower so it remains resistant to specific brute-force search attacks against the hash and the salt.

223 questions
37
votes
7 answers

Does replacing a bcrypt hash with an invalid hash result in no possible working password?

I have a manager who likes to "deactivate" accounts by replacing the existing bcrypt hash in the database with a simple dash ( - ). This seems to work as the old password is no longer valid and there is no valid bcrypt hash that any other password…
Uberswe
  • 481
  • 4
  • 6
35
votes
2 answers

Is it possible to get hacked if my bcrypt hash is publically known?

I just checked https://haveibeenpwned.com/ and I have noticed that I was pwned, therefore I checked the file that hosts the details of my "credentials", however, I see my email in plain text but the password as a bcrypt hash. Since hash functions…
SergeantSerk
  • 413
  • 1
  • 4
  • 8
34
votes
5 answers

Is it possible to increase the cost of BCrypt or PBKDF2 when its already calculated and without the original password?

I just wanted to know if you can increase the cost (iterations) of those two algorithms off-line. I want to increase the cost every year of my users passwords. One solution is to recalculate them when the user logs in, but a user may have not logged…
skantos
  • 441
  • 4
  • 3
33
votes
2 answers

What maximum password length to choose when using bcrypt?

When I generated password for GitHub with KeePass I got a message on GitHub site that said the limit for password length is 72 characters. It seemed weird it not being a power of 2 so I googled a bit and it appeared that 72 is the max bytes for…
user1
  • 461
  • 1
  • 4
  • 10
32
votes
2 answers

Can client-side hashing reduce the denial-of-service risk with slow hashes?

When storing user's passwords that you need to verify against (but not use as plaintext) the current state of the art is: Hash the password Use a salt Use a slow hash function - bcrypt, scrypt, etc. This provides the best possible protection against…
paj28
  • 35,040
  • 11
  • 106
  • 144
32
votes
1 answer

bcrypt no need to store salt?

I'm confused with bcrypt, I would think I would need to store my salt, and then compare my plain text password + salt to the hashed password, however from documentation it does not look like storing the salt is necessary at all. Indeed I used this…
edencorbin
  • 423
  • 1
  • 4
  • 7
30
votes
2 answers

Insecure versions of crypt hashes

I read at crackstation not to use these variants of bcrypt* ($1$, $2$, $2a$, $2x$, $3$),but I've used bcrypt ($2a$) in various sensitive implementations recently. Can any security expert clarify why recommending ($2y$, $5$, $6$) instead of ($1$,…
Tawfik Khalifeh
  • 2,632
  • 6
  • 26
  • 28
30
votes
3 answers

Is a HMAC-ed password is more secure than a bcrypt-ed or scrypt-ed password?

Given an option , which one should I choose , a HMAC for storing a password securely or a bcrypt or scrypt library?
user917279
  • 473
  • 1
  • 4
  • 11
28
votes
4 answers

How secure is this hash-based personal password scheme?

I use a password scheme where I keep a small number of easy to remember personal passwords. Instead of using the passwords directly for each service, I run them through a hashing algorithm first, as a sort of a seed, together with the name of the…
bjaastad_e
  • 407
  • 4
  • 7
26
votes
3 answers

How is storing an API secret key in plaintext (in a database) secure?

The answers to this question Is it okay for API secret to be stored in plain text or decrypt-able? are somewhat unsettling to me. I'm trying to wrap my mind around how storing a secret key in plaintext is in any way secure. This is how I'm imagining…
Rob
  • 393
  • 1
  • 4
  • 8
24
votes
6 answers

Does Rehashing a weak hash with a strong algorithm make it strong?

Imagine the following situation. We're making a web application which should be really safe Now the accounts/users are not directly added by us but they receive a letter with a logincode. We get a file every now and then containing an unsalted SHA-1…
Jester
  • 663
  • 5
  • 10
23
votes
3 answers

Should you care about DoS attacks if your server is using bcrypt?

(I just asked this question on "cryptography SE" and was suggested to ask it here instead) EDIT I just realized my question is mostly a dupe of: Prevent denial of service attacks against slow hashing functions? If someone chooses bcrypt isn't the…
Cedric Martin
  • 597
  • 1
  • 6
  • 14
21
votes
2 answers

How secure is BCRYPT(SHA1(Password))

This question is a fork from a previous question here: Is it safe/wise to store a salt in the same field as the hashed password? Assume you run a web portal, and store passwords in SHA1 hashes. How do you upgrade this to BCRYPT hashes instead?…
keithRozario
  • 3,781
  • 2
  • 16
  • 26
19
votes
5 answers

How to do client side hashing of password using BCrypt?

I am migrating an old application which used MD5 hashing to Spring Security with BCrypt encoding of passwords. I want to encode the password on new user creation page, change password page and on login page before it is sent to the network. I know…
Amit
  • 301
  • 1
  • 2
  • 7
16
votes
4 answers

How can I make sure password hashing is secure on computers while not being prohibitively slow on mobile devices?

I'm new to cryptography and its implementations. I'm designing an Android app where an user enters a password to retrieve some encrypted data. After some research on possible solutions I ended up with bcrypt used like so: User enter Password ->…
nsL
  • 263
  • 2
  • 5
1
2
3
…
14 15