API Token Configuration
Alauda Container Security requires API tokens for system integrations, authentication, and various system functions. You can manage tokens through the Alauda Container Security web interface.
TOC
Key Points
- To prevent privilege escalation, when you create a new token, your role's permissions limit the permissions you can assign to that token. For example, if you only have
readpermission for the Integration resource, you cannot create a token withwritepermission. - If you want a custom role to create tokens for other users, you must assign the required permissions to that custom role.
- Use short-lived tokens for machine-to-machine communication, such as CI/CD pipelines, scripts, and automation. For human-to-machine communication, such as CLI or API access, use the
roxctl central logincommand. - Most cloud service providers support OIDC identity tokens, such as Microsoft Entra ID, Google Cloud Identity Platform, and AWS Cognito. OIDC identity tokens issued by these services can be used for Alauda Container Security short-lived access.
Procedure
-
In the Alauda Container Security portal, go to Platform Configuration > Integrations.
-
Scroll to the Authentication Tokens category and click API Token.
-
Click Generate Token.
-
Enter a name for the token and select a role that provides the required level of access (for example, Continuous Integration or Sensor Creator).
-
Click Generate.
Important:
Copy the generated token and store it securely. You will not be able to view it again.
Token Expiration and Notification
API tokens expire one year from the creation date. Alauda Container Security alerts you in the web interface and by sending log messages to Central when a token will expire in less than one week. The log message process runs once an hour. Once a day, the process lists the tokens that are expiring and creates a log message for each one. Log messages are issued once a day and appear in Central logs.
Log message format:
Configuring Notification Settings
You can change the default settings for the log message process by configuring the following environment variables: