Activating or Deactivating a Trusted Session

You can add an additional layer of security to your OUTSCALE account, and all its EIM users, by activating a trusted session via the Trusted Env feature. For more information about this feature, see About Your API Access Policy > Trusted Session.

Activating a trusted session enables a root user to:

To activate a trusted session, you must meet the following requirements:

  • All your access keys must have expiration dates.

  • All your API access rules must specify a CA.

You can deactivate a trusted session at any time.

Activating or Deactivating a Trusted Session Using Cockpit

Activating a Trusted Session

Before you begin:

  • Make sure all your access keys have an expiration date and are trusted. For more information, see About Access Keys.

  • Make sure all your API access rules specify a CA. For more information, see About API Access Rules.

  1. In the API Protection dashboard, click the Trusted Env Secure Mode tab.
    The current status of the trusted session and the restrictions it enforces are displayed.

  2. Click IconEdit Update.
    The UPDATE SECURE MODE dialog box appears.

  3. Click the switch toggle to set it to Enable.

  4. In the Access keys lifespan field, type the maximum possible lifetime for your access keys and select a unit of time in the drop-down list.
    The corresponding value in seconds is displayed next to the field.

    • This value must be between 1 second and 100 years.

    • This value must be greater than the remaining lifetime of each access key of your OUTSCALE account, as it is required for access keys to have an expiration date.

  5. Click Update.
    The trusted session is activated.

Once the trusted session is activated, you, and all your EIM users must log in to Cockpit using multi-factor authentication. For security reasons, certain API methods are excluded from the scope of a trusted session. For more information, see About Your API Access Policy > Scope of a Trusted Session.

Deactivating a Trusted Session

  1. In the API Protection dashboard, click the Trusted Env Secure Mode tab.
    The current status of the trusted session and the restrictions it enforces are displayed.

  2. Click IconEdit Update.
    The UPDATE SECURE MODE dialog box appears.

  3. Click the switch toggle to set it to Disable.

  4. Click Update.
    The trusted session is deactivated.

Activating or Deactivating a Trusted Session Using octl

Activating a Trusted Session

Before you begin:

To activate a trusted session using octl, use the command UpdateApiAccessPolicy following this syntax:

Request sample
$ octl iaas api UpdateApiAccessPolicy \
  --profile "default" \
  --MaxAccessKeyExpirationSeconds 1 \
  --RequireTrustedEnv=true

This command contains the following options that you need to specify:

  • (optional) profile: The named profile you want to use, created when configuring octl. For more information, see the octl GitHub repository.

  • MaxAccessKeyExpirationSeconds: The maximum possible lifetime for your access keys, in seconds.

    This value can go from 0 to 3153600000 (100 years), both included. However, when activating a trusted session, it must be greater than the remaining lifetime of each access key of your OUTSCALE account, as it is required for access keys to have an expiration date.

  • RequireTrustedEnv: If true, a trusted session is activated.

The UpdateApiAccessPolicy command returns the following elements:

  • ApiAccessPolicy: Information about your API access policy. This element contains the following information:

    • MaxAccessKeyExpirationSeconds: The maximum possible lifetime for your access keys, in seconds.

    • RequireTrustedEnv: If true, a trusted session is activated.

  • ResponseContext: Information about the context of the response. This element contains the following information:

    • RequestId: The ID of the request.

