closes #2662 This feature adds the ability to restrict the SSL/TLS protocol used when making the web request. In 5.1 the user could make use of .NET API's to enforce this on the Web Cmdlets. With the move to HttpClient in PowerShell Core, those APIs have no impact. The user still has requirements to ensure specific protocols are used. The public enum WebSslProtocol is added as a wrapper to the underlying SslProtocols enum. Neither it nor SecurityProtocolType can be used because Ssl3 and Ssl2 are not supported by HttpClientHandler.SslProtocols. While it may not be intuitive to a PowerShell user to use -bor or "Tls, Tls11" to set multiple options, the general use case for this will be a single protocol. Adds -SslProtocol parameter to Web Cmdlets Adds WebSslProtocol Enum to support limited subset of SslProtocol enum supported by HttpClientHandler Adds TLS 1.1 and TLS 1.0 listening ports to WebListener |
||
---|---|---|
.. | ||
ClientCert.pfx | ||
README.md | ||
ServerCert.pfx | ||
WebListener.psd1 | ||
WebListener.psm1 |
WebListener Module
A PowerShell module for managing the WebListener App. The included SelF-Signed Certificate ServerCert.pfx
has the password set to password
and is issued for the Client and Server Authentication key usages. This certificate is used by the WebListener App for SSL/TLS. The included SelF-Signed Certificate ClientCert.pfx
has the password set to password
and has not been issued for any specific key usage. This Certificate is used for Client Certificate Authentication with the WebListener App. The port used for -HttpsPort
will use TLS 1.2.
Running WebListener
Import-Module .\build.psm1
Publish-PSTestTools
$Listener = Start-WebListener -HttpPort 8083 -HttpsPort 8084 -Tls11Port 8085 -TlsPort 8086
Stopping WebListener
Stop-WebListener