aboutsummaryrefslogtreecommitdiff
path: root/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust
diff options
context:
space:
mode:
Diffstat (limited to '.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust')
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/__init__.pyi28
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/_openssl.pyi8
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/asn1.pyi7
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/exceptions.pyi17
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/ocsp.pyi117
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/__init__.pyi72
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/aead.pyi103
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/ciphers.pyi38
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/cmac.pyi18
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/dh.pyi51
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/dsa.pyi41
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/ec.pyi52
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/ed25519.pyi12
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/ed448.pyi12
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/hashes.pyi19
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/hmac.pyi21
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/kdf.pyi43
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/keys.pyi33
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/poly1305.pyi13
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/rsa.pyi55
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/x25519.pyi12
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/x448.pyi12
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/pkcs12.pyi46
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/pkcs7.pyi49
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/test_support.pyi22
-rw-r--r--.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/x509.pyi246
26 files changed, 1147 insertions, 0 deletions
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/__init__.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/__init__.pyi
new file mode 100644
index 00000000..30b67d85
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/__init__.pyi
@@ -0,0 +1,28 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+import typing
+
+from cryptography.hazmat.primitives import padding
+
+def check_ansix923_padding(data: bytes) -> bool: ...
+
+class PKCS7PaddingContext(padding.PaddingContext):
+ def __init__(self, block_size: int) -> None: ...
+ def update(self, data: bytes) -> bytes: ...
+ def finalize(self) -> bytes: ...
+
+class PKCS7UnpaddingContext(padding.PaddingContext):
+ def __init__(self, block_size: int) -> None: ...
+ def update(self, data: bytes) -> bytes: ...
+ def finalize(self) -> bytes: ...
+
+class ObjectIdentifier:
+ def __init__(self, val: str) -> None: ...
+ @property
+ def dotted_string(self) -> str: ...
+ @property
+ def _name(self) -> str: ...
+
+T = typing.TypeVar("T")
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/_openssl.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/_openssl.pyi
new file mode 100644
index 00000000..80100082
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/_openssl.pyi
@@ -0,0 +1,8 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+import typing
+
+lib = typing.Any
+ffi = typing.Any
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/asn1.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/asn1.pyi
new file mode 100644
index 00000000..3b5f208e
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/asn1.pyi
@@ -0,0 +1,7 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+def decode_dss_signature(signature: bytes) -> tuple[int, int]: ...
+def encode_dss_signature(r: int, s: int) -> bytes: ...
+def parse_spki_for_data(data: bytes) -> bytes: ...
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/exceptions.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/exceptions.pyi
new file mode 100644
index 00000000..09f46b1e
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/exceptions.pyi
@@ -0,0 +1,17 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+class _Reasons:
+ BACKEND_MISSING_INTERFACE: _Reasons
+ UNSUPPORTED_HASH: _Reasons
+ UNSUPPORTED_CIPHER: _Reasons
+ UNSUPPORTED_PADDING: _Reasons
+ UNSUPPORTED_MGF: _Reasons
+ UNSUPPORTED_PUBLIC_KEY_ALGORITHM: _Reasons
+ UNSUPPORTED_ELLIPTIC_CURVE: _Reasons
+ UNSUPPORTED_SERIALIZATION: _Reasons
+ UNSUPPORTED_X509: _Reasons
+ UNSUPPORTED_EXCHANGE_ALGORITHM: _Reasons
+ UNSUPPORTED_DIFFIE_HELLMAN: _Reasons
+ UNSUPPORTED_MAC: _Reasons
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/ocsp.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/ocsp.pyi
new file mode 100644
index 00000000..e4321bec
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/ocsp.pyi
@@ -0,0 +1,117 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+import datetime
+import typing
+
+from cryptography import x509
+from cryptography.hazmat.primitives import hashes, serialization
+from cryptography.hazmat.primitives.asymmetric.types import PrivateKeyTypes
+from cryptography.x509 import ocsp
+
+class OCSPRequest:
+ @property
+ def issuer_key_hash(self) -> bytes: ...
+ @property
+ def issuer_name_hash(self) -> bytes: ...
+ @property
+ def hash_algorithm(self) -> hashes.HashAlgorithm: ...
+ @property
+ def serial_number(self) -> int: ...
+ def public_bytes(self, encoding: serialization.Encoding) -> bytes: ...
+ @property
+ def extensions(self) -> x509.Extensions: ...
+
+class OCSPResponse:
+ @property
+ def responses(self) -> typing.Iterator[OCSPSingleResponse]: ...
+ @property
+ def response_status(self) -> ocsp.OCSPResponseStatus: ...
+ @property
+ def signature_algorithm_oid(self) -> x509.ObjectIdentifier: ...
+ @property
+ def signature_hash_algorithm(
+ self,
+ ) -> hashes.HashAlgorithm | None: ...
+ @property
+ def signature(self) -> bytes: ...
+ @property
+ def tbs_response_bytes(self) -> bytes: ...
+ @property
+ def certificates(self) -> list[x509.Certificate]: ...
+ @property
+ def responder_key_hash(self) -> bytes | None: ...
+ @property
+ def responder_name(self) -> x509.Name | None: ...
+ @property
+ def produced_at(self) -> datetime.datetime: ...
+ @property
+ def produced_at_utc(self) -> datetime.datetime: ...
+ @property
+ def certificate_status(self) -> ocsp.OCSPCertStatus: ...
+ @property
+ def revocation_time(self) -> datetime.datetime | None: ...
+ @property
+ def revocation_time_utc(self) -> datetime.datetime | None: ...
+ @property
+ def revocation_reason(self) -> x509.ReasonFlags | None: ...
+ @property
+ def this_update(self) -> datetime.datetime: ...
+ @property
+ def this_update_utc(self) -> datetime.datetime: ...
+ @property
+ def next_update(self) -> datetime.datetime | None: ...
+ @property
+ def next_update_utc(self) -> datetime.datetime | None: ...
+ @property
+ def issuer_key_hash(self) -> bytes: ...
+ @property
+ def issuer_name_hash(self) -> bytes: ...
+ @property
+ def hash_algorithm(self) -> hashes.HashAlgorithm: ...
+ @property
+ def serial_number(self) -> int: ...
+ @property
+ def extensions(self) -> x509.Extensions: ...
+ @property
+ def single_extensions(self) -> x509.Extensions: ...
+ def public_bytes(self, encoding: serialization.Encoding) -> bytes: ...
+
+class OCSPSingleResponse:
+ @property
+ def certificate_status(self) -> ocsp.OCSPCertStatus: ...
+ @property
+ def revocation_time(self) -> datetime.datetime | None: ...
+ @property
+ def revocation_time_utc(self) -> datetime.datetime | None: ...
+ @property
+ def revocation_reason(self) -> x509.ReasonFlags | None: ...
+ @property
+ def this_update(self) -> datetime.datetime: ...
+ @property
+ def this_update_utc(self) -> datetime.datetime: ...
+ @property
+ def next_update(self) -> datetime.datetime | None: ...
+ @property
+ def next_update_utc(self) -> datetime.datetime | None: ...
+ @property
+ def issuer_key_hash(self) -> bytes: ...
+ @property
+ def issuer_name_hash(self) -> bytes: ...
+ @property
+ def hash_algorithm(self) -> hashes.HashAlgorithm: ...
+ @property
+ def serial_number(self) -> int: ...
+
+def load_der_ocsp_request(data: bytes) -> ocsp.OCSPRequest: ...
+def load_der_ocsp_response(data: bytes) -> ocsp.OCSPResponse: ...
+def create_ocsp_request(
+ builder: ocsp.OCSPRequestBuilder,
+) -> ocsp.OCSPRequest: ...
+def create_ocsp_response(
+ status: ocsp.OCSPResponseStatus,
+ builder: ocsp.OCSPResponseBuilder | None,
+ private_key: PrivateKeyTypes | None,
+ hash_algorithm: hashes.HashAlgorithm | None,
+) -> ocsp.OCSPResponse: ...
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/__init__.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/__init__.pyi
new file mode 100644
index 00000000..320cef10
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/__init__.pyi
@@ -0,0 +1,72 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+import typing
+
+from cryptography.hazmat.bindings._rust.openssl import (
+ aead,
+ ciphers,
+ cmac,
+ dh,
+ dsa,
+ ec,
+ ed448,
+ ed25519,
+ hashes,
+ hmac,
+ kdf,
+ keys,
+ poly1305,
+ rsa,
+ x448,
+ x25519,
+)
+
+__all__ = [
+ "aead",
+ "ciphers",
+ "cmac",
+ "dh",
+ "dsa",
+ "ec",
+ "ed448",
+ "ed25519",
+ "hashes",
+ "hmac",
+ "kdf",
+ "keys",
+ "openssl_version",
+ "openssl_version_text",
+ "poly1305",
+ "raise_openssl_error",
+ "rsa",
+ "x448",
+ "x25519",
+]
+
+CRYPTOGRAPHY_IS_LIBRESSL: bool
+CRYPTOGRAPHY_IS_BORINGSSL: bool
+CRYPTOGRAPHY_OPENSSL_300_OR_GREATER: bool
+CRYPTOGRAPHY_OPENSSL_309_OR_GREATER: bool
+CRYPTOGRAPHY_OPENSSL_320_OR_GREATER: bool
+
+class Providers: ...
+
+_legacy_provider_loaded: bool
+_providers: Providers
+
+def openssl_version() -> int: ...
+def openssl_version_text() -> str: ...
+def raise_openssl_error() -> typing.NoReturn: ...
+def capture_error_stack() -> list[OpenSSLError]: ...
+def is_fips_enabled() -> bool: ...
+def enable_fips(providers: Providers) -> None: ...
+
+class OpenSSLError:
+ @property
+ def lib(self) -> int: ...
+ @property
+ def reason(self) -> int: ...
+ @property
+ def reason_text(self) -> bytes: ...
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/aead.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/aead.pyi
new file mode 100644
index 00000000..047f49d8
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/aead.pyi
@@ -0,0 +1,103 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+class AESGCM:
+ def __init__(self, key: bytes) -> None: ...
+ @staticmethod
+ def generate_key(key_size: int) -> bytes: ...
+ def encrypt(
+ self,
+ nonce: bytes,
+ data: bytes,
+ associated_data: bytes | None,
+ ) -> bytes: ...
+ def decrypt(
+ self,
+ nonce: bytes,
+ data: bytes,
+ associated_data: bytes | None,
+ ) -> bytes: ...
+
+class ChaCha20Poly1305:
+ def __init__(self, key: bytes) -> None: ...
+ @staticmethod
+ def generate_key() -> bytes: ...
+ def encrypt(
+ self,
+ nonce: bytes,
+ data: bytes,
+ associated_data: bytes | None,
+ ) -> bytes: ...
+ def decrypt(
+ self,
+ nonce: bytes,
+ data: bytes,
+ associated_data: bytes | None,
+ ) -> bytes: ...
+
+class AESCCM:
+ def __init__(self, key: bytes, tag_length: int = 16) -> None: ...
+ @staticmethod
+ def generate_key(key_size: int) -> bytes: ...
+ def encrypt(
+ self,
+ nonce: bytes,
+ data: bytes,
+ associated_data: bytes | None,
+ ) -> bytes: ...
+ def decrypt(
+ self,
+ nonce: bytes,
+ data: bytes,
+ associated_data: bytes | None,
+ ) -> bytes: ...
+
+class AESSIV:
+ def __init__(self, key: bytes) -> None: ...
+ @staticmethod
+ def generate_key(key_size: int) -> bytes: ...
+ def encrypt(
+ self,
+ data: bytes,
+ associated_data: list[bytes] | None,
+ ) -> bytes: ...
+ def decrypt(
+ self,
+ data: bytes,
+ associated_data: list[bytes] | None,
+ ) -> bytes: ...
+
+class AESOCB3:
+ def __init__(self, key: bytes) -> None: ...
+ @staticmethod
+ def generate_key(key_size: int) -> bytes: ...
+ def encrypt(
+ self,
+ nonce: bytes,
+ data: bytes,
+ associated_data: bytes | None,
+ ) -> bytes: ...
+ def decrypt(
+ self,
+ nonce: bytes,
+ data: bytes,
+ associated_data: bytes | None,
+ ) -> bytes: ...
+
+class AESGCMSIV:
+ def __init__(self, key: bytes) -> None: ...
+ @staticmethod
+ def generate_key(key_size: int) -> bytes: ...
+ def encrypt(
+ self,
+ nonce: bytes,
+ data: bytes,
+ associated_data: bytes | None,
+ ) -> bytes: ...
+ def decrypt(
+ self,
+ nonce: bytes,
+ data: bytes,
+ associated_data: bytes | None,
+ ) -> bytes: ...
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/ciphers.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/ciphers.pyi
new file mode 100644
index 00000000..759f3b59
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/ciphers.pyi
@@ -0,0 +1,38 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+import typing
+
+from cryptography.hazmat.primitives import ciphers
+from cryptography.hazmat.primitives.ciphers import modes
+
+@typing.overload
+def create_encryption_ctx(
+ algorithm: ciphers.CipherAlgorithm, mode: modes.ModeWithAuthenticationTag
+) -> ciphers.AEADEncryptionContext: ...
+@typing.overload
+def create_encryption_ctx(
+ algorithm: ciphers.CipherAlgorithm, mode: modes.Mode
+) -> ciphers.CipherContext: ...
+@typing.overload
+def create_decryption_ctx(
+ algorithm: ciphers.CipherAlgorithm, mode: modes.ModeWithAuthenticationTag
+) -> ciphers.AEADDecryptionContext: ...
+@typing.overload
+def create_decryption_ctx(
+ algorithm: ciphers.CipherAlgorithm, mode: modes.Mode
+) -> ciphers.CipherContext: ...
+def cipher_supported(
+ algorithm: ciphers.CipherAlgorithm, mode: modes.Mode
+) -> bool: ...
+def _advance(
+ ctx: ciphers.AEADEncryptionContext | ciphers.AEADDecryptionContext, n: int
+) -> None: ...
+def _advance_aad(
+ ctx: ciphers.AEADEncryptionContext | ciphers.AEADDecryptionContext, n: int
+) -> None: ...
+
+class CipherContext: ...
+class AEADEncryptionContext: ...
+class AEADDecryptionContext: ...
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/cmac.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/cmac.pyi
new file mode 100644
index 00000000..9c03508b
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/cmac.pyi
@@ -0,0 +1,18 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+import typing
+
+from cryptography.hazmat.primitives import ciphers
+
+class CMAC:
+ def __init__(
+ self,
+ algorithm: ciphers.BlockCipherAlgorithm,
+ backend: typing.Any = None,
+ ) -> None: ...
+ def update(self, data: bytes) -> None: ...
+ def finalize(self) -> bytes: ...
+ def verify(self, signature: bytes) -> None: ...
+ def copy(self) -> CMAC: ...
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/dh.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/dh.pyi
new file mode 100644
index 00000000..08733d74
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/dh.pyi
@@ -0,0 +1,51 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+import typing
+
+from cryptography.hazmat.primitives.asymmetric import dh
+
+MIN_MODULUS_SIZE: int
+
+class DHPrivateKey: ...
+class DHPublicKey: ...
+class DHParameters: ...
+
+class DHPrivateNumbers:
+ def __init__(self, x: int, public_numbers: DHPublicNumbers) -> None: ...
+ def private_key(self, backend: typing.Any = None) -> dh.DHPrivateKey: ...
+ @property
+ def x(self) -> int: ...
+ @property
+ def public_numbers(self) -> DHPublicNumbers: ...
+
+class DHPublicNumbers:
+ def __init__(
+ self, y: int, parameter_numbers: DHParameterNumbers
+ ) -> None: ...
+ def public_key(self, backend: typing.Any = None) -> dh.DHPublicKey: ...
+ @property
+ def y(self) -> int: ...
+ @property
+ def parameter_numbers(self) -> DHParameterNumbers: ...
+
+class DHParameterNumbers:
+ def __init__(self, p: int, g: int, q: int | None = None) -> None: ...
+ def parameters(self, backend: typing.Any = None) -> dh.DHParameters: ...
+ @property
+ def p(self) -> int: ...
+ @property
+ def g(self) -> int: ...
+ @property
+ def q(self) -> int | None: ...
+
+def generate_parameters(
+ generator: int, key_size: int, backend: typing.Any = None
+) -> dh.DHParameters: ...
+def from_pem_parameters(
+ data: bytes, backend: typing.Any = None
+) -> dh.DHParameters: ...
+def from_der_parameters(
+ data: bytes, backend: typing.Any = None
+) -> dh.DHParameters: ...
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/dsa.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/dsa.pyi
new file mode 100644
index 00000000..0922a4c4
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/dsa.pyi
@@ -0,0 +1,41 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+import typing
+
+from cryptography.hazmat.primitives.asymmetric import dsa
+
+class DSAPrivateKey: ...
+class DSAPublicKey: ...
+class DSAParameters: ...
+
+class DSAPrivateNumbers:
+ def __init__(self, x: int, public_numbers: DSAPublicNumbers) -> None: ...
+ @property
+ def x(self) -> int: ...
+ @property
+ def public_numbers(self) -> DSAPublicNumbers: ...
+ def private_key(self, backend: typing.Any = None) -> dsa.DSAPrivateKey: ...
+
+class DSAPublicNumbers:
+ def __init__(
+ self, y: int, parameter_numbers: DSAParameterNumbers
+ ) -> None: ...
+ @property
+ def y(self) -> int: ...
+ @property
+ def parameter_numbers(self) -> DSAParameterNumbers: ...
+ def public_key(self, backend: typing.Any = None) -> dsa.DSAPublicKey: ...
+
+class DSAParameterNumbers:
+ def __init__(self, p: int, q: int, g: int) -> None: ...
+ @property
+ def p(self) -> int: ...
+ @property
+ def q(self) -> int: ...
+ @property
+ def g(self) -> int: ...
+ def parameters(self, backend: typing.Any = None) -> dsa.DSAParameters: ...
+
+def generate_parameters(key_size: int) -> dsa.DSAParameters: ...
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/ec.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/ec.pyi
new file mode 100644
index 00000000..5c3b7bf6
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/ec.pyi
@@ -0,0 +1,52 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+import typing
+
+from cryptography.hazmat.primitives.asymmetric import ec
+
+class ECPrivateKey: ...
+class ECPublicKey: ...
+
+class EllipticCurvePrivateNumbers:
+ def __init__(
+ self, private_value: int, public_numbers: EllipticCurvePublicNumbers
+ ) -> None: ...
+ def private_key(
+ self, backend: typing.Any = None
+ ) -> ec.EllipticCurvePrivateKey: ...
+ @property
+ def private_value(self) -> int: ...
+ @property
+ def public_numbers(self) -> EllipticCurvePublicNumbers: ...
+
+class EllipticCurvePublicNumbers:
+ def __init__(self, x: int, y: int, curve: ec.EllipticCurve) -> None: ...
+ def public_key(
+ self, backend: typing.Any = None
+ ) -> ec.EllipticCurvePublicKey: ...
+ @property
+ def x(self) -> int: ...
+ @property
+ def y(self) -> int: ...
+ @property
+ def curve(self) -> ec.EllipticCurve: ...
+ def __eq__(self, other: object) -> bool: ...
+
+def curve_supported(curve: ec.EllipticCurve) -> bool: ...
+def generate_private_key(
+ curve: ec.EllipticCurve, backend: typing.Any = None
+) -> ec.EllipticCurvePrivateKey: ...
+def from_private_numbers(
+ numbers: ec.EllipticCurvePrivateNumbers,
+) -> ec.EllipticCurvePrivateKey: ...
+def from_public_numbers(
+ numbers: ec.EllipticCurvePublicNumbers,
+) -> ec.EllipticCurvePublicKey: ...
+def from_public_bytes(
+ curve: ec.EllipticCurve, data: bytes
+) -> ec.EllipticCurvePublicKey: ...
+def derive_private_key(
+ private_value: int, curve: ec.EllipticCurve
+) -> ec.EllipticCurvePrivateKey: ...
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/ed25519.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/ed25519.pyi
new file mode 100644
index 00000000..5233f9a1
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/ed25519.pyi
@@ -0,0 +1,12 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+from cryptography.hazmat.primitives.asymmetric import ed25519
+
+class Ed25519PrivateKey: ...
+class Ed25519PublicKey: ...
+
+def generate_key() -> ed25519.Ed25519PrivateKey: ...
+def from_private_bytes(data: bytes) -> ed25519.Ed25519PrivateKey: ...
+def from_public_bytes(data: bytes) -> ed25519.Ed25519PublicKey: ...
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/ed448.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/ed448.pyi
new file mode 100644
index 00000000..7a065203
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/ed448.pyi
@@ -0,0 +1,12 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+from cryptography.hazmat.primitives.asymmetric import ed448
+
+class Ed448PrivateKey: ...
+class Ed448PublicKey: ...
+
+def generate_key() -> ed448.Ed448PrivateKey: ...
+def from_private_bytes(data: bytes) -> ed448.Ed448PrivateKey: ...
+def from_public_bytes(data: bytes) -> ed448.Ed448PublicKey: ...
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/hashes.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/hashes.pyi
new file mode 100644
index 00000000..56f31700
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/hashes.pyi
@@ -0,0 +1,19 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+import typing
+
+from cryptography.hazmat.primitives import hashes
+
+class Hash(hashes.HashContext):
+ def __init__(
+ self, algorithm: hashes.HashAlgorithm, backend: typing.Any = None
+ ) -> None: ...
+ @property
+ def algorithm(self) -> hashes.HashAlgorithm: ...
+ def update(self, data: bytes) -> None: ...
+ def finalize(self) -> bytes: ...
+ def copy(self) -> Hash: ...
+
+def hash_supported(algorithm: hashes.HashAlgorithm) -> bool: ...
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/hmac.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/hmac.pyi
new file mode 100644
index 00000000..e38d9b54
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/hmac.pyi
@@ -0,0 +1,21 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+import typing
+
+from cryptography.hazmat.primitives import hashes
+
+class HMAC(hashes.HashContext):
+ def __init__(
+ self,
+ key: bytes,
+ algorithm: hashes.HashAlgorithm,
+ backend: typing.Any = None,
+ ) -> None: ...
+ @property
+ def algorithm(self) -> hashes.HashAlgorithm: ...
+ def update(self, data: bytes) -> None: ...
+ def finalize(self) -> bytes: ...
+ def verify(self, signature: bytes) -> None: ...
+ def copy(self) -> HMAC: ...
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/kdf.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/kdf.pyi
new file mode 100644
index 00000000..4b90bb4f
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/kdf.pyi
@@ -0,0 +1,43 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+import typing
+
+from cryptography.hazmat.primitives.hashes import HashAlgorithm
+
+def derive_pbkdf2_hmac(
+ key_material: bytes,
+ algorithm: HashAlgorithm,
+ salt: bytes,
+ iterations: int,
+ length: int,
+) -> bytes: ...
+
+class Scrypt:
+ def __init__(
+ self,
+ salt: bytes,
+ length: int,
+ n: int,
+ r: int,
+ p: int,
+ backend: typing.Any = None,
+ ) -> None: ...
+ def derive(self, key_material: bytes) -> bytes: ...
+ def verify(self, key_material: bytes, expected_key: bytes) -> None: ...
+
+class Argon2id:
+ def __init__(
+ self,
+ *,
+ salt: bytes,
+ length: int,
+ iterations: int,
+ lanes: int,
+ memory_cost: int,
+ ad: bytes | None = None,
+ secret: bytes | None = None,
+ ) -> None: ...
+ def derive(self, key_material: bytes) -> bytes: ...
+ def verify(self, key_material: bytes, expected_key: bytes) -> None: ...
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/keys.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/keys.pyi
new file mode 100644
index 00000000..6815b7d9
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/keys.pyi
@@ -0,0 +1,33 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+import typing
+
+from cryptography.hazmat.primitives.asymmetric.types import (
+ PrivateKeyTypes,
+ PublicKeyTypes,
+)
+
+def load_der_private_key(
+ data: bytes,
+ password: bytes | None,
+ backend: typing.Any = None,
+ *,
+ unsafe_skip_rsa_key_validation: bool = False,
+) -> PrivateKeyTypes: ...
+def load_pem_private_key(
+ data: bytes,
+ password: bytes | None,
+ backend: typing.Any = None,
+ *,
+ unsafe_skip_rsa_key_validation: bool = False,
+) -> PrivateKeyTypes: ...
+def load_der_public_key(
+ data: bytes,
+ backend: typing.Any = None,
+) -> PublicKeyTypes: ...
+def load_pem_public_key(
+ data: bytes,
+ backend: typing.Any = None,
+) -> PublicKeyTypes: ...
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/poly1305.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/poly1305.pyi
new file mode 100644
index 00000000..2e9b0a9e
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/poly1305.pyi
@@ -0,0 +1,13 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+class Poly1305:
+ def __init__(self, key: bytes) -> None: ...
+ @staticmethod
+ def generate_tag(key: bytes, data: bytes) -> bytes: ...
+ @staticmethod
+ def verify_tag(key: bytes, data: bytes, tag: bytes) -> None: ...
+ def update(self, data: bytes) -> None: ...
+ def finalize(self) -> bytes: ...
+ def verify(self, tag: bytes) -> None: ...
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/rsa.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/rsa.pyi
new file mode 100644
index 00000000..ef7752dd
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/rsa.pyi
@@ -0,0 +1,55 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+import typing
+
+from cryptography.hazmat.primitives.asymmetric import rsa
+
+class RSAPrivateKey: ...
+class RSAPublicKey: ...
+
+class RSAPrivateNumbers:
+ def __init__(
+ self,
+ p: int,
+ q: int,
+ d: int,
+ dmp1: int,
+ dmq1: int,
+ iqmp: int,
+ public_numbers: RSAPublicNumbers,
+ ) -> None: ...
+ @property
+ def p(self) -> int: ...
+ @property
+ def q(self) -> int: ...
+ @property
+ def d(self) -> int: ...
+ @property
+ def dmp1(self) -> int: ...
+ @property
+ def dmq1(self) -> int: ...
+ @property
+ def iqmp(self) -> int: ...
+ @property
+ def public_numbers(self) -> RSAPublicNumbers: ...
+ def private_key(
+ self,
+ backend: typing.Any = None,
+ *,
+ unsafe_skip_rsa_key_validation: bool = False,
+ ) -> rsa.RSAPrivateKey: ...
+
+class RSAPublicNumbers:
+ def __init__(self, e: int, n: int) -> None: ...
+ @property
+ def n(self) -> int: ...
+ @property
+ def e(self) -> int: ...
+ def public_key(self, backend: typing.Any = None) -> rsa.RSAPublicKey: ...
+
+def generate_private_key(
+ public_exponent: int,
+ key_size: int,
+) -> rsa.RSAPrivateKey: ...
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/x25519.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/x25519.pyi
new file mode 100644
index 00000000..da0f3ec5
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/x25519.pyi
@@ -0,0 +1,12 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+from cryptography.hazmat.primitives.asymmetric import x25519
+
+class X25519PrivateKey: ...
+class X25519PublicKey: ...
+
+def generate_key() -> x25519.X25519PrivateKey: ...
+def from_private_bytes(data: bytes) -> x25519.X25519PrivateKey: ...
+def from_public_bytes(data: bytes) -> x25519.X25519PublicKey: ...
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/x448.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/x448.pyi
new file mode 100644
index 00000000..e51cfebe
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/openssl/x448.pyi
@@ -0,0 +1,12 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+from cryptography.hazmat.primitives.asymmetric import x448
+
+class X448PrivateKey: ...
+class X448PublicKey: ...
+
+def generate_key() -> x448.X448PrivateKey: ...
+def from_private_bytes(data: bytes) -> x448.X448PrivateKey: ...
+def from_public_bytes(data: bytes) -> x448.X448PublicKey: ...
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/pkcs12.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/pkcs12.pyi
new file mode 100644
index 00000000..40514c46
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/pkcs12.pyi
@@ -0,0 +1,46 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+import typing
+
+from cryptography import x509
+from cryptography.hazmat.primitives.asymmetric.types import PrivateKeyTypes
+from cryptography.hazmat.primitives.serialization import (
+ KeySerializationEncryption,
+)
+from cryptography.hazmat.primitives.serialization.pkcs12 import (
+ PKCS12KeyAndCertificates,
+ PKCS12PrivateKeyTypes,
+)
+
+class PKCS12Certificate:
+ def __init__(
+ self, cert: x509.Certificate, friendly_name: bytes | None
+ ) -> None: ...
+ @property
+ def friendly_name(self) -> bytes | None: ...
+ @property
+ def certificate(self) -> x509.Certificate: ...
+
+def load_key_and_certificates(
+ data: bytes,
+ password: bytes | None,
+ backend: typing.Any = None,
+) -> tuple[
+ PrivateKeyTypes | None,
+ x509.Certificate | None,
+ list[x509.Certificate],
+]: ...
+def load_pkcs12(
+ data: bytes,
+ password: bytes | None,
+ backend: typing.Any = None,
+) -> PKCS12KeyAndCertificates: ...
+def serialize_key_and_certificates(
+ name: bytes | None,
+ key: PKCS12PrivateKeyTypes | None,
+ cert: x509.Certificate | None,
+ cas: typing.Iterable[x509.Certificate | PKCS12Certificate] | None,
+ encryption_algorithm: KeySerializationEncryption,
+) -> bytes: ...
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/pkcs7.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/pkcs7.pyi
new file mode 100644
index 00000000..f9aa81ea
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/pkcs7.pyi
@@ -0,0 +1,49 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+import typing
+
+from cryptography import x509
+from cryptography.hazmat.primitives import serialization
+from cryptography.hazmat.primitives.asymmetric import rsa
+from cryptography.hazmat.primitives.serialization import pkcs7
+
+def serialize_certificates(
+ certs: list[x509.Certificate],
+ encoding: serialization.Encoding,
+) -> bytes: ...
+def encrypt_and_serialize(
+ builder: pkcs7.PKCS7EnvelopeBuilder,
+ encoding: serialization.Encoding,
+ options: typing.Iterable[pkcs7.PKCS7Options],
+) -> bytes: ...
+def sign_and_serialize(
+ builder: pkcs7.PKCS7SignatureBuilder,
+ encoding: serialization.Encoding,
+ options: typing.Iterable[pkcs7.PKCS7Options],
+) -> bytes: ...
+def decrypt_der(
+ data: bytes,
+ certificate: x509.Certificate,
+ private_key: rsa.RSAPrivateKey,
+ options: typing.Iterable[pkcs7.PKCS7Options],
+) -> bytes: ...
+def decrypt_pem(
+ data: bytes,
+ certificate: x509.Certificate,
+ private_key: rsa.RSAPrivateKey,
+ options: typing.Iterable[pkcs7.PKCS7Options],
+) -> bytes: ...
+def decrypt_smime(
+ data: bytes,
+ certificate: x509.Certificate,
+ private_key: rsa.RSAPrivateKey,
+ options: typing.Iterable[pkcs7.PKCS7Options],
+) -> bytes: ...
+def load_pem_pkcs7_certificates(
+ data: bytes,
+) -> list[x509.Certificate]: ...
+def load_der_pkcs7_certificates(
+ data: bytes,
+) -> list[x509.Certificate]: ...
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/test_support.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/test_support.pyi
new file mode 100644
index 00000000..ef9f779f
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/test_support.pyi
@@ -0,0 +1,22 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+from cryptography import x509
+from cryptography.hazmat.primitives import serialization
+from cryptography.hazmat.primitives.serialization import pkcs7
+
+class TestCertificate:
+ not_after_tag: int
+ not_before_tag: int
+ issuer_value_tags: list[int]
+ subject_value_tags: list[int]
+
+def test_parse_certificate(data: bytes) -> TestCertificate: ...
+def pkcs7_verify(
+ encoding: serialization.Encoding,
+ sig: bytes,
+ msg: bytes | None,
+ certs: list[x509.Certificate],
+ options: list[pkcs7.PKCS7Options],
+) -> None: ...
diff --git a/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/x509.pyi b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/x509.pyi
new file mode 100644
index 00000000..b494fb61
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/cryptography/hazmat/bindings/_rust/x509.pyi
@@ -0,0 +1,246 @@
+# This file is dual licensed under the terms of the Apache License, Version
+# 2.0, and the BSD License. See the LICENSE file in the root of this repository
+# for complete details.
+
+import datetime
+import typing
+
+from cryptography import x509
+from cryptography.hazmat.primitives import hashes, serialization
+from cryptography.hazmat.primitives.asymmetric.ec import ECDSA
+from cryptography.hazmat.primitives.asymmetric.padding import PSS, PKCS1v15
+from cryptography.hazmat.primitives.asymmetric.types import (
+ CertificateIssuerPublicKeyTypes,
+ CertificatePublicKeyTypes,
+ PrivateKeyTypes,
+)
+from cryptography.x509 import certificate_transparency
+
+def load_pem_x509_certificate(
+ data: bytes, backend: typing.Any = None
+) -> x509.Certificate: ...
+def load_der_x509_certificate(
+ data: bytes, backend: typing.Any = None
+) -> x509.Certificate: ...
+def load_pem_x509_certificates(
+ data: bytes,
+) -> list[x509.Certificate]: ...
+def load_pem_x509_crl(
+ data: bytes, backend: typing.Any = None
+) -> x509.CertificateRevocationList: ...
+def load_der_x509_crl(
+ data: bytes, backend: typing.Any = None
+) -> x509.CertificateRevocationList: ...
+def load_pem_x509_csr(
+ data: bytes, backend: typing.Any = None
+) -> x509.CertificateSigningRequest: ...
+def load_der_x509_csr(
+ data: bytes, backend: typing.Any = None
+) -> x509.CertificateSigningRequest: ...
+def encode_name_bytes(name: x509.Name) -> bytes: ...
+def encode_extension_value(extension: x509.ExtensionType) -> bytes: ...
+def create_x509_certificate(
+ builder: x509.CertificateBuilder,
+ private_key: PrivateKeyTypes,
+ hash_algorithm: hashes.HashAlgorithm | None,
+ rsa_padding: PKCS1v15 | PSS | None,
+) -> x509.Certificate: ...
+def create_x509_csr(
+ builder: x509.CertificateSigningRequestBuilder,
+ private_key: PrivateKeyTypes,
+ hash_algorithm: hashes.HashAlgorithm | None,
+ rsa_padding: PKCS1v15 | PSS | None,
+) -> x509.CertificateSigningRequest: ...
+def create_x509_crl(
+ builder: x509.CertificateRevocationListBuilder,
+ private_key: PrivateKeyTypes,
+ hash_algorithm: hashes.HashAlgorithm | None,
+ rsa_padding: PKCS1v15 | PSS | None,
+) -> x509.CertificateRevocationList: ...
+
+class Sct:
+ @property
+ def version(self) -> certificate_transparency.Version: ...
+ @property
+ def log_id(self) -> bytes: ...
+ @property
+ def timestamp(self) -> datetime.datetime: ...
+ @property
+ def entry_type(self) -> certificate_transparency.LogEntryType: ...
+ @property
+ def signature_hash_algorithm(self) -> hashes.HashAlgorithm: ...
+ @property
+ def signature_algorithm(
+ self,
+ ) -> certificate_transparency.SignatureAlgorithm: ...
+ @property
+ def signature(self) -> bytes: ...
+ @property
+ def extension_bytes(self) -> bytes: ...
+
+class Certificate:
+ def fingerprint(self, algorithm: hashes.HashAlgorithm) -> bytes: ...
+ @property
+ def serial_number(self) -> int: ...
+ @property
+ def version(self) -> x509.Version: ...
+ def public_key(self) -> CertificatePublicKeyTypes: ...
+ @property
+ def public_key_algorithm_oid(self) -> x509.ObjectIdentifier: ...
+ @property
+ def not_valid_before(self) -> datetime.datetime: ...
+ @property
+ def not_valid_before_utc(self) -> datetime.datetime: ...
+ @property
+ def not_valid_after(self) -> datetime.datetime: ...
+ @property
+ def not_valid_after_utc(self) -> datetime.datetime: ...
+ @property
+ def issuer(self) -> x509.Name: ...
+ @property
+ def subject(self) -> x509.Name: ...
+ @property
+ def signature_hash_algorithm(
+ self,
+ ) -> hashes.HashAlgorithm | None: ...
+ @property
+ def signature_algorithm_oid(self) -> x509.ObjectIdentifier: ...
+ @property
+ def signature_algorithm_parameters(
+ self,
+ ) -> None | PSS | PKCS1v15 | ECDSA: ...
+ @property
+ def extensions(self) -> x509.Extensions: ...
+ @property
+ def signature(self) -> bytes: ...
+ @property
+ def tbs_certificate_bytes(self) -> bytes: ...
+ @property
+ def tbs_precertificate_bytes(self) -> bytes: ...
+ def __eq__(self, other: object) -> bool: ...
+ def __hash__(self) -> int: ...
+ def public_bytes(self, encoding: serialization.Encoding) -> bytes: ...
+ def verify_directly_issued_by(self, issuer: Certificate) -> None: ...
+
+class RevokedCertificate: ...
+
+class CertificateRevocationList:
+ def public_bytes(self, encoding: serialization.Encoding) -> bytes: ...
+ def fingerprint(self, algorithm: hashes.HashAlgorithm) -> bytes: ...
+ def get_revoked_certificate_by_serial_number(
+ self, serial_number: int
+ ) -> RevokedCertificate | None: ...
+ @property
+ def signature_hash_algorithm(
+ self,
+ ) -> hashes.HashAlgorithm | None: ...
+ @property
+ def signature_algorithm_oid(self) -> x509.ObjectIdentifier: ...
+ @property
+ def signature_algorithm_parameters(
+ self,
+ ) -> None | PSS | PKCS1v15 | ECDSA: ...
+ @property
+ def issuer(self) -> x509.Name: ...
+ @property
+ def next_update(self) -> datetime.datetime | None: ...
+ @property
+ def next_update_utc(self) -> datetime.datetime | None: ...
+ @property
+ def last_update(self) -> datetime.datetime: ...
+ @property
+ def last_update_utc(self) -> datetime.datetime: ...
+ @property
+ def extensions(self) -> x509.Extensions: ...
+ @property
+ def signature(self) -> bytes: ...
+ @property
+ def tbs_certlist_bytes(self) -> bytes: ...
+ def __eq__(self, other: object) -> bool: ...
+ def __len__(self) -> int: ...
+ @typing.overload
+ def __getitem__(self, idx: int) -> x509.RevokedCertificate: ...
+ @typing.overload
+ def __getitem__(self, idx: slice) -> list[x509.RevokedCertificate]: ...
+ def __iter__(self) -> typing.Iterator[x509.RevokedCertificate]: ...
+ def is_signature_valid(
+ self, public_key: CertificateIssuerPublicKeyTypes
+ ) -> bool: ...
+
+class CertificateSigningRequest:
+ def __eq__(self, other: object) -> bool: ...
+ def __hash__(self) -> int: ...
+ def public_key(self) -> CertificatePublicKeyTypes: ...
+ @property
+ def subject(self) -> x509.Name: ...
+ @property
+ def signature_hash_algorithm(
+ self,
+ ) -> hashes.HashAlgorithm | None: ...
+ @property
+ def signature_algorithm_oid(self) -> x509.ObjectIdentifier: ...
+ @property
+ def signature_algorithm_parameters(
+ self,
+ ) -> None | PSS | PKCS1v15 | ECDSA: ...
+ @property
+ def extensions(self) -> x509.Extensions: ...
+ @property
+ def attributes(self) -> x509.Attributes: ...
+ def public_bytes(self, encoding: serialization.Encoding) -> bytes: ...
+ @property
+ def signature(self) -> bytes: ...
+ @property
+ def tbs_certrequest_bytes(self) -> bytes: ...
+ @property
+ def is_signature_valid(self) -> bool: ...
+ def get_attribute_for_oid(self, oid: x509.ObjectIdentifier) -> bytes: ...
+
+class PolicyBuilder:
+ def time(self, new_time: datetime.datetime) -> PolicyBuilder: ...
+ def store(self, new_store: Store) -> PolicyBuilder: ...
+ def max_chain_depth(self, new_max_chain_depth: int) -> PolicyBuilder: ...
+ def build_client_verifier(self) -> ClientVerifier: ...
+ def build_server_verifier(
+ self, subject: x509.verification.Subject
+ ) -> ServerVerifier: ...
+
+class VerifiedClient:
+ @property
+ def subjects(self) -> list[x509.GeneralName] | None: ...
+ @property
+ def chain(self) -> list[x509.Certificate]: ...
+
+class ClientVerifier:
+ @property
+ def validation_time(self) -> datetime.datetime: ...
+ @property
+ def store(self) -> Store: ...
+ @property
+ def max_chain_depth(self) -> int: ...
+ def verify(
+ self,
+ leaf: x509.Certificate,
+ intermediates: list[x509.Certificate],
+ ) -> VerifiedClient: ...
+
+class ServerVerifier:
+ @property
+ def subject(self) -> x509.verification.Subject: ...
+ @property
+ def validation_time(self) -> datetime.datetime: ...
+ @property
+ def store(self) -> Store: ...
+ @property
+ def max_chain_depth(self) -> int: ...
+ def verify(
+ self,
+ leaf: x509.Certificate,
+ intermediates: list[x509.Certificate],
+ ) -> list[x509.Certificate]: ...
+
+class Store:
+ def __init__(self, certs: list[x509.Certificate]) -> None: ...
+
+class VerificationError(Exception):
+ pass