检测到您已登录华为云国际站账号,为了您更好的体验,建议您访问国际站服务网站 https://www.huaweicloud.com/intl/zh-cn
不再显示此消息
Related Services IAM Identity and Access Management (IAM) provides Content Moderation with the user authentication and authorization function. For more information about IAM, see the Identity and Access Management User Guide.
For example, the endpoint of IAM in the CN-Hong Kong region is iam.ap-southeast-1.myhuaweicloud.com. resource-path Resource path, that is, API access path. Obtain the value from the URI of an API.
To create an IAM user, perform the following steps: In the navigation pane of the IAM console, choose Users. Then click Create User. Set user information and click Next. For details about the parameters, see Creating an IAM User.
To ensure account security, create IAM users and grant them permissions for routine management. User A user is created in IAM using an account to use cloud services. Each user has its own identity credentials (password and access keys).
Copy the IAM username and account name to username and domainname, and enter the IAM user password. Figure 3 Token-based authentication Click Send to send a request, and obtain and copy the token. In Headers, obtain the value of X-Subject-Token, which is the token.
about how to obtain the project ID, see Obtaining a Project ID. job_id Yes String Job ID returned when a job is created Request Parameters Table 2 Request header parameters Parameter Mandatory Type Description X-Auth-Token Yes String User token, which can be obtained by calling the IAM
Copy the IAM username and account name to username and domainname, and enter the IAM user password. Figure 4 Token-based authentication Click Send to send a request, and obtain and copy the token. In Headers, obtain the value of X-Subject-Token, which is the token.
When using a token for authentication, cache it to prevent frequently calling the IAM API used to obtain a user token. A token specifies certain permissions in a computer system.
Incorrect IAM authentication information: Failed to decrypt the token. Check whether the entered token is complete. 2. The validity period of a token is 24 hours. If the token expires, obtain a new token and pass it. 3. The AK/SK authentication fails.
Request Parameters Table 2 Request header parameters Parameter Mandatory Type Description X-Auth-Token Yes String User token, which can be obtained by calling the IAM API (The token is the value of X-Subject-Token in the response header.)
Request Parameters Table 2 Request header parameters Parameter Mandatory Type Description X-Auth-Token Yes String User token which can be obtained by calling the IAM API (The token is the value of X-Subject-Token in the response header.)
Request Parameters Table 2 Request header parameters Parameter Mandatory Type Description X-Auth-Token Yes String User token, which can be obtained by calling the IAM API (The token is the value of X-Subject-Token in the response header.)
OBS authorization must be performed by an account, not by an IAM user. Once enabled, OBS authorization cannot be disabled. Step 3: (Optional) Configure a Moderation Rule You can configure review rules to detect pornographic content in different scenarios.
about how to obtain the project ID, see Obtaining a Project ID. job_id Yes String Job ID returned when a job is created Request Parameters Table 2 Request header parameters Parameter Mandatory Type Description X-Auth-Token Yes String User token, which can be obtained by calling the IAM
about how to obtain the project ID, see Obtaining a Project ID. job_id Yes String Job ID returned when a job is created Request Parameters Table 2 Request header parameters Parameter Mandatory Type Description X-Auth-Token Yes String User token which can be obtained by calling the IAM