Encrypt Passwords

To store passwords in a secure way (without secure store) the solution supports password encryption.

1. Export Key

While installation the solution automatically creates a public-private key pair. To encrypt a password we need to export the public key. To export the key run the “Export-Key.ps1” script that is included in the download package. The script have to be executed on a SharePoint server.

PS> & .\Export-Key.ps1 –path “C:\public.key”

2. Encrypt Password

To encrypt a password we need  the key file that we’ve exported in step 1. The script have not be run on SharePoint server, you only need the key.

PS> & .\Encrypt-Password.ps1 –password “P@ssw0rd” –keyPath “C:\public.key”

3. Copy the encrypted password

The encrypted password will look like this:

enc::WowqgXN/ssnqJW7RDm0VYbGDGUlO8wO9qgrE0JdxWCONQi/88rVTHdJqrOgkSNd0vTvrM+Zab4
tp48BgfcUhcvyjTNxmY2Iq/eOgXUDxH6Xv2tPU+UI5x92oxydlGL4O7lyFav9oXpkGbRmIrhJKOacOJ
+zYftU0A8rnR+yTYYQ=

You can copy the encrypted password to any action (e.g. Execute SQL) that requires a password.

Last edited Feb 21, 2011 at 9:16 PM by cglessner, version 2

Comments

No comments yet.