Passwords

Feb 20, 2011 at 10:37 AM

What would be the best way to mask the characters of a string property like a password?

I'm displaying the properties of an sql connection and one of them is the password.

Coordinator
Feb 22, 2011 at 5:14 PM

See the latest source code. You can decorate with password property with the [Password] attribute - and PropertyEditor will use a PasswordBox to edit the password (with a little trick since PasswordBox does not let you bind to the Password property).

If you are using a SecureString some more changes may be neccessary.

Feb 22, 2011 at 8:00 PM

Thanks,

I wasn't expecting you to write something for me. I'm not using a SecureString.