#[non_exhaustive]pub enum Principal {
Anonymous,
Signer {
ed25519: [u8; 32],
},
BearerHolder,
TransportPeer {
ed25519: [u8; 32],
},
SshForcedCommand {
key: Option<[u8; 32]>,
},
}Expand description
The identity a request was mapped to. Non-exhaustive: M2 may add a caller-view class.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Anonymous
No credentials.
Signer
An auth v2 signer.
BearerHolder
Holder of a deployment-wide shared bearer token (mkit-server serve --auth bearer, formerly mkit serve --http).
TransportPeer
The authenticated peer of an encrypted (enc) listener.
SshForcedCommand
mkit serve over stdio. The identity is the ssh forced command
(SSH-SECURITY §5). key is always None in M0; WP-1.15 sets it from
mkit serve --principal <ed25519-hex>.
Implementations§
Trait Implementations§
impl Eq for Principal
impl StructuralPartialEq for Principal
Auto Trait Implementations§
impl Freeze for Principal
impl RefUnwindSafe for Principal
impl Send for Principal
impl Sync for Principal
impl Unpin for Principal
impl UnsafeUnpin for Principal
impl UnwindSafe for Principal
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
Mutably borrows from an owned value. Read more