Identity management
To ensure the security of your Alibaba Cloud account and cloud resources, you should avoid using the Alibaba Cloud account (the root account) to access Raascall unless necessary. We recommend that you use RAM identities (RAM users and RAM roles) to access Raascall.
RAM users
RAM users must be created by the Alibaba Cloud account (the root account) or by a RAM user or RAM role with administrator permissions. A RAM user can log on to the console or use the API to access resources under the Alibaba Cloud account only after the RAM user is authorized.
We recommend that you follow these best practices when using RAM users:
-
Use the Alibaba Cloud account to create a RAM user and grant the RAM user administrator permissions. Then use the RAM user with administrator permissions to create and manage other RAM users.
-
Separate human users from programmatic users.
When you create a RAM user, you can configure two access methods: Console Access and OpenAPI Call Access. Console users use a username and password to access the cloud product console, while API users use AccessKey (AK) to call APIs to access cloud resources. We recommend that you separate these two usage scenarios to prevent service disruptions caused by accidental operations. For users who access the console, we recommend that you enable MFA multi-factor authentication.
-
Grant the least privilege to RAM users as needed.
The principle of least privilege means granting users only the permissions required to perform a specific task and no additional permissions. Least privilege prevents users from having excessive permissions, improves data security, and reduces security risks caused by permission abuse.
-
Do not save the AccessKey ID and AccessKey Secret of a RAM user in project code. Otherwise, the AccessKey may be leaked, threatening the security of all resources under your account. We recommend that you use STS or environment variables to obtain access authorization.
-
Configure SSO single sign-on for RAM users when conditions are met, so that you can use your enterprise identity to log on to and access Alibaba Cloud resources directly.
Operations related to RAM users
RAM user groups
When you have multiple RAM users under your Alibaba Cloud account, you can create user groups to group RAM users with the same responsibilities and grant permissions to the groups in batches. This enables efficient management of RAM users and their permissions. We recommend that you follow these best practices when using RAM user groups:
-
Follow the principle of least privilege when granting permissions to RAM user groups.
-
Remove a RAM user from a user group when the user's responsibilities change to prevent permission abuse.
-
Remove permissions from a user group when the group no longer needs those permissions.
Operations related to RAM user groups
RAM roles
A RAM role is a virtual user that can be granted a set of permission policies. Unlike a RAM user, a RAM role does not have permanent identity credentials (a logon password or access key). A RAM role must be assumed by a trusted entity. After the role is assumed, the trusted entity obtains the temporary identity credentials of the RAM role, that is, a security token (STS Token). The security token can be used to access authorized resources as the RAM role.
The following are security recommendations for using RAM roles:
-
After you create a RAM role, do not change the trusted entity of the RAM role at will. Modifying the trusted entity in the trust policy of a RAM role may cause the original trusted entity to lose permissions, affecting normal business operations. It may also introduce the risk of over-authorization by adding new trusted entities. If modification is required under special circumstances, make sure to test the changes thoroughly in a test account before applying them to your production account.
-
After a RAM user of the trusted entity is authorized, the RAM user can call the AssumeRole API operation to obtain the STS Token of the RAM role. An STS Token is valid for a period of time after it is issued. We recommend that you set a reasonable token validity period to avoid security risks caused by an excessively long validity period.
Note
The maximum validity period of an STS Token is the maximum session duration of the role. For security purposes, you should also set the maximum session duration of the role to a reasonable range.
-
Configure SSO single sign-on for RAM roles when conditions are met, so that you can use your enterprise identity to log on to and access Alibaba Cloud resources directly.