pub struct WorkloadIdentityCredential { /* private fields */ }
Expand description
Enables authentication to Azure Active Directory using a client secret that was generated for an App Registration.
More information on how to configure a client secret can be found here: https://docs.microsoft.com/azure/active-directory/develop/quickstart-configure-app-access-web-apis#add-credentials-to-your-web-application
Implementations§
source§impl WorkloadIdentityCredential
impl WorkloadIdentityCredential
sourcepub fn new<T>(
http_client: Arc<dyn HttpClient>,
tenant_id: String,
client_id: String,
token: T
) -> Self
pub fn new<T>( http_client: Arc<dyn HttpClient>, tenant_id: String, client_id: String, token: T ) -> Self
Create a new WorkloadIdentityCredential
sourcepub fn set_options(&mut self, options: TokenCredentialOptions)
pub fn set_options(&mut self, options: TokenCredentialOptions)
set TokenCredentialOptions
Trait Implementations§
source§impl Debug for WorkloadIdentityCredential
impl Debug for WorkloadIdentityCredential
source§impl TokenCredential for WorkloadIdentityCredential
impl TokenCredential for WorkloadIdentityCredential
source§fn get_token<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
scopes: &'life1 [&'life2 str]
) -> Pin<Box<dyn Future<Output = Result<AccessToken>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn get_token<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
scopes: &'life1 [&'life2 str]
) -> Pin<Box<dyn Future<Output = Result<AccessToken>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Gets a
AccessToken
for the specified resourceAuto Trait Implementations§
impl !RefUnwindSafe for WorkloadIdentityCredential
impl Send for WorkloadIdentityCredential
impl Sync for WorkloadIdentityCredential
impl Unpin for WorkloadIdentityCredential
impl !UnwindSafe for WorkloadIdentityCredential
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