Skip to content

Commit

Permalink
Workaround 'Could not create SSL/TLS secure channel' issue due to TLS…
Browse files Browse the repository at this point in the history
… 1.1 being the default on earlier versions of .NET.
  • Loading branch information
drieseng committed Dec 31, 2020
1 parent 0085562 commit 68a47f6
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions build/build.proj
Original file line number Diff line number Diff line change
Expand Up @@ -222,6 +222,10 @@
<Reference Include="System" />
<Code Type="Fragment" Language="cs">
<![CDATA[
// Workaround 'Could not create SSL/TLS secure channel' issue due to TLS 1.1 being
// the default on earlier versions of .NET
System.Net.ServicePointManager.SecurityProtocol = System.Net.SecurityProtocolType.Tls12;
// Download file
new System.Net.WebClient().DownloadFile(Address, FileName);
]]>
</Code>
Expand Down

0 comments on commit 68a47f6

Please sign in to comment.