CreateWithTokenAndName(string databaseAccessToken, string endUserName, string lookUpKey)

This method creates a new end-user security context using a database access token and end-user identity.

Declaration

// C#
public static OracleEndUserSecurityContext CreateWithTokenAndName(string databaseAccessToken, string endUserName, string lookUpKey)

Parameters

  • databaseAccessToken

    Database access token string.

  • endUserName

    End-user name to associate with the security context.

  • lookUpKey

    A unique lookup key used for additional identification, mapping, or routing logic within the database or application context.

Return Value

A new OracleEndUserSecurityContext initialized with the provided database token, end-user name, and lookup key.

Exceptions

ArgumentException - Thrown if databaseAccessToken, endUserName, or lookUpKey is null or empty.

Other exceptions may be thrown by token parsing and expiry validation checks.

Remarks

This method:

  • Validates all input strings are non-null and non-empty.

  • Constructs an internal token object from the provided string for database token.

  • Validates the database token and checks whether it has expired before returning the context.

The end-user name should be enclosed in double-quotes if the end user was declared using a quoted identifier.