EMA C++ Edition
List of all members
refinitiv::ema::access::OAuth2Credential Class Reference

OAuth2Credential class is used with OmmConsumer::SubmitOAuthCredentialRenewal to supply EMA with changed credentials. More...

Public Member Functions

Constructor
 OAuth2Credential ()
  More...
 
Destructor
 ~OAuth2Credential ()
  More...
 
Operations
OAuth2Credentialclear ()
  More...
 
OAuth2CredentialuserName (const EmaString &userName)
  More...
 
OAuth2Credentialpassword (const EmaString &password)
  More...
 
OAuth2CredentialclientId (const EmaString &clientId)
  More...
 
OAuth2CredentialclientSecret (const EmaString &clientSecret)
  More...
 
OAuth2CredentialclientJWK (const EmaString &clientJWK)
  More...
 
OAuth2Credentialaudience (const EmaString &audience)
  More...
 
OAuth2CredentialtokenScope (const EmaString &tokenScope)
  More...
 
OAuth2CredentialtakeExclusiveSignOnControl (bool takeExclusiveSignOnControl)
  More...
 
OAuth2CredentialchannelList (const EmaString &channelList)
  More...
 

Accessors

class OmmOAuth2CredentialImpl
 
const EmaStringgetUserName ()
  More...
 
const EmaStringgetPassword ()
  More...
 
const EmaStringgetClientId ()
  More...
 
const EmaStringgetClientSecret ()
  More...
 
const EmaStringgetClientJWK ()
  More...
 
const EmaStringgetAudience ()
  More...
 
const EmaStringgetTokenScope ()
  More...
 
const EmaStringgetChannelList ()
  More...
 
const bool getTakeExclusiveSignOnControl ()
  More...
 

Detailed Description

Definition at line 32 of file OAuth2Credential.h.

Constructor & Destructor Documentation

◆ OAuth2Credential()

refinitiv::ema::access::OAuth2Credential::OAuth2Credential ( )

Create an OAuth2Credential for use with OmmConsumer::SubmitOAuthCredentialRenewal

◆ ~OAuth2Credential()

refinitiv::ema::access::OAuth2Credential::~OAuth2Credential ( )

Clear out all contained EmaString by zeroing out the memory, then free everything.

Member Function Documentation

◆ audience()

OAuth2Credential& refinitiv::ema::access::OAuth2Credential::audience ( const EmaString audience)

Specifies the audience claim for the JWT. Optional and only used for V2 Client Credentials with JWT.

Parameters
[in]audiencespecifies the audience claim string
Returns
reference to this object

◆ channelList()

OAuth2Credential& refinitiv::ema::access::OAuth2Credential::channelList ( const EmaString channelList)

Specifies the connections associated with this credential set. This is a comma separated string with the name of the connections. If this is blank, then these credentials will apply to all channels that have session management enabled that do not match with any other configured oAuth2 credentials.

Parameters
[in]connectionListspecifies the list of connections associated with this set of credentials.
Returns
reference to this object

◆ clear()

OAuth2Credential& refinitiv::ema::access::OAuth2Credential::clear ( )

Zeros out and clears all allocated EMAStrings in the class.

Returns
reference to this object

◆ clientId()

OAuth2Credential& refinitiv::ema::access::OAuth2Credential::clientId ( const EmaString clientId)

Specifies the clientID used for RDP token service. Mandatory, used to specify Application ID obtained from App Generator for V1 oAuth Password Credentials, or to specify Service Account username for V2 Client Credentials and V2 Client Credentials with JWT Logins.

Parameters
[in]clientIdspecifies the clientId
Returns
reference to this object

◆ clientJWK()

OAuth2Credential& refinitiv::ema::access::OAuth2Credential::clientJWK ( const EmaString clientJWK)

Specifies the JWK formatted private key used to create the JWT. The JWT is used to authenticate with the RDP token service. Mandatory for V2 logins with client JWT logins

Parameters
[in]clientJWKspecifies the JWK formatted private key
Returns
reference to this object

◆ clientSecret()

OAuth2Credential& refinitiv::ema::access::OAuth2Credential::clientSecret ( const EmaString clientSecret)

