pub enum IdentityDescriptor {
Oidc {
issuer: String,
subject: String,
proof: String,
},
Spiffe {
subject: String,
svid_type: String,
proof: String,
},
}Expand description
An RFC-AITP-0002 identity descriptor with its token as proof
(§5.1). Debug never prints the token.
Variants§
Implementations§
Source§impl IdentityDescriptor
impl IdentityDescriptor
Sourcepub fn oidc(
issuer: impl Into<String>,
subject: impl Into<String>,
token: impl Into<String>,
) -> Self
pub fn oidc( issuer: impl Into<String>, subject: impl Into<String>, token: impl Into<String>, ) -> Self
An OIDC descriptor.
Sourcepub fn spiffe_jwt(subject: impl Into<String>, svid: impl Into<String>) -> Self
pub fn spiffe_jwt(subject: impl Into<String>, svid: impl Into<String>) -> Self
A SPIFFE JWT-SVID descriptor.
Sourcepub fn identity(&self) -> WorkloadIdentity
pub fn identity(&self) -> WorkloadIdentity
The identity without its proof.
Trait Implementations§
Source§impl Clone for IdentityDescriptor
impl Clone for IdentityDescriptor
Source§impl Debug for IdentityDescriptor
impl Debug for IdentityDescriptor
Source§impl<'de> Deserialize<'de> for IdentityDescriptor
impl<'de> Deserialize<'de> for IdentityDescriptor
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>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for IdentityDescriptor
Source§impl PartialEq for IdentityDescriptor
impl PartialEq for IdentityDescriptor
Source§impl Serialize for IdentityDescriptor
impl Serialize for IdentityDescriptor
impl StructuralPartialEq for IdentityDescriptor
Auto Trait Implementations§
impl Freeze for IdentityDescriptor
impl RefUnwindSafe for IdentityDescriptor
impl Send for IdentityDescriptor
impl Sync for IdentityDescriptor
impl Unpin for IdentityDescriptor
impl UnsafeUnpin for IdentityDescriptor
impl UnwindSafe for IdentityDescriptor
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
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.