Giter Club home page Giter Club logo

zxcppvbn's Introduction

zxcppvbn

zxcppvbn is a C++11 password strength estimation library. This library is the C++11 implementation of the similarly named zxcvbn library, written in CoffeeScript, and which you can find here.

zxcvbn attempts to give sound password advice through pattern matching and conservative entropy calculations. It finds 10k common passwords, common American names and surnames, common English words, and common patterns like dates, repeats (aaa), sequences (abcd), and QWERTY patterns.

This library follows the original CoffeeScript implementation as much as possible, with slight modifications because of the C++ programming language specificities, and some improvements, as well.

zxcppvbn's People

Contributors

peterbudai avatar jakepetroules avatar

Stargazers

Kent P avatar Pali avatar Michal Švagerka avatar Dave Smith avatar Ádám Lippai avatar

Watchers

Ádám Lippai avatar Gergely Nagy avatar James Cloos avatar Robert Angeli avatar  avatar Ukran avatar David Dvorszki avatar  avatar Peter Bartha avatar Tamás Hegedüs avatar  avatar  avatar

zxcppvbn's Issues

Unicode support

Hi, could you pls add unicode support?

I have problems when I have a unicode character like '§' for example here:

*N$1lu§m5E#uT§G0n76=a!F§

the library says its weak, because the last '§' does not fall in any cardinality group (its integer representation is -72 or something negative I dont remember):

add_class_cardinality('0', '9', 0);
add_class_cardinality('a', 'z', 0);
add_class_cardinality('A', 'Z', 0);
add_class_cardinality('\0', '\x7f', 33);
add_class_cardinality('\0', '\xff', 100);

thus having cardinality 0, then entropy minus infinity and then the password is weak.

my hotfix was to add another cardinality bucket for unicode (kinda treating it like other non-numeric/non-alphabetic ASCII character):

add_class_cardinality(-127, '\0', 100);

and trimming all unicode chars to last (rightest byte).

which kinda fixes this bug, but its just hotfix if you think about it not really taking into account some national characters like 'ç' or 'ž' or any semantics at all.

Thanks!

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.