Skip to content

Commit

Permalink
fix: use utcnow() to check certificate validity (#151)
Browse files Browse the repository at this point in the history
  • Loading branch information
rstanchak authored Oct 24, 2022
1 parent 72e8cc9 commit 5185483
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion iso15118/shared/security.py
Original file line number Diff line number Diff line change
Expand Up @@ -710,7 +710,7 @@ def check_validity(certs: List[Certificate]):
Raises:
CertNotYetValidError, CertExpiredError
"""
now = datetime.now()
now = datetime.utcnow()
for cert in certs:
if cert.not_valid_before > now:
raise CertNotYetValidError(cert.subject.__str__())
Expand Down

0 comments on commit 5185483

Please sign in to comment.