powershell password encryption in script code example
Example: powershell password encryption in script
(get-credential).password | ConvertFrom-SecureString | set-content "C:\Passwords\password.txt"
(get-credential).password | ConvertFrom-SecureString | set-content "C:\Passwords\password.txt"