pub struct KeyUsage(pub FlagSet<KeyUsages>);Expand description
KeyUsage as defined in RFC 5280 Section 4.2.1.3.
Tuple Fields§
§0: FlagSet<KeyUsages>Implementations§
Source§impl KeyUsage
impl KeyUsage
Sourcepub fn digital_signature(&self) -> bool
pub fn digital_signature(&self) -> bool
The subject public key is used for verifying digital signatures
Sourcepub fn non_repudiation(&self) -> bool
pub fn non_repudiation(&self) -> bool
When the subject public key is used to verify digital signatures, it is asserted as non-repudiation.
Sourcepub fn key_encipherment(&self) -> bool
pub fn key_encipherment(&self) -> bool
The subject public key is used for enciphering private or secret keys, i.e., for key transport.
Sourcepub fn data_encipherment(&self) -> bool
pub fn data_encipherment(&self) -> bool
The subject public key is used for directly enciphering raw user data without the use of an intermediate symmetric cipher.
Sourcepub fn key_agreement(&self) -> bool
pub fn key_agreement(&self) -> bool
The subject public key is used for key agreement
Sourcepub fn key_cert_sign(&self) -> bool
pub fn key_cert_sign(&self) -> bool
The subject public key is used for enciphering private or secret keys, i.e., for key transport.
Sourcepub fn crl_sign(&self) -> bool
pub fn crl_sign(&self) -> bool
The subject public key is used for verifying signatures on certificate revocation lists (e.g., CRLs, delta CRLs, or ARLs).
Sourcepub fn encipher_only(&self) -> bool
pub fn encipher_only(&self) -> bool
The meaning of the encipher_only is undefined when key_agreement
returns false. When encipher_only returns true and
key_agreement also returns true, the subject public key may be
used only for enciphering data while performing key agreement.
Sourcepub fn decipher_only(&self) -> bool
pub fn decipher_only(&self) -> bool
The meaning of the decipher_only is undefined when key_agreement
returns false. When encipher_only returns true and
key_agreement also returns true, the subject public key may be
used only for deciphering data while performing key agreement.