See http://www.passwordmeter.com/ and http://phiras.wordpress.com/2007/04/08/password-strength-meter-a-jquery-plugin/ as good examples.
And let the user decide what is crucial and what fits the custom rules of the project. Like number of upper case, number of special chars and minimum length of the password.