SSLAccept Parameter (Get-POP Cmdlet)
The encoded public key of the certificate which is to be trusted explicitly.
Get-POP -SSLAccept string
Ordinarily, the certificate presented by the server will be checked against the system certificate stores to see if the Certificate Authority is trusted, and if not, the cmdlet will prompt the user to accept the certificate. Setting this parameter will override the system settings and trust the certificate provided.
After each connection, regardless of whether or not the certificate was trusted, the cmdlet will store the certificate presented by the server in the $SSLServerCertificate session variable. This variable can be inspected to view details of the server's certificate.
If the Force parameter is set, the cmdlet will accept the server's certificate unconditionally.
In cases where the certificate presented by the server is not trusted, a prompt will be shown to the user. This prompt will allow the user to decide whether or not they would like to accept the certificate presented by the server.
There may be cases where you do not want a prompt to be displayed or would like to handle the response supplied directly within your script. This can be done by setting the $SSLAcceptPreference variable prior to running the cmdlet. The available values for this variable are:
|None (default)||Maintains the default behavior. If the certificate is not trusted by default, the user will be prompted.|
|Accept||Accepts the certificate without prompting the user, even if it is not trusted by default.|
|Reject||Rejects the certificate without prompting the user only if it is not trusted by default. Thus if the certificate is found to be trusted or the Force parameter is set, the connection will still be accepted.|