Giter Site home page Giter Site logo

matcher-pwned requests about zxcvbn HOT 5 CLOSED

zxcvbn-ts avatar zxcvbn-ts commented on June 10, 2024
matcher-pwned requests

from zxcvbn.

Comments (5)

MrWook avatar MrWook commented on June 10, 2024

Hey, as stated in the documentation it is recommended to use the provided debounce function or a debounce function from somewhere else.
There is even a example for the debounce function https://zxcvbn-ts.github.io/zxcvbn/guide/examples/#debounce

from zxcvbn.

bwillert avatar bwillert commented on June 10, 2024

I'am using the debounce function.
But the repeat-matcher executes the pwnd matcher for every repeat I guess.

So when I enter the password "testaa", two requests are sent to the pwnd api:
"testaa" = "1F390" in SHA1
"a" = "86F7E" in SHA1

When I enter "testaabb" I get 3 requests:
"testaabb" = "C4DCC" in SHA1
"a" = "86F7E" in SHA1
"b" = "E9D71" in SHA1

from zxcvbn.

MrWook avatar MrWook commented on June 10, 2024

Ah now i understand. This should not be the case i will look into it thanks for the report 👍

Edit:
I kind of revert this answer. Because the repeat matcher gets a base guess count for all other matchers. This doesn't seem to make sense for something like Testaabb but if you would have something like P4$$w0rdP4$$w0rd which is a common used password and in the pwned api it will get a pretty bad base guess count from it.
This basically means that for every part in the repeat matcher it will use all matchers to create a base guess count.
Does this answer your question?

from zxcvbn.

dark544 avatar dark544 commented on June 10, 2024

I don't really know, im not that deep into your library. 😅
It just seemed odd to me, that there are multiple requests happening.
For your example there are 6 requests being sent to the pwnd api (P4$$w0rdP4$$w0rd).
But I guess there is no other way, if you want to partially match a password.

from zxcvbn.

MrWook avatar MrWook commented on June 10, 2024

Just to get my example straight, there are actually 3 real requests and 3 preflight options requests :D Which means they belong together.
Those requests should be the whole example P4$$w0rdP4$$w0rd, a part of it for the repeat P4$$w0rd and $ because it repeats twice, too

from zxcvbn.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.