Result sample
{
  "ApiAccessPolicy": {
    "MaxAccessKeyExpirationSeconds": 1,
    "RequireTrustedEnv": true
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

You have activated a trusted session.

Deactivating a Trusted Session

Before you begin:

To deactivate a trusted session using octl, use the command UpdateApiAccessPolicy following this syntax:

Request sample
$ octl iaas api UpdateApiAccessPolicy \
  --profile "default" \
  --MaxAccessKeyExpirationSeconds 1 \
  --RequireTrustedEnv=false

This command contains the following options that you need to specify:

  • (optional) profile: The named profile you want to use, created when configuring octl. For more information, see the octl GitHub repository.

  • MaxAccessKeyExpirationSeconds: The maximum possible lifetime for your access keys, in seconds. This value can go from 0 to 3153600000 (100 years), both included.

  • RequireTrustedEnv: If false, the trusted session is deactivated.

The UpdateApiAccessPolicy command returns the following elements:

  • ApiAccessPolicy: Information about your API access policy. This element contains the following information:

    • MaxAccessKeyExpirationSeconds: The maximum possible lifetime for your access keys, in seconds.

    • RequireTrustedEnv: If false, the trusted session is deactivated.

  • ResponseContext: Information about the context of the response. This element contains the following information:

    • RequestId: The ID of the request.

Result sample
{
  "ApiAccessPolicy": {
    "MaxAccessKeyExpirationSeconds": 1,
    "RequireTrustedEnv": false
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

You have deactivated the trusted session.

Activating or Deactivating a Trusted Session Using OSC CLI

Activating a Trusted Session

Before you begin:

To activate a trusted session using OSC CLI, use the command UpdateApiAccessPolicy following this syntax:

Request sample
$ osc-cli api UpdateApiAccessPolicy \
  --profile "default" \
  --MaxAccessKeyExpirationSeconds 1 \
  --RequireTrustedEnv True

This command contains the following options that you need to specify:

  • (optional) profile: The named profile you want to use, created when configuring OSC CLI. For more information, see the OSC CLI GitHub repository.

  • MaxAccessKeyExpirationSeconds: The maximum possible lifetime for your access keys, in seconds.

    This value can go from 0 to 3153600000 (100 years), both included. However, when activating a trusted session, it must be greater than the remaining lifetime of each access key of your OUTSCALE account, as it is required for access keys to have an expiration date.

  • RequireTrustedEnv: If True, a trusted session is activated.

The UpdateApiAccessPolicy command returns the following elements:

  • ApiAccessPolicy: Information about your API access policy. This element contains the following information:

    • MaxAccessKeyExpirationSeconds: The maximum possible lifetime for your access keys, in seconds.

    • RequireTrustedEnv: If true, a trusted session is activated.

  • ResponseContext: Information about the context of the response. This element contains the following information:

    • RequestId: The ID of the request.

Result sample
{
  "ApiAccessPolicy": {
    "MaxAccessKeyExpirationSeconds": 1,
    "RequireTrustedEnv": true
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

You have activated a trusted session.

Deactivating a Trusted Session

Before you begin:

To deactivate a trusted session using OSC CLI, use the command UpdateApiAccessPolicy following this syntax:

Request sample
$ osc-cli api UpdateApiAccessPolicy \
  --profile "default" \
  --MaxAccessKeyExpirationSeconds 1 \
  --RequireTrustedEnv False

This command contains the following options that you need to specify:

  • (optional) profile: The named profile you want to use, created when configuring OSC CLI. For more information, see the OSC CLI GitHub repository.

  • MaxAccessKeyExpirationSeconds: The maximum possible lifetime for your access keys, in seconds. This value can go from 0 to 3153600000 (100 years), both included.

  • RequireTrustedEnv: If False, the trusted session is deactivated.

The UpdateApiAccessPolicy command returns the following elements:

  • ApiAccessPolicy: Information about your API access policy. This element contains the following information:

    • MaxAccessKeyExpirationSeconds: The maximum possible lifetime for your access keys, in seconds.

    • RequireTrustedEnv: If false, the trusted session is deactivated.

  • ResponseContext: Information about the context of the response. This element contains the following information:

    • RequestId: The ID of the request.

Result sample
{
  "ApiAccessPolicy": {
    "MaxAccessKeyExpirationSeconds": 1,
    "RequireTrustedEnv": false
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

You have deactivated the trusted session.

Activating or Deactivating a Trusted Session Using oapi-cli

Activating a Trusted Session

Before you begin:

To activate a trusted session using oapi-cli, use the command UpdateApiAccessPolicy following this syntax:

Request sample
$ oapi-cli --profile "default" UpdateApiAccessPolicy \
  --MaxAccessKeyExpirationSeconds 1 \
  --RequireTrustedEnv True

This command contains the following attributes that you need to specify:

  • (optional) profile: The named profile you want to use, created when configuring oapi-cli. For more information, see the oapi-cli GitHub repository.

  • MaxAccessKeyExpirationSeconds: The maximum possible lifetime for your access keys, in seconds.

    This value can go from 0 to 3153600000 (100 years), both included. However, when activating a trusted session, it must be greater than the remaining lifetime of each access key of your OUTSCALE account, as it is required for access keys to have an expiration date.

  • RequireTrustedEnv: If True, a trusted session is activated.

The UpdateApiAccessPolicy command returns the following elements:

  • ApiAccessPolicy: Information about your API access policy. This element contains the following information:

    • MaxAccessKeyExpirationSeconds: The maximum possible lifetime for your access keys, in seconds.

    • RequireTrustedEnv: If true, a trusted session is activated.

  • ResponseContext: Information about the context of the response. This element contains the following information:

    • RequestId: The ID of the request.

Result sample
{
  "ApiAccessPolicy": {
    "MaxAccessKeyExpirationSeconds": 1,
    "RequireTrustedEnv": true
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

You have activated a trusted session.

Deactivating a Trusted Session

Before you begin:

To deactivate a trusted session using oapi-cli, use the command UpdateApiAccessPolicy following this syntax:

Request sample
$ oapi-cli --profile "default" UpdateApiAccessPolicy \
  --MaxAccessKeyExpirationSeconds 1 \
  --RequireTrustedEnv False

This command contains the following attributes that you need to specify:

  • (optional) profile: The named profile you want to use, created when configuring oapi-cli. For more information, see the oapi-cli GitHub repository.

  • MaxAccessKeyExpirationSeconds: The maximum possible lifetime for your access keys, in seconds. This value can go from 0 to 3153600000 (100 years), both included.

  • RequireTrustedEnv: If False, the trusted session is deactivated.

The UpdateApiAccessPolicy command returns the following elements:

  • ApiAccessPolicy: Information about your API access policy. This element contains the following information:

    • MaxAccessKeyExpirationSeconds: The maximum possible lifetime for your access keys, in seconds.

    • RequireTrustedEnv: If false, the trusted session is deactivated.

  • ResponseContext: Information about the context of the response. This element contains the following information:

    • RequestId: The ID of the request.

Result sample
{
  "ApiAccessPolicy": {
    "MaxAccessKeyExpirationSeconds": 1,
    "RequireTrustedEnv": false
  },
  "ResponseContext": {
    "RequestId": "string"
  }
}

You have deactivated the trusted session.

Related Pages

Corresponding API Method