django_ca.constants - constants¶
- django_ca.constants.ELLIPTIC_CURVE_TYPES¶
Mapping of elliptic curve names to the implementing classes
Key
Value
"brainpoolP256r1""brainpoolP384r1""brainpoolP512r1""secp192r1""secp224r1""secp256k1""secp256r1""secp384r1""secp521r1""sect163k1""sect163r2""sect233k1""sect233r1""sect283k1""sect283r1""sect409k1""sect409r1""sect571k1""sect571r1"
- django_ca.constants.EXTENDED_KEY_USAGE_NAMES¶
Map of ExtendedKeyUsageOIDs to names in RFC 5280 (and other RFCs).
test
Key
Value
"anyExtendedKeyUsage""certificateTransparency""clientAuth""codeSigning""emailProtection""ipsecIKE""msKDC""OCSPSigning""serverAuth""smartcardLogon""timeStamping"<ObjectIdentifier(oid=1.0.18013.5.1.2, name=Unknown OID)>"mdlDS"<ObjectIdentifier(oid=1.0.18013.5.1.3, name=Unknown OID)>"mdlJWS"<ObjectIdentifier(oid=1.3.6.1.5.5.7.3.5, name=Unknown OID)>"ipsecEndSystem"<ObjectIdentifier(oid=1.3.6.1.5.5.7.3.6, name=Unknown OID)>"ipsecTunnel"<ObjectIdentifier(oid=1.3.6.1.5.5.7.3.7, name=Unknown OID)>"ipsecUser"
- django_ca.constants.EXTENSION_DEFAULT_CRITICAL¶
Map of ExtensionOIDs to the default critical values as defined in the RFC where they are defined.
Key
Value
FalseFalseTrueFalseFalseFalseTrueFalseFalseTrueFalseTrueTrueTrueFalseTrueExtensionOID.POLICY_MAPPINGSTrueTrueFalseFalseFalseExtensionOID.SUBJECT_DIRECTORY_ATTRIBUTESFalseFalseFalseFalse
- django_ca.constants.EXTENSION_KEYS¶
Map of ExtensionOIDs to keys that are usable as class attributes.
Key
Value
"authority_information_access""authority_key_identifier""basic_constraints""certificate_policies""crl_distribution_points""crl_number""delta_crl_indicator""extended_key_usage""freshest_crl""inhibit_any_policy""issuer_alternative_name""issuing_distribution_point""key_usage""name_constraints""ocsp_no_check""policy_constraints"ExtensionOID.POLICY_MAPPINGS"policy_mappings""precert_poison""precertificate_signed_certificate_timestamps""signed_certificate_timestamps""subject_alternative_name"ExtensionOID.SUBJECT_DIRECTORY_ATTRIBUTES"subject_directory_attributes""subject_information_access""subject_key_identifier""tls_feature"
- django_ca.constants.EXTENSION_KEY_OIDS¶
Map of extension keys to ExtensionOIDs (the inverse of EXTENSION_KEYS).
- django_ca.constants.HASH_ALGORITHM_NAMES: MappingProxyType[Type[AllowedHashTypes], str]¶
Key
Value
"SHA-224""SHA-256""SHA-384""SHA3/224""SHA3/256""SHA3/384""SHA3/512""SHA-512"
- django_ca.constants.KEY_USAGE_NAMES¶
Map of kwargs for
KeyUsageto names in RFC 5280.Key
Value
"content_commitment""nonRepudiation""crl_sign""cRLSign""data_encipherment""dataEncipherment""decipher_only""decipherOnly""digital_signature""digitalSignature""encipher_only""encipherOnly""key_agreement""keyAgreement""key_cert_sign""keyCertSign""key_encipherment""keyEncipherment"
- django_ca.constants.NAME_OID_NAMES¶
Map OID objects to IDs used in subject strings
Key
Value
"businessCategory""CN""C""dnQualifier""DC""emailAddress""generationQualifier""givenName""jurisdictionCountryName""jurisdictionLocalityName""jurisdictionStateOrProvinceName""L""OU""O""postalAddress""postalCode""pseudonym""serialNumber""ST""street""sn""title""unstructuredName""uid""x500UniqueIdentifier"NameOID.INN"inn"NameOID.OGRN"ogrn"NameOID.SNILS"snils"
- django_ca.constants.NAME_OID_TYPES¶
Map NameOID names to cryptography NameOID objects. This variant adds all RFC 4519 aliases as well.
Key
Value
"C""CN""DC""L""O""OU""ST""businessCategory""commonName""countryName""dnQualifier""domainComponent""emailAddress""generationQualifier""givenName""inn"NameOID.INN"jurisdictionCountryName""jurisdictionLocalityName""jurisdictionStateOrProvinceName""localityName""ogrn"NameOID.OGRN"organizationName""organizationalUnitName""postalAddress""postalCode""pseudonym""serialNumber""sn""snils"NameOID.SNILS"street""streetAddress""surname""title""uid""unstructuredName""userid""x500UniqueIdentifier"
Collection of constants used by django-ca.
- class django_ca.constants.ReasonFlags(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)[source]¶
An enumeration for CRL reasons.
This enumeration is a copy of
cryptography.x509.ReasonFlags. We create a copy because any change in the enumeration would trigger a database migration, so up/downgrading cryptography might cause problems with your Django project.