pub struct Ed25519CertConstructor { /* private fields */ }
Expand description
Builder for Ed25519Cert
.
Implementations§
Source§impl Ed25519CertConstructor
impl Ed25519CertConstructor
Sourcepub fn expiration(&mut self, expiration: SystemTime) -> &mut Self
Available on crate feature encode
only.
pub fn expiration(&mut self, expiration: SystemTime) -> &mut Self
encode
only.Set the approximate expiration time for this certificate.
(The time will be rounded forward to the nearest hour after the epoch.)
Sourcepub fn signing_key(&mut self, key: Ed25519Identity) -> &mut Self
Available on crate feature encode
only.
pub fn signing_key(&mut self, key: Ed25519Identity) -> &mut Self
encode
only.Set the signing key to be included with this certificate.
This is optional: you don’t need to include the signing key at all. If you do, it must match the key that you actually use to sign the certificate.
Sourcepub fn clear_signing_key(&mut self) -> &mut Self
Available on crate feature encode
only.
pub fn clear_signing_key(&mut self) -> &mut Self
encode
only.Remove any signing key previously set on this Ed25519CertConstructor.
Sourcepub fn encode_and_sign<S>(
&self,
skey: &S,
) -> Result<EncodedEd25519Cert, CertEncodeError>where
S: Ed25519PublicKey + Ed25519SigningKey,
Available on crate feature encode
only.
pub fn encode_and_sign<S>(
&self,
skey: &S,
) -> Result<EncodedEd25519Cert, CertEncodeError>where
S: Ed25519PublicKey + Ed25519SigningKey,
encode
only.Encode a certificate into a new vector, signing the result
with skey
.
This function exists in lieu of a build()
function, since we have a rule that
we don’t produce an Ed25519Cert
except if the certificate is known to be
valid.
Trait Implementations§
Source§impl Clone for Ed25519CertConstructor
impl Clone for Ed25519CertConstructor
Source§fn clone(&self) -> Ed25519CertConstructor
fn clone(&self) -> Ed25519CertConstructor
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl Freeze for Ed25519CertConstructor
impl RefUnwindSafe for Ed25519CertConstructor
impl Send for Ed25519CertConstructor
impl Sync for Ed25519CertConstructor
impl Unpin for Ed25519CertConstructor
impl UnwindSafe for Ed25519CertConstructor
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more