Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Export-Certificate -Cert $cert -FilePath ".DevConfig.cer"
- $mypwd = ConvertTo-SecureString -String "1234" -Force -AsPlainText
- Export-PfxCertificate -Cert $cert -FilePath ".DevConfig.pfx" -Password $mypwd
- $cert
- Import-Certificate -Filepath ".DevConfig.cer" -CertStoreLocation cert:LocalMachineMy
- $mypwd = ConvertTo-SecureString -String "1234" -Force -AsPlainText
- Import-PfxCertificate -FilePath ".DevConfig.pfx" -CertStoreLocation Cert:LocalMachineMy -Password $mypwd
- Install-Package WebConfigEncrypter -Version 1.1.0
- <configProtectedData>
- <providers>
- <add name="Pkcs12Provider" thumbprint="91cb0b7c611e54f6bfd43c4d8d178b542bc6557e" type="WebConfigEncrypter.Pkcs12ProtectedConfigurationProvider, WebConfigEncrypter" storeLocation="LocalMachine"/>
- </providers>
- </configProtectedData>
- aspnet_regiis -pef "connectionStrings" "." -prov "Pkcs12Provider"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement