Struct graph_oauth::ClientSecretCredential
source · pub struct ClientSecretCredential { /* private fields */ }
Expand description
Client Credentials flow using a client secret.
The OAuth 2.0 client credentials grant flow permits a web service (confidential client) to use its own credentials, instead of impersonating a user, to authenticate when calling another web service. The grant specified in RFC 6749, sometimes called two-legged OAuth, can be used to access web-hosted resources by using the identity of an application. This type is commonly used for server-to-server interactions that must run in the background, without immediate interaction with a user, and is often referred to as daemons or service accounts.
See Microsoft identity platform and the OAuth 2.0 client credentials flow
Implementations§
Trait Implementations§
source§impl Clone for ClientSecretCredential
impl Clone for ClientSecretCredential
source§fn clone(&self) -> ClientSecretCredential
fn clone(&self) -> ClientSecretCredential
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for ClientSecretCredential
impl Debug for ClientSecretCredential
source§impl From<ClientSecretCredential> for ConfidentialClientApplication<ClientSecretCredential>
impl From<ClientSecretCredential> for ConfidentialClientApplication<ClientSecretCredential>
source§fn from(value: ClientSecretCredential) -> Self
fn from(value: ClientSecretCredential) -> Self
Converts to this type from the input type.
source§impl TokenCache for ClientSecretCredential
impl TokenCache for ClientSecretCredential
type Token = Token
fn get_token_silent(&mut self) -> Result<Self::Token, AuthExecutionError>
fn get_token_silent_async<'life0, 'async_trait>(
&'life0 mut self
) -> Pin<Box<dyn Future<Output = Result<Self::Token, AuthExecutionError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn with_force_token_refresh(&mut self, force_token_refresh: ForceTokenRefresh)
source§impl TokenCredentialExecutor for ClientSecretCredential
impl TokenCredentialExecutor for ClientSecretCredential
fn form_urlencode(&mut self) -> IdentityResult<HashMap<String, String>>
fn client_id(&self) -> &Uuid
fn azure_cloud_instance(&self) -> AzureCloudInstance
fn basic_auth(&self) -> Option<(String, String)>
fn app_config(&self) -> &AppConfig
fn uri(&mut self) -> IdentityResult<Url>
fn request_parts(&mut self) -> IdentityResult<AuthorizationRequestParts>
fn build_request(&mut self) -> AuthExecutionResult<RequestBuilder>
fn build_request_async(&mut self) -> AuthExecutionResult<RequestBuilder>
fn extra_header_parameters(&self) -> &HeaderMap
fn issuer(&self) -> Result<Url, ParseError>
fn extra_query_parameters(&self) -> &HashMap<String, String>
fn execute(&mut self) -> AuthExecutionResult<Response>
fn execute_async<'life0, 'async_trait>(
&'life0 mut self
) -> Pin<Box<dyn Future<Output = AuthExecutionResult<Response>> + Send + 'async_trait>>where
Self: Send + 'async_trait,
'life0: 'async_trait,
Auto Trait Implementations§
impl Freeze for ClientSecretCredential
impl !RefUnwindSafe for ClientSecretCredential
impl Send for ClientSecretCredential
impl Sync for ClientSecretCredential
impl Unpin for ClientSecretCredential
impl !UnwindSafe for ClientSecretCredential
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