• Home
  • Tutorials
  • API Documentation
Search Results for

    Show / Hide Table of Contents
    • Oracle.NoSQL.SDK
      • AddReplicaOptions
        • AddReplicaOptions
        • Compartment
        • MatchETag
        • PollDelay
        • ReadUnits
        • Timeout
        • WriteUnits
      • AddReplicaRequest
        • Options
        • RegionId
      • AdminOptions
        • AdminOptions
        • PollDelay
        • Timeout
      • AdminRequest
        • Options
        • Statement
      • AdminResult
        • Output
        • State
        • Statement
        • WaitForCompletionAsync
      • AdminState
        • Complete
        • InProgress
        • value__
      • AdminStatusRequest
        • AdminResult
        • Options
      • ArrayValue
        • Add
        • ArrayValue
        • Clear
        • Contains
        • CopyTo
        • Count
        • DbType
        • IndexOf
        • Insert
        • Item
        • Remove
        • RemoveAt
        • SerializeAsJson
      • AuthorizationException
        • AuthorizationException
        • IsRetryable
      • AuthorizationStringProvider
        • ApplyAuthorizationAsync
        • AuthorizationStringProvider
        • ConfigureAuthorization
        • GetAuthorizationStringAsync
      • BadProtocolException
        • BadProtocolException
      • BatchOperationNumberLimitException
        • BatchOperationNumberLimitException
      • BinaryValue
        • AsByteArray
        • BinaryValue
        • DbType
        • SerializeAsJson
      • BooleanValue
        • AsBoolean
        • DbType
        • False
        • SerializeAsJson
        • True
      • CapacityMode
        • OnDemand
        • Provisioned
        • value__
      • ConnectionOptions
        • ConnectionOptions
        • DisableHostnameVerification
        • TrustedRootCertificateFile
        • TrustedRootCertificates
      • Consistency
        • Absolute
        • Eventual
        • value__
      • ConsumedCapacity
        • RateLimitDelay
        • ReadKB
        • ReadRateLimitDelay
        • ReadUnits
        • ToString
        • WriteKB
        • WriteRateLimitDelay
        • WriteUnits
      • ControlOperationThrottlingException
        • ControlOperationThrottlingException
      • DbType
        • Array
        • Binary
        • Boolean
        • Double
        • Empty
        • Integer
        • JsonNull
        • Long
        • Map
        • Null
        • Number
        • String
        • Timestamp
        • value__
      • DeleteIfVersionOperation
        • MatchVersion
      • DeleteIfVersionRequest<TRow>
        • MatchVersion
      • DeleteManyOptions
        • AbortIfUnsuccessful
        • DeleteManyOptions
      • DeleteOperation
        • AbortIfUnsuccessful
        • Options
        • PrimaryKey
        • TableName
      • DeleteOptions
        • Compartment
        • DeleteOptions
        • Durability
        • MatchVersion
        • Namespace
        • ReturnExisting
        • Timeout
      • DeleteRangeContinuationKey
      • DeleteRangeOptions
        • Compartment
        • ContinuationKey
        • DeleteRangeOptions
        • Durability
        • FieldRange
        • MaxWriteKB
        • Namespace
        • Timeout
      • DeleteRangeRequest
        • FieldRange
        • Options
        • PartialPrimaryKey
      • DeleteRangeResult
        • ConsumedCapacity
        • ContinuationKey
        • DeletedCount
      • DeleteRequest<TRow>
        • Options
        • PrimaryKey
      • DeleteResult<TRow>
        • ConsumedCapacity
        • ExistingModificationTime
        • ExistingRow
        • ExistingVersion
        • Success
      • DeploymentLimitException
        • DeploymentLimitException
      • DoubleValue
        • AsDouble
        • DbType
        • DoubleValue
        • SerializeAsJson
        • ToDecimal
        • ToInt32
        • ToInt64
      • DropReplicaOptions
        • Compartment
        • DropReplicaOptions
        • MatchETag
        • PollDelay
        • Timeout
      • DropReplicaRequest
        • Options
        • RegionId
      • Durability
        • CommitNoSync
        • CommitSync
        • CommitWriteNoSync
        • Durability
        • Equality
        • Equals
        • GetHashCode
        • Inequality
        • MasterSync
        • ReplicaAck
        • ReplicaSync
      • ETagMismatchException
        • ETagMismatchException
      • EvolutionLimitException
        • EvolutionLimitException
      • FieldRange
        • EndsBefore
        • EndsWith
        • EndValue
        • FieldName
        • FieldRange
        • IsEndInclusive
        • IsStartInclusive
        • StartsAfter
        • StartsWith
        • StartValue
      • FieldValue
        • AsArrayValue
        • AsBoolean
        • AsByteArray
        • AsDateTime
        • AsDecimal
        • AsDouble
        • AsInt32
        • AsInt64
        • AsMapValue
        • AsRecordValue
        • AsString
        • CompareTo
        • Count
        • DbType
        • DeserializeFromJson
        • Equality
        • Equals
        • Explicit
        • FieldValue
        • FromJsonString
        • GetHashCode
        • GreaterThan
        • GreaterThanOrEqual
        • Implicit
        • Inequality
        • Item
        • JsonNull
        • LessThan
        • LessThanOrEqual
        • Null
        • SerializeAsJson
        • ToBoolean
        • ToByteArray
        • ToDateTime
        • ToDecimal
        • ToDouble
        • ToInt32
        • ToInt64
        • ToJsonString
        • ToString
      • GetAdminStatusOptions
        • GetAdminStatusOptions
        • Timeout
      • GetIndexesRequest
        • Options
      • GetIndexOptions
        • Compartment
        • GetIndexOptions
        • Namespace
        • Timeout
      • GetIndexRequest
        • IndexName
      • GetOptions
        • Compartment
        • Consistency
        • GetOptions
        • Namespace
        • Timeout
      • GetReplicaStatsOptions
        • Compartment
        • GetReplicaStatsOptions
        • Limit
        • StartTime
        • Timeout
      • GetReplicaStatsRequest
        • Options
        • RegionId
      • GetRequest<TRow>
        • Options
        • PrimaryKey
      • GetResult<TRow>
        • ConsumedCapacity
        • ExpirationTime
        • ModificationTime
        • Row
        • Version
      • GetTableOptions
        • Compartment
        • GetTableOptions
        • Namespace
        • Timeout
      • GetTableRequest
        • Options
      • GetTableUsageOptions
        • Compartment
        • EndTime
        • FromIndex
        • GetTableUsageOptions
        • Limit
        • StartTime
        • Timeout
      • GetTableUsageRequest
        • Options
      • IAMAuthorizationProvider
        • ApplyAuthorizationAsync
        • CacheDuration
        • ConfigFile
        • ConfigureAuthorization
        • CreateWithInstancePrincipal
        • CreateWithInstancePrincipalForDelegation
        • CreateWithInstancePrincipalForDelegationFromFile
        • CreateWithOKEWorkloadIdentity
        • CreateWithOKEWorkloadIdentityAndTokenFile
        • CreateWithResourcePrincipal
        • CreateWithSessionToken
        • Credentials
        • CredentialsProvider
        • DelegationTokenFile
        • DelegationTokenProvider
        • Dispose
        • FederationEndpoint
        • IAMAuthorizationProvider
        • ProfileName
        • RefreshAhead
        • RequestTimeout
        • ServiceAccountTokenFile
        • UseInstancePrincipal
        • UseOKEWorkloadIdentity
        • UseResourcePrincipal
        • UseSessionToken
      • IAMCredentials
        • Fingerprint
        • IAMCredentials
        • Passphrase
        • PrivateKey
        • PrivateKeyFile
        • PrivateKeyPEM
        • TenantId
        • UserId
      • IAuthorizationProvider
        • ApplyAuthorizationAsync
        • ConfigureAuthorization
      • IndexExistsException
        • IndexExistsException
      • IndexLimitException
        • IndexLimitException
      • IndexNotFoundException
        • IndexNotFoundException
      • IndexResult
        • Fields
        • FieldTypes
        • IndexName
      • InstanceMetadataClient
        • Dispose
        • GetRegionAsync
        • InstanceMetadataClient
      • IntegerValue
        • AsInt32
        • DbType
        • IntegerValue
        • SerializeAsJson
        • ToDateTime
        • ToDecimal
        • ToDouble
        • ToInt64
      • InvalidAuthorizationException
        • InvalidAuthorizationException
      • IRateLimiter
        • ConsumeUnitsAsync
        • HandleThrottlingException
        • SetLimit
      • IRetryHandler
        • GetRetryDelay
        • ShouldRetry
      • IWriteOperation
        • AbortIfUnsuccessful
        • TableName
      • JsonInputOptions
        • AllowComments
        • AllowTrailingCommas
        • JsonInputOptions
        • PreferDecimal
      • JsonNullValue
        • DbType
        • SerializeAsJson
      • JsonOutputOptions
        • DateTimeAsMillis
        • DateTimeFormatString
        • DefaultDateTimeFormatString
        • Indented
        • JsonOutputOptions
      • JsonParseException
        • JsonParseException
      • KeySizeLimitException
        • KeySizeLimitException
      • KVStoreAuthorizationProvider
        • AutoRenew
        • ConfigureAuthorization
        • Credentials
        • CredentialsFile
        • CredentialsProvider
        • Dispose
        • GetAuthorizationStringAsync
        • KVStoreAuthorizationProvider
        • RequestTimeout
      • KVStoreCredentials
        • KVStoreCredentials
        • Password
        • UserName
      • ListTablesOptions
        • Compartment
        • FromIndex
        • Limit
        • ListTablesOptions
        • Namespace
        • Timeout
      • ListTablesRequest
        • Options
      • ListTablesResult
        • NextIndex
        • TableNames
      • LongValue
        • AsInt64
        • DbType
        • LongValue
        • SerializeAsJson
        • ToDateTime
        • ToDecimal
        • ToDouble
        • ToInt32
      • MapValue
        • Add
        • Clear
        • ContainsKey
        • Count
        • DbType
        • Item
        • Keys
        • MapValue
        • Remove
        • SerializeAsJson
        • TryGetValue
        • Values
      • NoSQLClient
        • AddReplicaAsync
        • AddReplicaWithCompletionAsync
        • DeleteAsync
        • DeleteIfVersionAsync
        • DeleteManyAsync
        • DeleteRangeAsync
        • Dispose
        • DropReplicaAsync
        • DropReplicaWithCompletionAsync
        • ExecuteAdminAsync
        • ExecuteAdminWithCompletionAsync
        • ExecuteTableDDLAsync
        • ExecuteTableDDLWithCompletionAsync
        • GetAdminStatusAsync
        • GetAsync
        • GetDeleteRangeAsyncEnumerable
        • GetIndexAsync
        • GetIndexesAsync
        • GetListTablesAsyncEnumerable
        • GetQueryAsyncEnumerable
        • GetReplicaStatsAsync
        • GetTableAsync
        • GetTableUsageAsync
        • GetTableUsageAsyncEnumerable
        • ListNamespacesAsync
        • ListRolesAsync
        • ListTablesAsync
        • ListUsersAsync
        • NoSQLClient
        • PrepareAsync
        • PutAsync
        • PutIfAbsentAsync
        • PutIfPresentAsync
        • PutIfVersionAsync
        • PutManyAsync
        • QueryAsync
        • ServiceType
        • SetTableLimitsAsync
        • SetTableLimitsWithCompletionAsync
        • SetTableTagsAsync
        • SetTableTagsWithCompletionAsync
        • WaitForLocalReplicaInitAsync
        • WaitForTableStateAsync
        • WriteManyAsync
      • NoSQLConfig
        • AdminPollDelay
        • AdminPollTimeout
        • AdminTimeout
        • AuthorizationProvider
        • Compartment
        • ConnectionOptions
        • Consistency
        • Durability
        • Endpoint
        • FromJsonFile
        • FromJsonString
        • MaxMemoryMB
        • Namespace
        • NoRetries
        • NoSQLConfig
        • RateLimiterCreator
        • RateLimiterPercent
        • RateLimitingEnabled
        • Region
        • RetryHandler
        • ServiceType
        • TableDDLTimeout
        • TablePollDelay
        • TablePollTimeout
        • Timeout
      • NoSQLException
        • IsRetryable
        • Message
        • NoSQLException
        • Request
      • NoSQLRateLimiter
        • ConsumeUnitsAsync
        • HandleThrottlingException
        • NoSQLRateLimiter
        • SetLimit
      • NoSQLRetryHandler
        • BaseDelay
        • ControlOperationBaseDelay
        • GetRetryDelay
        • MaxRetryAttempts
        • NoSQLRetryHandler
        • ShouldRetry
      • NullValue
        • DbType
        • SerializeAsJson
      • NumberValue
        • AsDecimal
        • DbType
        • NumberValue
        • SerializeAsJson
        • ToDouble
        • ToInt32
        • ToInt64
      • PreparedStatement
        • ClearVariables
        • ConsumedCapacity
        • CopyStatement
        • QueryPlan
        • ResultSchema
        • SetVariable
        • SQLText
        • Variables
      • PrepareOptions
        • Compartment
        • GetQueryPlan
        • GetResultSchema
        • Namespace
        • PrepareOptions
        • Timeout
      • PrepareRequest
        • Options
        • Statement
      • PutIfAbsentOperation
      • PutIfAbsentRequest<TRow>
      • PutIfPresentOperation
      • PutIfPresentRequest<TRow>
      • PutIfVersionOperation
        • MatchVersion
      • PutIfVersionRequest<TRow>
        • MatchVersion
      • PutManyOptions
        • AbortIfUnsuccessful
        • PutManyOptions
      • PutOperation
        • AbortIfUnsuccessful
        • Options
        • Row
        • TableName
      • PutOptions
        • Compartment
        • Durability
        • ExactMatch
        • IdentityCacheSize
        • IfAbsent
        • IfPresent
        • MatchVersion
        • Namespace
        • PutOptions
        • ReturnExisting
        • Timeout
        • TTL
        • UpdateTTLToDefault
      • PutRequest<TRow>
        • Options
        • Row
      • PutResult<TRow>
        • ConsumedCapacity
        • ExistingModificationTime
        • ExistingRow
        • ExistingVersion
        • GeneratedValue
        • Success
        • Version
      • QueryContinuationKey
      • QueryOptions
        • Compartment
        • Consistency
        • ContinuationKey
        • Durability
        • Limit
        • MaxMemoryMB
        • MaxReadKB
        • MaxWriteKB
        • Namespace
        • QueryOptions
        • Timeout
      • QueryRequest
      • QueryRequest<TRow>
        • IsPrepared
        • Options
        • PreparedStatement
        • Statement
      • QueryRequestBase
      • QueryResult<TRow>
        • ConsumedCapacity
        • ContinuationKey
        • Rows
      • ReadRequest
      • ReadThrottlingException
        • ReadThrottlingException
      • RecordValue
        • Equals
        • GetKeyAtIndex
        • GetValueAtIndex
        • Insert
        • Item
        • RecordValue
        • RemoveAt
      • Region
        • AF_JOHANNESBURG_1
        • AP_CHIYODA_1
        • AP_CHUNCHEON_1
        • AP_DCC_CANBERRA_1
        • AP_DCC_GAZIPUR_1
        • AP_DCC_OSAKA_1
        • AP_DCC_TOKYO_1
        • AP_HOBSONVILLE_1
        • AP_HYDERABAD_1
        • AP_IBARAKI_1
        • AP_MELBOURNE_1
        • AP_MUMBAI_1
        • AP_OSAKA_1
        • AP_SEOUL_1
        • AP_SINGAPORE_1
        • AP_SINGAPORE_2
        • AP_SYDNEY_1
        • AP_TOKYO_1
        • CA_MONTREAL_1
        • CA_TORONTO_1
        • Endpoint
        • EU_AMSTERDAM_1
        • EU_DCC_DUBLIN_1
        • EU_DCC_DUBLIN_2
        • EU_DCC_MILAN_1
        • EU_DCC_MILAN_2
        • EU_DCC_RATING_1
        • EU_DCC_RATING_2
        • EU_DCC_ROME_1
        • EU_DCC_ZURICH_1
        • EU_FRANKFURT_1
        • EU_FRANKFURT_2
        • EU_JOVANOVAC_1
        • EU_MADRID_1
        • EU_MADRID_2
        • EU_MARSEILLE_1
        • EU_MILAN_1
        • EU_PARIS_1
        • EU_STOCKHOLM_1
        • EU_ZURICH_1
        • FromRegionCodeOrId
        • FromRegionId
        • IL_JERUSALEM_1
        • ME_ABUDHABI_1
        • ME_ABUDHABI_3
        • ME_DCC_DOHA_1
        • ME_DCC_MUSCAT_1
        • ME_DUBAI_1
        • ME_JEDDAH_1
        • MX_MONTERREY_1
        • MX_QUERETARO_1
        • RegionCode
        • RegionId
        • SA_BOGOTA_1
        • SA_SANTIAGO_1
        • SA_SAOPAULO_1
        • SA_VALPARAISO_1
        • SA_VINHEDO_1
        • SecondLevelDomain
        • ToString
        • UK_CARDIFF_1
        • UK_GOV_CARDIFF_1
        • UK_GOV_LONDON_1
        • UK_LONDON_1
        • US_ASHBURN_1
        • US_CHICAGO_1
        • US_DCC_PHOENIX_1
        • US_DCC_PHOENIX_2
        • US_DCC_PHOENIX_4
        • US_DCC_SWJORDAN_1
        • US_DCC_SWJORDAN_2
        • US_GOV_ASHBURN_1
        • US_GOV_CHICAGO_1
        • US_GOV_PHOENIX_1
        • US_LANGLEY_1
        • US_LUKE_1
        • US_PHOENIX_1
        • US_SALTLAKE_2
        • US_SANJOSE_1
        • US_TACOMA_1
        • US_WESTJORDAN_1
        • Values
      • ReplicaAckPolicy
        • All
        • None
        • SimpleMajority
        • value__
      • ReplicaInfo
        • CapacityMode
        • Region
        • ReplicaName
        • ReplicaOCID
        • TableState
        • WriteUnits
      • ReplicaStatsRecord
        • CollectionTime
        • ReplicaLag
        • ToString
        • UnknownLag
      • ReplicaStatsResult
        • NextStartTime
        • StatsRecords
        • TableName
      • Request
        • Exceptions
        • LastException
        • PriorException
        • RetryCount
      • RequestSizeLimitException
        • RequestSizeLimitException
      • RequestWithTable
        • TableName
      • ResourceExistsException
        • ResourceExistsException
      • ResourceNotFoundException
        • ResourceNotFoundException
      • RetryableException
        • IsRetryable
        • RetryableException
      • RowSizeLimitException
        • RowSizeLimitException
      • RowVersion
        • Bytes
        • Encoded
        • RowVersion
        • ToString
      • SecurityInfoNotReadyException
        • SecurityInfoNotReadyException
      • ServerException
        • ServerException
      • ServiceResponseException
        • IsRetryable
        • ResponseMessage
        • ServiceResponseException
        • StatusCode
        • StatusMessage
      • ServiceType
        • Cloud
        • CloudSim
        • KVStore
        • Unspecified
        • value__
      • ServiceUnavailableException
        • ServiceUnavailableException
      • StringValue
        • AsString
        • DbType
        • SerializeAsJson
        • StringValue
        • ToBoolean
        • ToByteArray
        • ToDateTime
        • ToDecimal
        • ToDouble
        • ToInt32
        • ToInt64
      • SyncPolicy
        • NoSync
        • Sync
        • value__
        • WriteNoSync
      • TableBusyException
        • TableBusyException
      • TableCompletionOptions
        • PollDelay
        • TableCompletionOptions
      • TableDDLOptions
        • Compartment
        • DefinedTags
        • FreeFormTags
        • MatchETag
        • Namespace
        • PollDelay
        • TableDDLOptions
        • TableLimits
        • Timeout
      • TableDDLRequest
        • Options
        • Statement
      • TableExistsException
        • TableExistsException
      • TableLimitException
        • TableLimitException
      • TableLimits
        • CapacityMode
        • ReadUnits
        • StorageGB
        • TableLimits
        • WriteUnits
      • TableLimitsRequest
        • TableLimits
      • TableNotFoundException
        • TableNotFoundException
      • TableNotReadyException
        • TableNotReadyException
      • TableOperationRequest
      • TableResult
        • CompartmentId
        • DefinedTags
        • ETag
        • FreeFormTags
        • IsLocalReplicaInitialized
        • IsReplicated
        • IsSchemaFrozen
        • Namespace
        • Replicas
        • TableDDL
        • TableLimits
        • TableName
        • TableOCID
        • TableSchema
        • TableState
        • WaitForCompletionAsync
      • TableSizeLimitException
        • TableSizeLimitException
      • TableState
        • Active
        • Creating
        • Dropped
        • Dropping
        • Updating
        • value__
      • TableTagsRequest
        • DefinedTags
        • FreeFormTags
      • TableUsageRecord
        • Duration
        • MaxShardUsagePercent
        • ReadThrottleCount
        • ReadUnits
        • StartTime
        • StorageGB
        • StorageThrottleCount
        • TableUsageRecord
        • ToString
        • WriteThrottleCount
        • WriteUnits
      • TableUsageResult
        • NextIndex
        • TableName
        • UsageRecords
      • TimestampValue
        • AsDateTime
        • DbType
        • SerializeAsJson
        • TimestampValue
        • ToInt64
      • TimeToLive
        • DoNotExpire
        • FromExpirationTime
        • OfDays
        • OfHours
        • TimeUnit
        • ToExpirationTime
        • ToString
        • Value
      • TTLTimeUnit
        • Days
        • Hours
        • value__
      • UnauthorizedException
        • UnauthorizedException
      • UnsupportedProtocolException
        • UnsupportedProtocolException
      • UnsupportedQueryVersionException
        • UnsupportedQueryVersionException
      • UserInfo
        • Id
        • Name
      • WriteManyOptions
        • AbortIfUnsuccessful
        • Compartment
        • Durability
        • Namespace
        • Timeout
        • WriteManyOptions
      • WriteManyRequest
      • WriteManyRequest<TRow>
        • DeleteManyOptions
        • Operations
        • PutManyOptions
        • TableName
        • WriteManyOptions
      • WriteManyResult<TRow>
        • ConsumedCapacity
        • FailedOperationIndex
        • FailedOperationResult
        • Results
        • Success
      • WriteOperationCollection
        • AddDelete
        • AddDeleteIfVersion
        • AddPut
        • AddPutIfAbsent
        • AddPutIfPresent
        • AddPutIfVersion
        • Clear
        • Count
        • WriteOperationCollection
      • WriteOperationResult<TRow>
        • ExistingModificationTime
        • ExistingRow
        • ExistingVersion
        • GeneratedValue
        • Success
        • Version
      • WriteRequest
      • WriteThrottlingException
        • WriteThrottlingException

    Class IAMAuthorizationProvider

    Authorization provider for the Oracle NoSQL Database Cloud Service.
    Inheritance
    Object
    IAMAuthorizationProvider
    Implements
    IAuthorizationProvider
    IDisposable
    Namespace: Oracle.NoSQL.SDK
    Assembly: Oracle.NoSQL.SDK.dll
    Syntax
    public class IAMAuthorizationProvider : Object, IAuthorizationProvider
    Remarks

    This provider class is used to authorize operations using Oracle Cloud Infrastructure Identity and Access Management (IAM). The instance of this class should be set as AuthorizationProvider in the initial configuration.

    See Overview of Oracle Cloud Infrastructure Identity and Access Management for information on IAM components and how they work together to provide security for Oracle Cloud services.

    All operations require a request signature that is used by the system to authorize the operation. The request signature may be created using one of the following:

    • Specific user's identity.
      See the information below on what credentials are required and how to obtain them, as well how these credentials may be provided to IAMAuthorizationProvider.
    • Instance Principal.
      You may use Instance Principal when calling Oracle NoSQL Database Cloud Service from a compute instance in the Oracle Cloud Infrastructure (OCI). See Calling Services from an Instance for more information. The driver authenticates with the instance principal and obtains a security token issued by IAM to create the request signature. Use Instance Principal by setting UseInstancePrincipal to true or calling CreateWithInstancePrincipal(String) or CreateWithInstancePrincipalForDelegation.
    • Resource Principal.
      You may use Resource Principal when calling Oracle NoSQL Database Cloud Service from other Oracle Cloud service resource such as Functions . See Accessing Other Oracle Cloud Infrastructure Resources from Running Functions for more information. The driver obtains a resource provider session token (RPST) that enables the resource such as function to authenticate itself. The RPST is used to create the request signature. Use Resource Principal by setting UseResourcePrincipal to true or calling CreateWithResourcePrincipal().
    • Oracle Container Engine for Kubernetes (OKE) workload identity.
      You may use OKE workload identity when running an application inside Kubernetes cluster. For information on Container Engine for Kubernetes, see Overview of Container Engine for Kubernetes . Also see Granting Workloads Access to OCI Resources for more details on OKE workload identity. Use OKE workload identity by setting UseOKEWorkloadIdentity to true or calling CreateWithOKEWorkloadIdentity or CreateWithOKEWorkloadIdentityAndTokenFile(String). See UseOKEWorkloadIdentity for more information.
    • Session Token.
      Session Token-Based Authentication uses temporary session token read from a token file. The path of the token file is read from a profile in OCI configuration file as the value of field security_token_file. See SDK Configuration File for details of the file's contents and format.
      For session token-based authentication, the properties required in the OCI config file by the driver are tenancy for tenant OCID, security_token_file for security token file and key_file for private key file. You may also specify pass_phrase and region properties. The same considerations apply as described below when using OCI config file with specific user's identity.
      You can use the OCI CLI to authenticate and create a session token (together with the profile in OCI config file that uses that session token), see Token-based Authentication for the CLI . Use Session Token by setting UseSessionToken to true or calling one of CreateWithSessionToken methods.

    Note that when using Instance Principal, Resource Principal or OKE workload identity, you must specify the compartment id (OCID), either as Compartment or in the operation options. You must use compartment id (OCID) and not the compartment name. This also means that you may not prefix the table name with the compartment name when passing the table name to the NoSQLClient APIs or in queries. These restrictions do not apply when using the specific user identity, which is best for naming flexibility, allowing both compartment names and OCIDs.

    The driver caches the request signature for a configurable duration CacheDuration with a maximum of 5 minutes. In addition, the driver can optionally renew the request signature in the background ahead of its expiration. The automatic renewal is controlled by RefreshAhead property.

    The information that follows describes the steps to use the specific user identity and does not apply to using instance principal or resource principal.

    To use the specific user's identity, you must provide the following credentials:

    • Tenancy OCID. This is Oracle Cloud ID (OCID) for your tenancy. See Resource Identifiers for information on OCIDs.
    • User's OCID. This is Oracle Cloud ID (OCID) for the user in your tenancy. See Resource Identifiers for information on OCIDs.
    • API Signing Key. This is public-private key pair used to sign the API requests. See Required Keys and OCIDs for details. In particular, the private key is needed to generate the request signature.
    • Public Key Fingerprint. This is an identifier of the public key of the API Signing Key pair.
    • Passphrase for the private key of API Signing Key pair if the private key is encrypted.

    To enable signing of API requests, perform the following steps:

    1. Generate the key pair described above.
    2. Upload the public key.
    3. Obtain the tenancy and user OCIDs and the public key fingerprint.
    Required Keys and OCIDs describes these steps in detail.

    You may set the credentials using one of the following, in order of increasing security:

    1. As IAMCredentials object set as Credentials or using IAMAuthorizationProvider(IAMCredentials) constructor. You must set the properties TenantId, UserId, Fingerprint and one of PrivateKey, PrivateKeyPEM or PrivateKeyFile. In addition, you must set Passphrase if the private key is encrypted.
    2. As part of the OCI configuration file. See SDK and CLI Configuration File for information on the OCI configuration file format. Set properties ConfigFile and ProfileName or use IAMAuthorizationProvider(String, String) constructor. Because both of these properties have default values, the default instance of IAMAuthorizationProvider is configured to use credentials from the default OCI configuration file with the default profile name. In fact, the driver will create this default instance if you don't set AuthorizationProvider. Note that the driver will load the credentials from the OCI configuration file only once.
      Note that if using an OCI configuration file, you may also specify region identifier in the same profile as your credentials. In this case, you need not specify either region or endpoint in NoSQLConfig. In particular, if you use the default OCI config file (~/.oci/config) and default profile name (DEFAULT) and do not need to customize any other configuration properties, you may create NoSQLClient instance without providing any arguments to the NoSQLClient constructor. See NoSQLClient(NoSQLConfig) for more information.
    3. Specify your own credentials provider delegate as CredentialsProvider or use IAMAuthorizationProvider(Func<CancellationToken, Task<IAMCredentials>>) constructor. This is the most secure option because you can choose where the credentials are stored and how they are accessed. The credentials provider delegate will be called every time the credentials are needed (when the request signature is renewed).

    The private key, if provided in a file or as a string, must be in PEM format. It can be either in PKCS#8 format (starts with -----BEGIN PRIVATE KEY----- or -----BEGIN ENCRYPTED PRIVATE KEY-----) or PKCS#1 format (starts with -----BEGIN RSA PRIVATE KEY-----). PKCS#8 format is preferred. There is a limitation for encrypted private keys in PKCS#1 format in that it must use AES encryption (with key sizes of 128, 192 or 256 bits). Otherwise, if you have an encrypted private key in PKCS#1 format, you can convert it to PKCS#8 using openssl:
    openssl pkcs8 -topk8 -inform PEM -outform PEM -in encrypted_pkcs1_key.pem -out encrypted_pkcs8_key.pem

    The examples show the ways to instantiate IAMAuthorizationProvider for different authorization scenarios outlined above.

    Examples
    Instantiating IAMAuthorizationProvider with specified credentials.
        var config = new NoSQLConfig
        {
        Region = Region.AP_SYDNEY_1,
        AuthorizationProvider = new IAMAuthorizationProvider(
            new IAMCredentials
            {
                TenantId = "ocid1.tenancy.oc...................",
                UserId = "ocid1.user.oc........................",
                Fingerprint = "aa:aa:aa:aa:....................",
                PrivateKeyFile = "~/my_app/security/oci_api_key.pem",
                Passphrase = "................................."
            }
        };
    Specifying IAMAuthorizationProvider with specified credentials in JSON configuration file (note that storing the passphrase in the configuration file is not secure, use this for development/testing only).
    {
        "Region": "ap-sydney-1",
        "AuthorizationProvider": {
            "AuthorizationType": "IAM",
            "Credentials": {
                "TenantId": "ocid1.tenancy.oc...................",
                "UserId": "ocid1.user.oc........................",
                "Fingerprint": "aa:aa:aa:aa:....................",
                "PrivateKeyFile": "~/my_app/security/oci_api_key.pem",
                "Passphrase": "................................."
            }
        }
    }
    Instantiating IAMAuthorizationProvider using the credentials in the OCI configuration file
        var config = new NoSQLConfig
        {
            Region = Region.AP_TOKYO_1,
            AuthorizationProvider = new IAMAuthorizationProvider(
                "~/my_app/.oci/config", "Jane")
        };
    Specifying IAMAuthorizationProvider in JSON configuration file using the credentials in OCI configuration file.
    {
        "Region": "ap-tokyo-1",
        "AuthorizationProvider": {
            "AuthorizationType": "IAM",
            "ConfigFile": "~/my_app/.oci/config",
            "ProfileName": "Jane"
        }
    }
    Instantiating IAMAuthorizationProvider using credentials supplied by the credentials provider delegate.
        ...
        public static async Task<IAMCredentials> LoadCredentialsAsync(
            CancellationToken cancellationToken)
        {
            // Load the credentials from a secure location.
            return new IAMCredentials
            {
                TenantId = "...",
                UserId = "...",
                ...
            };
        }
        ...
        var config = new NoSQLConfig
        {
            Region = Region.US_SANJOSE_1,
            AuthorizationProvider = new IAMAuthorizationProvider(
                LoadCredentialsAsync)
        };
    Instantiating IAMAuthorizationProvider using instance principal.
        var config = new NoSQLConfig
        {
            Region = Region.SA_SAOPAULO_1,
            AuthorizationProvider =
                IAMAuthorizationProvider.CreateWithInstancePrincipal()
        };
    Specifying IAMAuthorizationProvider using instance principal in JSON configuration file.
    {
        "Region": "sa-saopaulo-1",
        "AuthorizationProvider": {
            "AuthorizationType": "IAM",
            "UseInstancePrincipal": true
    }
    Instantiating IAMAuthorizationProvider using instance principal with delegation token.
        // Obtain delegation token somehow.
        var delegationToken = GetDelegationToken();
        var config = new NoSQLConfig
        {
            Region = Region.SA_SAOPAULO_1,
            AuthorizationProvider =
                IAMAuthorizationProvider
                    .CreateWithInstancePrincipalForDelegation(
                        delegationToken);
        };
    Specifying IAMAuthorizationProvider using instance principal with delegation token in JSON configuration file (the delegation token is stored in a separate file "delegation_token_file").
    {
        "Region": "sa-saopaulo-1",
        "AuthorizationProvider": {
            "AuthorizationType": "IAM",
            "UseInstancePrincipal": true,
            "DelegationTokenFile": "path/to/delegation_token_file"
        }
    }
    Instantiating IAMAuthorizationProvider using resource principal.
        var config = new NoSQLConfig
        {
            Region = Region.SA_SAOPAULO_1,
            AuthorizationProvider =
                IAMAuthorizationProvider.CreateWithResourcePrincipal()
        };
    Specifying IAMAuthorizationProvider using resource principal in JSON configuration file.
    {
        "Region": "sa-saopaulo-1",
        "AuthorizationProvider": {
            "AuthorizationType": "IAM",
            "UseResourcePrincipal": true
        }
    }
    Instantiating IAMAuthorizationProvider using OKE workload identity.
        var config = new NoSQLConfig
        {
            Region = Region.AP_MUMBAI_1,
            AuthorizationProvider =	IAMAuthorizationProvider
                .CreateWithOKEWorkloadIdentity()
        };
    Specifying IAMAuthorizationProvider using OKE workload identity in JSON configuration file.
        {
            "Region": "sa-saopaulo-1",
            "AuthorizationProvider": {
                "AuthorizationType": "IAM",
                "UseOKEWorkloadIdentity": true
            }
        }
    Instantiating IAMAuthorizationProvider using OKE workload identity and provided service account token.
        // Obtain service account token somehow.
        var serviceAccountToken = GetServiceAccountToken();
        var config = new NoSQLConfig
        {
            Region = Region.AP_MUMBAI_1,
            AuthorizationProvider =	IAMAuthorizationProvider
                .CreateWithOKEWorkloadIdentity(serviceAccountToken)
        };
    Specifying IAMAuthorizationProvider using OKE workload identity with provided service account token in JSON configuration file (service account token is stored in a separate file "service_account_token_file").
        {
            "Region": "sa-saopaulo-1",
            "AuthorizationProvider": {
                "AuthorizationType": "IAM",
                "UseOKEWorkloadIdentity": true,
                "ServiceAccountTokenFile": "path/to/service_account_token_file"
            }
        }
    Instantiating IAMAuthorizationProvider using session token.
        var config = new NoSQLConfig
        {
            Region = Region.AP_SYDNEY_1,
            AuthorizationProvider =
                IAMAuthorizationProvider.CreateWithSessionToken(
                    "~/my_app/.oci/config", "Jane")
        };
    Specifying IAMAuthorizationProvider using session token in JSON configuration file.
    {
        "Region": "ap-sydney-1",
        "AuthorizationProvider": {
            "AuthorizationType": "IAM",
            "UseSessionToken": true,
            "ConfigFile": "~/my_app/.oci/config",
            "ProfileName": "Jane"
        }
    }

    Constructors

    Name Description
    IAMAuthorizationProvider() Initializes a new instance of IAMAuthorizationProvider with default configuration.
    IAMAuthorizationProvider(IAMCredentials) Initializes a new instance of IAMAuthorizationProvider with the specified credentials.
    IAMAuthorizationProvider(Func<CancellationToken, Task<IAMCredentials>>) Initializes a new instance of IAMAuthorizationProvider using specified credentials provider delegate.
    IAMAuthorizationProvider(String) Initializes a new instance of IAMAuthorizationProvider using the default OCI configuration file and the specified profile name.
    IAMAuthorizationProvider(String, String) Initializes a new instance of IAMAuthorizationProvider using specified OCI configuration file and profile name.

    Properties

    Name Description
    CacheDuration Gets or sets the duration of the request signature in the cache.
    ConfigFile Gets or sets the path of the OCI configuration file.
    Credentials Gets or sets the credentials for the specific user identity.
    CredentialsProvider Gets or sets the credentials provider delegate.
    DelegationTokenFile Gets or sets the delegation token file path.
    DelegationTokenProvider Gets or sets the delegation token provider delegate.
    FederationEndpoint Gets or sets the federation endpoint for use with instance principal.
    ProfileName Gets or sets the profile name in the OCI configuration file.
    RefreshAhead Gets or sets the value indicating when to automatically refresh the request signature before its expiration.
    RequestTimeout Gets or sets the timeout for requests made to the authorization service.
    ServiceAccountTokenFile Gets or sets the service account token file path.
    UseInstancePrincipal Gets or sets the value that determines whether to use an instance principal.
    UseOKEWorkloadIdentity Gets or sets a value that determines whether to use authorization for Oracle Container Engine for Kubernetes (OKE) workload identity. This authorization can only be used inside Kubernetes pods.
    UseResourcePrincipal Gets or sets the value that determines whether to use a resource principal.
    UseSessionToken Gets or sets the value that determines whether to use a session token.

    Methods

    Name Description
    ApplyAuthorizationAsync(Request, HttpRequestMessage, CancellationToken) Obtains and adds the required HTTP headers for authorization with IAM.
    ConfigureAuthorization(NoSQLConfig) Validates and configures the authorization provider.
    CreateWithInstancePrincipal(String) Creates a new instance of IAMAuthorizationProvider using the instance principal.
    CreateWithInstancePrincipalForDelegation(Func<CancellationToken, Task<String>>, String) Creates a new instance of IAMAuthorizationProvider using an instance principal with a delegation token using the specified delegation token provider delegate.
    CreateWithInstancePrincipalForDelegation(String, String) Creates a new instance of IAMAuthorizationProvider using an instance principal with a delegation token.
    CreateWithInstancePrincipalForDelegationFromFile(String, String) Creates a new instance of IAMAuthorizationProvider using an instance principal with a delegation token using the specified delegation file.
    CreateWithOKEWorkloadIdentity(Func<CancellationToken, Task<String>>) Creates a new instance of IAMAuthorizationProvider using OKE workload identity and specified service account token provider delegate.
    CreateWithOKEWorkloadIdentity(String) Creates a new instance of IAMAuthorizationProvider using OKE workload identity.
    CreateWithOKEWorkloadIdentityAndTokenFile(String) Creates a new instance of IAMAuthorizationProvider using OKE workload identity and specified service account token file.
    CreateWithResourcePrincipal() Creates a new instance of IAMAuthorizationProvider using the resource principal.
    CreateWithSessionToken() Creates a new instance of IAMAuthorizationProvider using session token-based authentication with the default OCI configuration file and the default profile name.
    CreateWithSessionToken(String) Creates a new instance of IAMAuthorizationProvider using session token-based authentication with the default OCI configuration file and the specified profile name.
    CreateWithSessionToken(String, String) Creates a new instance of IAMAuthorizationProvider using session token-based authentication with the specified OCI configuration file and profile name.
    Dispose() Releases resources used by this IAMAuthorizationProvider instance.
    Dispose(Boolean) Releases the unmanaged resources used by this instance and optionally releases the managed resources.
    In This Article
    Back to top Copyright © 2020, 2024 Oracle and/or its affiliates. All rights reserved.