nccgroup / aws-inventory

Discover resources created in an AWS account.
Apache License 2.0
707 stars 128 forks source link

botocore.exceptions.ClientError: An error occurred (AccessDenied) when calling the AssumeRole operation #34

Closed Leectan closed 3 years ago

Leectan commented 3 years ago

Describe the bug A clear and concise description of what the bug is. botocore.exceptions.ClientError: An error occurred (AccessDenied) when calling the AssumeRole operation: User: arn:aws:iam::123456789012:user/aws-user is not authorized to perform: sts:AssumeRole on resource: arn:aws:iam::210987654321:role/cross-account-assume-role

To Reproduce Steps to reproduce the behavior:

  1. Go to 'python aws_inventory.py --profile profile1'

Expected behavior Should run all the way and output a file.

Screenshots / Stack Traces

Desktop (please complete the following information):

bitsandsalsa commented 3 years ago

@Leectan I think your configuration is set to use an IAM role. See AWS CLI and Boto configuration docs. The inventory tool does not do any assuming of roles.