skip to Main Content

I’m trying to setup my aws cli. I downloaded it and everything worked.
Now I wanted to log in from my powershell script.

Set-AWSCredentials –AccessKey key-name –SecretKey key-name

Because I don’t have any users at the moment I had to create one. I have given the user admin rights.

When creating the user aws throws this error:

User: arn:aws:sts::37197122623409:assumed-role/voclabs/user2135080=.... is not authorized to perform: iam:CreateUser on resource: arn:aws:iam::371237422423709:user/.... because no identity-based policy allows the iam:CreateUser action

My first thought was that my education account is having a problem. But I didn’t find anything about it. Thanks for your help in advance.

2

Answers


  1. The "voclab" part of the error suggests you are not logged as the account root user but instead assuming a role in an account used for teaching purposes.
    This role is probably designed to disallow IAM actions, in order to prevent privilege escalation.

    Read
    https://docs.aws.amazon.com/singlesignon/latest/userguide/howtogetcredentials.html to get role credentials for the role you’re assuming

    Login or Signup to reply.
  2. You can’t make any IAM roles, policies or users as a student using voclabs account. AWS Academy does not allow to do that and its a hard limit which you nor your educator can change.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search