zxcvbn is not thread safe
lukedd opened this issue · 2 comments
lukedd commented
zxcvbn.zxcvbn(password, user_inputs)
is not thread safe, because it calls matching.set_user_input_dictionary(...)
which puts state into a module global variable RANKED_DICTIONARIES
This can lead to incorrect behaviour if two threads are concurrently calling this function with different user_inputs.
dwolfhub commented
thanks for reporting.
i believe i have a quick fix in place. in master branch. can you confirm?
lukedd commented
Thanks, that change on master looks like it fixes the issue