Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root


1 badge earned


Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!


Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.


Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!


Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
Community Members
Community Events
Community Groups

OIDC Pipelines do not working (Not authorized to perform sts:AssumeRoleWithWebIdentity)

Pipelines deployment is failing when trying to connect to AWS through OIDC.

I assume it's not a permission issue, as even adding AdministratorAccess Policy to the OIDC Role, the authentication does not work.


WARNING: Refreshing temporary credentials failed during mandatory refresh period.
Traceback (most recent call last):
File "/usr/local/lib/python3.9/site-packages/botocore/", line 529, in _protected_refresh
metadata = self._refresh_using()
File "/usr/local/lib/python3.9/site-packages/botocore/", line 670, in fetch_credentials
return self._get_cached_credentials()
File "/usr/local/lib/python3.9/site-packages/botocore/", line 680, in _get_cached_credentials
response = self._get_credentials()
File "/usr/local/lib/python3.9/site-packages/botocore/", line 890, in _get_credentials
return client.assume_role_with_web_identity(**kwargs)
File "/usr/local/lib/python3.9/site-packages/botocore/", line 386, in _api_call
return self._make_api_call(operation_name, kwargs)
File "/usr/local/lib/python3.9/site-packages/botocore/", line 705, in _make_api_call
raise error_class(parsed_response, operation_name)
botocore.exceptions.ClientError: An error occurred (AccessDenied) when calling the AssumeRoleWithWebIdentity operation: Not authorized to perform sts:AssumeRoleWithWebIdentity

2 answers

The problem was that I had a conditional policy in my OIDC Role Trus Relationship that allowed a specific range of IPs from Bitbucket.

I took those IPs from this documentation:

I don't know why Bitbucket Pipelines was using another IP to connect to my AWS OIDC.


So now, I merged another IP list from this documentation:


And now it's working again.

@Marco Tanaka 

Thanks for knowledge sharing and contributing to the community!

0 votes

Hi @Marco Tanaka

Thank you for your question!

Make sure that you setup properly OIDC access on AWS according to the Deploy on AWS using Bitbucket Pipelines OpenID Connect guide.


Best regards,

Suggest an answer

Log in or Sign up to answer
Site Admin

Atlassian Community Events