fixed deprecations
This commit is contained in:
parent
3095a13f18
commit
9f89d2d221
@ -254,8 +254,8 @@ def test_our_config_token_with_our_key():
|
||||
.issuer_name(ca_subject)
|
||||
.public_key(instance_private_key.public_key())
|
||||
.serial_number(x509.random_serial_number())
|
||||
.not_valid_before(datetime.utcnow() - timedelta(days=1))
|
||||
.not_valid_after(datetime.utcnow() + timedelta(days=365 * 10))
|
||||
.not_valid_before(datetime.now(tz=UTC) - timedelta(days=1))
|
||||
.not_valid_after(datetime.now(tz=UTC) + timedelta(days=365 * 10))
|
||||
.add_extension(x509.BasicConstraints(ca=True, path_length=None), critical=True)
|
||||
.sign(instance_private_key, hashes.SHA256()))
|
||||
|
||||
@ -276,8 +276,8 @@ def test_our_config_token_with_our_key():
|
||||
.issuer_name(issuer_name)
|
||||
.public_key(instance_private_key.public_key())
|
||||
.serial_number(x509.random_serial_number())
|
||||
.not_valid_before(datetime.utcnow() - timedelta(days=1))
|
||||
.not_valid_after(datetime.utcnow() + timedelta(days=3650))
|
||||
.not_valid_before(datetime.now(tz=UTC) - timedelta(days=1))
|
||||
.not_valid_after(datetime.now(tz=UTC) + timedelta(days=3650))
|
||||
.add_extension(x509.BasicConstraints(ca=False, path_length=None), critical=False)
|
||||
.sign(instance_private_key, hashes.SHA256())
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user