pub trait WorkloadIdentityProvider:
Debug
+ Send
+ Sync {
// Required methods
fn issue(
&self,
request: WorkloadCredentialRequest,
) -> Result<WorkloadCredential, WorkloadIdentityError>;
fn verify(
&self,
token: &str,
verification: &WorkloadIdentityVerification,
) -> Result<AuthenticatedServicePrincipal, WorkloadIdentityError>;
// Provided method
fn issue_async(
&self,
request: WorkloadCredentialRequest,
) -> Pin<Box<dyn Future<Output = Result<WorkloadCredential, WorkloadIdentityError>> + Send + '_>> { ... }
}Required Methods§
fn issue( &self, request: WorkloadCredentialRequest, ) -> Result<WorkloadCredential, WorkloadIdentityError>
fn verify( &self, token: &str, verification: &WorkloadIdentityVerification, ) -> Result<AuthenticatedServicePrincipal, WorkloadIdentityError>
Provided Methods§
Sourcefn issue_async(
&self,
request: WorkloadCredentialRequest,
) -> Pin<Box<dyn Future<Output = Result<WorkloadCredential, WorkloadIdentityError>> + Send + '_>>
fn issue_async( &self, request: WorkloadCredentialRequest, ) -> Pin<Box<dyn Future<Output = Result<WorkloadCredential, WorkloadIdentityError>> + Send + '_>>
Asynchronous credential issuance for providers backed by networked or
local-agent protocols. Existing synchronous providers inherit a
source-compatible adapter around issue.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".