tags:

views:

68

answers:

2

I need to be able to tell the user if their password is strong or weak (or in between). Is there a library or a function that already does this?

If there isn't, what would be the best approach to determining if a password is secure or not?

+2  A: 

You can check out some articles on CodeProject. 1) http://www.codeproject.com/KB/edit/PasswordStrengh.aspx 2) http://www.codeproject.com/KB/security/passworddialog.aspx

A simple approach is to evaluate some regular expressions to check if it contains uppercase and lowercase letters, numbers, special symbols and the length of the password.

Iraklis
+3  A: 

KeePass has a password strength function. You can download the source zip file from here. The file you are looking for is called QualityEstimation in KeePassLib.Cryptography.

Jeremy Wiebe