For some reason, Apple’s website where you can manage your Apple ID (appleid.apple.com) is blocking users of Linux browsers from accessing it. Having access to the website is important to manage things such as payment information, two-factor authentication, and other account details. Even though the number of Linux users accessing the website must be relatively small compared to other operating systems, some iPhone users who use Linux on the desktop noticed the issue.
This behavior was first explained by user Alexander Martin on Mastodon and then shared on Hacker News. He discovered that when the browser reports itself as being a Linux browser, Apple’s website will block the access by throwing a “Bad Gateway” error.
We were able to reproduce the issue by using the developer tools on Safari running on the Mac, if the website encounters the string “Linux” in the user agent, the connection is interrupted by a “Bad Gateway” error message.
It’s unclear whether this was a deliberate decision by Apple or if it’s just a bug on their website. It is possible that, for security reasons, the website only accepts a set of whitelisted user agents and that given the relatively small amount of Linux users accessing the website, the open-source OS was forgotten.