Skip to content

Commit 91652f0

Browse files
authored
Merge pull request #2192 from sopel-irc/trusty-expired-LE-root
travis: remove expired DST Root CA X3 cert on trusty
2 parents d922732 + d075d51 commit 91652f0

1 file changed

Lines changed: 12 additions & 0 deletions

File tree

.travis.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,18 @@ install:
3939
- pip install --upgrade "setuptools<=39.2.0; python_version < '3.9'"
4040
- pip install --upgrade -r requirements.txt -r dev-requirements.txt
4141
- python setup.py develop
42+
before_script:
43+
# deal with Let's Encrypt's ISRG Root CA X1 being cross-signed by an expired root
44+
# only needed on trusty - mark the bad cert disabled in conf, update ca-certificates
45+
# bundle, then tell python-requests to use the system bundle instead of certifi's
46+
# (as of 2021-10-05, certifi still stubbornly bundles the expired root;
47+
# see https://github.com/certifi/python-certifi/pull/162
48+
# and https://bugzilla.mozilla.org/show_bug.cgi?id=1733560 for updates)
49+
- if [ "$TRAVIS_DIST" == "trusty" ]; then
50+
sudo sed -re 's#^(mozilla/DST_Root_CA_X3.crt)$#!\1#' -i /etc/ca-certificates.conf;
51+
sudo update-ca-certificates;
52+
export REQUESTS_CA_BUNDLE=/etc/ssl/certs/ca-certificates.crt;
53+
fi
4254
script:
4355
- make travis
4456
env:

0 commit comments

Comments
 (0)