Error "To access this repository, an admin must whitelist your IP" even though IPs are whitelisted in Bitbucket Cloud
Platform Notice: Cloud - This article applies to Atlassian products on the cloud platform.
Summary
Bitbucket Cloud offers IP whitelisting as a part of the Premium plan feature which allows one to access the repository content only with the allowlisted public IPs. If the user is trying to access the repository content from other IPs, they will get the below error:
To access this repository, an admin must whitelist your IP.
fatal: unable to access 'https://bitbucket.org/workspaceID/repository.git/': The requested URL returned error: 403
Even though their public IP is whitelisted, the above error persisted.
Cause
- The error occurs when Bitbucket Cloud sees a different public IP address when a connection is established from the user's network provider. It is possible that the network is connected to Bitbucket Cloud through IPv6 public IP address of the user but IPv4 address is whitelisted.
Solution
Ensure that both public IPv4 and IPv6 addresses are whitelisted in Bitbucket Cloud.