pub struct SignedInvocation { /* private fields */ }Expand description
An invocation’s InvocationStatement, the signer’s signature over it,
and the signer’s certificate. Decoded, it is only what it claims: nothing
in it is trusted until the identity layer verified the signature, the
certificate, its revocation and its freshness.
Implementations§
Source§impl SignedInvocation
impl SignedInvocation
Sourcepub const fn new(
statement: InvocationStatement,
signature: [u8; 64],
signer_cert: Vec<u8>,
) -> Self
pub const fn new( statement: InvocationStatement, signature: [u8; 64], signer_cert: Vec<u8>, ) -> Self
statement with the signature its signer made over
InvocationStatement::signing_message, and signer_cert, the
signer’s certificate in its binary encoding.
Sourcepub const fn statement(&self) -> &InvocationStatement
pub const fn statement(&self) -> &InvocationStatement
What the signer claims to have asked. Trust it only once verified.
pub const fn signature(&self) -> &[u8; 64]
Sourcepub fn signer_cert(&self) -> &[u8] ⓘ
pub fn signer_cert(&self) -> &[u8] ⓘ
The signer’s certificate in its binary encoding, its issuer’s within.
Sourcepub fn serves(&self, request: &InvokeRequest) -> bool
pub fn serves(&self, request: &InvokeRequest) -> bool
Whether this is the invocation request serves rather than request’s own: a call an
app makes while it runs this invocation names it as what it continues
(InvokeRequest::on_behalf_of) and carries it as its proof.
Sourcepub fn called_app(&self) -> Option<(String, String)>
pub fn called_app(&self) -> Option<(String, String)>
The workspace and the app the signer called: the app whose process runs this
invocation, and the only one whose calls it proves. None where it called no app.
Trait Implementations§
Source§impl Clone for SignedInvocation
impl Clone for SignedInvocation
Source§impl Debug for SignedInvocation
impl Debug for SignedInvocation
Source§impl<'de> Deserialize<'de> for SignedInvocation
impl<'de> Deserialize<'de> for SignedInvocation
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
impl Eq for SignedInvocation
Source§impl PartialEq for SignedInvocation
impl PartialEq for SignedInvocation
Source§impl Serialize for SignedInvocation
impl Serialize for SignedInvocation
impl StructuralPartialEq for SignedInvocation
Auto Trait Implementations§
impl Forget for SignedInvocation
impl Freeze for SignedInvocation
impl Move for SignedInvocation
impl RefUnwindSafe for SignedInvocation
impl Send for SignedInvocation
impl Sync for SignedInvocation
impl Unpin for SignedInvocation
impl UnsafeUnpin for SignedInvocation
impl UnwindSafe for SignedInvocation
Blanket Implementations§
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§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> ⓘ
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> ⓘ
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