Specifies the clientSecret, also known as the Service Account password, used to authenticate with RDP token service. Mandatory for V2 Client Credentials Logins and used in conjunction with clientID.

Parameters
[in]clientSecretspecifies the clientSecret
Returns
reference to this object

◆ getAudience()

const EmaString& refinitiv::ema::access::OAuth2Credential::getAudience ( )

Gets the audience claim for the JWT. Optional and only used for V2 Client Credentials with JWT.

Returns
audience

◆ getChannelList()

const EmaString& refinitiv::ema::access::OAuth2Credential::getChannelList ( )

Gets the connections associated with this credential set. This is a comma separated string with the name of the connections. If this is blank, then these credentials will apply to all channels that have session management enabled that do not match with any other configured oAuth2 credentials.

Returns
channe list

◆ getClientId()

const EmaString& refinitiv::ema::access::OAuth2Credential::getClientId ( )

Gets the clientID used for RDP token service. Mandatory, used to specify Application ID obtained from App Generator for V1 oAuth Password Credentials, or to specify Service Account username for V2 Client Credentials and V2 Client Credentials with JWT Logins.

Returns
client id

◆ getClientJWK()

const EmaString& refinitiv::ema::access::OAuth2Credential::getClientJWK ( )

Gets the JWK formatted private key used to create the JWT. The JWT is used to authenticate with the RDP token service. Mandatory for V2 logins with client JWT logins

Returns
client WJK

◆ getClientSecret()

const EmaString& refinitiv::ema::access::OAuth2Credential::getClientSecret ( )

Gets the clientSecret, also known as the Service Account password, used to authenticate with RDP token service. Mandatory for V2 Client Credentials Logins and used in conjunction with clientID.

Returns
client secret

◆ getPassword()

const EmaString& refinitiv::ema::access::OAuth2Credential::getPassword ( )

Gets the password for user name used to get access token. Mandatory for V1 oAuth Password Credentials logins

Returns
password

◆ getTakeExclusiveSignOnControl()

const bool refinitiv::ema::access::OAuth2Credential::getTakeExclusiveSignOnControl ( )

Gets the take exclusive sign on control value. If set to true, other applications using the same credentials will be force signed-out. Optional and only used for V1 oAuth Password Credentials logins.

Returns
takeExclusiveSignOnControl value

◆ getTokenScope()

const EmaString& refinitiv::ema::access::OAuth2Credential::getTokenScope ( )

Gets the token scope to limit the scope of generated token from the token service. Optional.

Returns
token scope

◆ getUserName()

const EmaString& refinitiv::ema::access::OAuth2Credential::getUserName ( )

Gets the user name required to authorize with the RDP token service. Mandatory for V1 oAuth Password Credentials logins.

Returns
user name

◆ password()

OAuth2Credential& refinitiv::ema::access::OAuth2Credential::password ( const EmaString password)

Specifies the password for user name used to get access token. Mandatory for V1 oAuth Password Credentials logins

Parameters
[in]passwordspecifies the password
Returns
reference to this object

◆ takeExclusiveSignOnControl()

OAuth2Credential& refinitiv::ema::access::OAuth2Credential::takeExclusiveSignOnControl ( bool  takeExclusiveSignOnControl)

Specifies the take exclusive sign on control value. If set to true, other applications using the same credentials will be force signed-out. Optional and only used for V1 oAuth Password Credentials logins.

Parameters
[in]takeExclusiveSignOnControlspecifies the takeExclusiveSignOnControl value
Returns
reference to this object

◆ tokenScope()

OAuth2Credential& refinitiv::ema::access::OAuth2Credential::tokenScope ( const EmaString tokenScope)

Specifies the token scope to limit the scope of generated token from the token service. Optional.

Parameters
[in]clientSecretspecifies the clientSecret
Returns
reference to this object

◆ userName()

OAuth2Credential& refinitiv::ema::access::OAuth2Credential::userName ( const EmaString userName)

Specifies the user name required to authorize with the RDP token service. Mandatory for V1 oAuth Password Credentials logins.

Parameters
[in]userNamespecifies the user name
Returns
reference to this object