Skip to content

Commit

Permalink
Arnold installer : Ignore expired certificate
Browse files Browse the repository at this point in the history
Temporary measure for testing. DO NOT MERGE.
  • Loading branch information
johnhaddon authored and ericmehl committed Sep 3, 2024
1 parent 1731ab6 commit e38ff9c
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion .github/workflows/main/installArnold.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@
import os
import pathlib
import shutil
import ssl
import subprocess
import urllib.request
import zipfile
Expand Down Expand Up @@ -68,6 +69,11 @@

print( "Downloading Arnold \"{}\"".format( url ) )

context = ssl.create_default_context()
context.check_hostname = False
context.verify_mode = ssl.CERT_NONE
httpsHandler = urllib.request.HTTPSHandler( context = context )

passwordManager = urllib.request.HTTPPasswordMgrWithDefaultRealm()
passwordManager.add_password(
realm = None,
Expand All @@ -77,7 +83,7 @@
)

authHandler = urllib.request.HTTPBasicAuthHandler( passwordManager )
opener = urllib.request.build_opener( authHandler )
opener = urllib.request.build_opener( httpsHandler, authHandler )

with opener.open( url ) as inFile :
with open( archiveFile, "wb" ) as outFile :
Expand Down

0 comments on commit e38ff9c

Please sign in to comment.