Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Time to crack sometimes wrong in v1.9.0 #177

Open
StellarSand opened this issue Jul 6, 2024 · 0 comments
Open

Time to crack sometimes wrong in v1.9.0 #177

StellarSand opened this issue Jul 6, 2024 · 0 comments

Comments

@StellarSand
Copy link

StellarSand commented Jul 6, 2024

When using v1.9.0 of this library, time to crack calculations are wrong, sometimes giving 0 months/years.
Issue is not present in v1.8.2 & earlier.

For now I've found mainly 2 passwords that are able to reproduce this issue: jdfhasfqwui1 & hsdsjlll, but there's definitely more (check Some more passwords at the end).

Here's a sample code with results:

Sample code

import com.nulabinc.zxcvbn.Zxcvbn

fun main() {
    val zxcvbn = Zxcvbn()
    val strength = zxcvbn.measure("jdfhasfqwui1")
    val crackTimesDisplay = strength.crackTimesDisplay
    println("10B/sec (offline fast): ${crackTimesDisplay.offlineFastHashing1e10PerSecond}")
    println("10K/sec (offline slow): ${crackTimesDisplay.offlineSlowHashing1e4perSecond}")
    println("10/sec (online fast): ${crackTimesDisplay.onlineNoThrottling10perSecond}")
    println("100/hour (online slow): ${crackTimesDisplay.onlineThrottling100perHour}")
}

Results

Password v1.9.0 v1.8.2
jdfhasfqwui1 1_1_9_0 1_1_8_2
hsdsjlll 2_1_9_0 2_1_8_2

Some more passwords

  • Modify jdfhasfqwui1 a bit to get:
    • jdfhasfewui5
    • fdfhadfewui7
    • ydfhcxfewup9
    • 1lmhcxf5wuo9

All of the above give the same 10K/sec (offline slow): 0 years as jdfhasfqwui1 with v1.9.0

  • Similarly modify hsdsjlll a bit to get:
    • ut3sljjj
    • abc9ppp
    • jr9rg555
    • down3tlkkk

down3tlkkk gives 10/sec (online fast): 0 months with v1.9.0.
The rest of them gives the same 100/hour (online slow): 0 years as hsdsjlll with v1.9.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant