@@ -800,6 +800,9 @@ def get_components(self) -> list[tuple[bytes, bytes]]:
800
800
class X509Extension :
801
801
"""
802
802
An X.509 v3 certificate extension.
803
+
804
+ .. deprecated:: 23.3.0
805
+ Use cryptography's X509 APIs instead.
803
806
"""
804
807
805
808
def __init__ (
@@ -980,6 +983,9 @@ def get_data(self) -> bytes:
980
983
class X509Req :
981
984
"""
982
985
An X.509 certificate signing requests.
986
+
987
+ .. deprecated:: 24.2.0
988
+ Use `cryptography.x509.CertificateSigningRequest` instead.
983
989
"""
984
990
985
991
def __init__ (self ) -> None :
@@ -2248,6 +2254,9 @@ def dump_privatekey(
2248
2254
class Revoked :
2249
2255
"""
2250
2256
A certificate revocation.
2257
+
2258
+ .. deprecated:: 23.3.0
2259
+ Use cryptography's X509 APIs instead.
2251
2260
"""
2252
2261
2253
2262
# https://www.openssl.org/docs/manmaster/man5/x509v3_config.html#CRL-distribution-points
@@ -2438,6 +2447,9 @@ def get_rev_date(self) -> bytes | None:
2438
2447
class CRL :
2439
2448
"""
2440
2449
A certificate revocation list.
2450
+
2451
+ .. deprecated:: 23.3.0
2452
+ Use cryptography's X509 APIs instead.
2441
2453
"""
2442
2454
2443
2455
def __init__ (self ) -> None :
@@ -2841,6 +2853,10 @@ def dump_certificate_request(type: int, req: X509Req) -> bytes:
2841
2853
:param type: The file type (one of FILETYPE_PEM, FILETYPE_ASN1)
2842
2854
:param req: The certificate request to dump
2843
2855
:return: The buffer with the dumped certificate request in
2856
+
2857
+
2858
+ .. deprecated:: 24.2.0
2859
+ Use `cryptography.x509.CertificateSigningRequest` instead.
2844
2860
"""
2845
2861
bio = _new_mem_buf ()
2846
2862
@@ -2883,6 +2899,10 @@ def load_certificate_request(type: int, buffer: bytes) -> X509Req:
2883
2899
:param type: The file type (one of FILETYPE_PEM, FILETYPE_ASN1)
2884
2900
:param buffer: The buffer the certificate request is stored in
2885
2901
:return: The X509Req object
2902
+
2903
+ .. deprecated:: 24.2.0
2904
+ Use `cryptography.x509.load_der_x509_csr` or
2905
+ `cryptography.x509.load_pem_x509_csr` instead.
2886
2906
"""
2887
2907
if isinstance (buffer , str ):
2888
2908
buffer = buffer .encode ("ascii" )
@@ -2927,6 +2947,8 @@ def sign(pkey: PKey, data: str | bytes, digest: str) -> bytes:
2927
2947
:return: signature
2928
2948
2929
2949
.. versionadded:: 0.11
2950
+ .. deprecated:: 23.3.0
2951
+ Use cryptography's X509 APIs instead.
2930
2952
"""
2931
2953
data = _text_to_bytes_and_warn ("data" , data )
2932
2954
@@ -2975,6 +2997,8 @@ def verify(
2975
2997
:return: ``None`` if the signature is correct, raise exception otherwise.
2976
2998
2977
2999
.. versionadded:: 0.11
3000
+ .. deprecated:: 23.3.0
3001
+ Use cryptography's X509 APIs instead.
2978
3002
"""
2979
3003
data = _text_to_bytes_and_warn ("data" , data )
2980
3004
@@ -3018,6 +3042,9 @@ def dump_crl(type: int, crl: _CRLInternal) -> bytes:
3018
3042
3019
3043
:return: The buffer with the CRL.
3020
3044
:rtype: bytes
3045
+
3046
+ .. deprecated:: 23.3.0
3047
+ Use cryptography's X509 APIs instead.
3021
3048
"""
3022
3049
bio = _new_mem_buf ()
3023
3050
@@ -3059,6 +3086,9 @@ def load_crl(type: int, buffer: str | bytes) -> _CRLInternal:
3059
3086
:param buffer: The buffer the CRL is stored in
3060
3087
3061
3088
:return: The CRL object
3089
+
3090
+ .. deprecated:: 23.3.0
3091
+ Use cryptography's X509 APIs instead.
3062
3092
"""
3063
3093
if isinstance (buffer , str ):
3064
3094
buffer = buffer .encode ("ascii" )
0 commit comments