generated from nathanwoodburn/python-webserver-template
parent
0c08f11f6e
commit
15caf7ce4f
@ -3,4 +3,5 @@ gunicorn
|
||||
requests
|
||||
python-dotenv
|
||||
dnspython
|
||||
cryptography
|
||||
cryptography
|
||||
datetime
|
2
tools.py
2
tools.py
@ -101,7 +101,7 @@ def check_ssl(domain: str):
|
||||
|
||||
expiry_date = cert_obj.not_valid_after_utc
|
||||
# Check if expiry date is past
|
||||
if expiry_date < datetime.datetime.now(tz=datetime.UTC):
|
||||
if expiry_date < datetime.datetime.now(datetime.timezone.utc):
|
||||
returns["cert"]["expired"] = True
|
||||
returns["cert"]["valid"] = False
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user