Class X509FederationClient
This class gets a security token from the auth service by signing the request with a
PKI issued leaf certificate, passing along a temporary public key that is bounded to the
security token, and the leaf certificate.
Inheritance
X509FederationClient
Assembly: OCI.DotNetSDK.Common.dll
Syntax
public class X509FederationClient : IFederationClient
Constructors
X509FederationClient(string, string, IX509CertificateSupplier, ISessionKeySupplier, HashSet<IX509CertificateSupplier>)
Declaration
public X509FederationClient(string federationEndpoint, string tenancyId, IX509CertificateSupplier leafCertificateSupplier, ISessionKeySupplier sessionKeySupplier, HashSet<IX509CertificateSupplier> intermediateCertificateSuppliers)
Parameters
X509FederationClient(string, string, IX509CertificateSupplier, ISessionKeySupplier, HashSet<IX509CertificateSupplier>, string, IFederationRequestSigner)
Declaration
public X509FederationClient(string federationEndpoint, string tenancyId, IX509CertificateSupplier leafCertificateSupplier, ISessionKeySupplier sessionKeySupplier, HashSet<IX509CertificateSupplier> intermediateCertificateSuppliers, string purpose, IFederationRequestSigner federationRequestSigner)
Parameters
Fields
logger
Declaration
protected static Logger logger
Field Value
Properties
Client
Declaration
public HttpClient Client { get; set; }
Property Value
FederationSigner
Declaration
public IFederationRequestSigner FederationSigner { get; set; }
Property Value
Methods
GetSecurityToken()
Gets a security token. If there is already a valid token cached, it will be returned.
Else this will make a call to the auth service to get a new token, using the provided suppliers.
This method is thread-safe.
Declaration
public string GetSecurityToken()
Returns
Type |
Description |
string |
The security token.
|
GetStringClaim(string)
Return a claim embedded in the security token.
Declaration
public string GetStringClaim(string key)
Parameters
Type |
Name |
Description |
string |
key |
key the name of the claim.
|
Returns
Type |
Description |
string |
The value of the claim.
|
RefreshAndGetSecurityToken()
Gets a security token from the federation endpoint. This will always retreive
a new token from the federation endpoint and does not use a cached token.
Declaration
public string RefreshAndGetSecurityToken()
Returns
Type |
Description |
string |
A security token that can be used to authenticate requests.
|
Implements