It seams that we have a collision with our security policy's.
[...]
add-type @"
using System.Net;
using System.Security.Cryptography.X509Certificates;
public class TrustAllCertsPolicy : ICertificatePolicy {
public bool CheckValidationResult(
ServicePoint srvPoint, X509Certificate certificate,
WebRequest request, int certificateProblem) {
return true;
}
}
"@
[System.Net.ServicePointManager]::CertificatePolicy = New-Object TrustAllCertsPolicy
[...]
I removed this section signed the script with our PKI.
But now the script doesn't get executed.
How can I sign the script with passwordstate?
Thanks.
Otto