Trait AsExtension

Source
pub trait AsExtension: AssociatedOid + Encode {
    // Required method
    fn critical(&self, subject: &Name, extensions: &[Extension]) -> bool;

    // Provided method
    fn to_extension(
        &self,
        subject: &Name,
        extensions: &[Extension],
    ) -> Result<Extension, Error> { ... }
}
Expand description

Trait to be implemented by extensions to allow them to be formated as x509 v3 extensions by builder.

Required Methods§

Source

fn critical(&self, subject: &Name, extensions: &[Extension]) -> bool

Should the extension be marked critical

Provided Methods§

Source

fn to_extension( &self, subject: &Name, extensions: &[Extension], ) -> Result<Extension, Error>

Returns the Extension with the content encoded.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§