Name

Bases: CryptoParser

Name type describes e.g. certificate subject or issuer. The attributes are following the RFC5280#Section-4.1.2.4

Note that every attribute is a list of string in order to support multivalued RDNs.

Attributes:
  • c (List[str]) –

    Country Name (2.5.4.6)

  • o (List[str]) –

    Organization Name (2.5.4.10)

  • ou (List[str]) –

    Organizational Unit Name (2.5.4.11)

  • dnq (List[str]) –

    Distinguished Name Qualifier (2.5.4.46)

  • s (List[str]) –

    State Or Province Name (2.5.4.8)

  • cn (List[str]) –

    Common Name (2.5.4.3)

  • serial (List[str]) –

    Serial Number (2.5.4.5)

  • ln (List[str]) –

    Locality Name (2.5.4.7)

  • t (List[str]) –

    Title (2.5.4.12)

  • sn (List[str]) –

    Surname (2.5.4.4)

  • gn (List[str]) –

    Given Name (2.5.4.42)

  • i (List[str]) –

    Initials (2.5.4.43)

  • p (List[str]) –

    Pseudonym (2.5.4.65)

  • gq (List[str]) –

    Generation Qualifier (2.5.4.44)

  • dc (List[str]) –

    Domain Component (0.9.2342.19200300.100.1.25)

from_cryptography classmethod
from_cryptography(name: x509.Name) -> Name

Create a Name instance from a cryptography Name object.

Parameters:
  • name (x509.Name) –

    The cryptography Name object.

Returns:
  • Name

    The Name instance.