Skip to content

Commit 3b8e542

Browse files
authored
Merge pull request #204 from adrian-andersson/updateTheTls12Method
Adjusted the TLS12 method based on discussions in Slack Chat
2 parents a4de0b1 + c0bc59d commit 3b8e542

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

PoshBot/PoshBot.psm1

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,5 +17,6 @@ $PSDefaultParameterValues = @{
1717
'ConvertTo-Json:Verbose' = $false
1818
}
1919

20-
# Enforce TLS 1.2
21-
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
20+
# Ensure TLS 1.2 is available
21+
# Thanks to jborean93 for the code
22+
[Net.ServicePointManager]::SecurityProtocol = [Net.ServicePointManager]::SecurityProtocol -bor [Net.SecurityProtocolType]::Tls12

0 commit comments

Comments
 (0)