SDK for PHP 3.x

AssumeRoleWithWebIdentityCredentialProvider
in package

Credential provider that provides credentials via assuming a role with a web identity More Information, see: https://docs.aws.amazon.com/aws-sdk-php/v3/api/api-sts-2011-06-15.html#assumerolewithwebidentity

Table of Contents

Constants

ENV_RETRIES  = 'AWS_METADATA_SERVICE_NUM_ATTEMPTS'
ERROR_MSG  = "Missing required 'AssumeRoleWithWebIdentityCredentialProvider' configuration option: "

Methods

__construct()  : mixed
The constructor attempts to load config from environment variables.
__invoke()  : PromiseInterface
Loads assume role with web identity credentials.

Constants

ENV_RETRIES

public mixed ENV_RETRIES = 'AWS_METADATA_SERVICE_NUM_ATTEMPTS'

ERROR_MSG

public mixed ERROR_MSG = "Missing required 'AssumeRoleWithWebIdentityCredentialProvider' configuration option: "

Methods

__construct()

The constructor attempts to load config from environment variables.

public __construct([array<string|int, mixed> $config = [] ]) : mixed

If not set, the following config options are used:

  • WebIdentityTokenFile: full path of token filename
  • RoleArn: arn of role to be assumed
  • SessionName: (optional) set by SDK if not provided
Parameters
$config : array<string|int, mixed> = []

Configuration options

Tags
throws
InvalidArgumentException
On this page