Azure OAuth 2.0 Vulnerability Grabs Tokens
Security firm CyberArk is now finally able to discuss a major OAuth 2.0 vulnerability that affects Microsoft Azure web services.
![](https://eu-images.contentstack.com/v3/assets/blt6d90778a997de1cd/blt7584329791799f5f/64f179d92263b359bead2677/8629.png?width=1280&auto=webp&quality=95&format=jpg&disable=upscale)
Omer Tsarfati and his team at security firm CyberArk are now finally able to discuss a major OAuth 2.0 vulnerability that affects Microsoft Azure web services which they have been sitting on since October, according to their timeline.
To appreciate the problem, it's needed to step back a bit and consider how OAuth functions in the first place.
OAuth is a protocol used for authorization. End users can grant websites or applications access to their information from other websites without having to give the requesting website access to app secrets or passwords. It is widely used by many companies because it works fairly well in most situations.
A permanent "refresh" token is used in the protocol to validate identification and obtain an "access" token.
But, as CyberArk puts it, "The protocol itself is well built and secured, but a wrong implementation or inappropriate usage and configuration can have a colossal impact."
Certain of Microsoft's OAuth2.0 applications (including Portfolios, O365 Secure Score and Microsoft Service Trust) will give unquestioning trust to the white-listed domains and sub-domains they use. These domains can be registered by anyone (including an attacker) and Microsoft does not maintain a central registry of them. The app's trust can be misapplied to a false but yet trusted domain. Use of these apps is mandated in the Microsoft Account's approved applications portal.
To make things even more difficult for the security response to this vulnerability, these apps are allowed to ask for an "access_token." This token functions in the protocol as a session identifier, and is needed to actually implement an action on behalf of the user.
The combination of these two factors being active at the same time meets the requirements needed to enable an action with the user's permissions -- including gaining access to Azure resources, AD resources and more.
This means that a user encountering a specially-crafted link could initiate an OAuth workflow in Azure that ends up grabbing the user's access tokens which then allows other data to be compromised, especially if the token is functionally a privileged credential.
CyberArk recommends some mitigation steps that can be done along with the "fix" that Microsoft has issued, according to CyberArk, on 11/19/2019. They are:
"Make sure that all the trusted redirect URIs configured in the application are under your ownership. \r\n
Remove unnecessary redirect URIs.\r\n
Make sure the permissions that the OAuth application asks for are the least privileged one it needs.\r\n
Disable non-used applications."
This situation points how how security in the cloud may take unexpected turns. Vulnerabilities can arise from a myriad of sources when they are combined together in one project, and an approach that can get to the needed granularity of individual elements used in the resultant can greatly aid in the detection of malicious outcomes.
— Larry Loeb has written for many of the last century's major "dead tree" computer magazines, having been, among other things, a consulting editor for BYTE magazine and senior editor for the launch of WebWeek.
Read more about:
Security NowAbout the Author
You May Also Like
Catch the Threat Before it Catches you: Proactive Ransomware Defense
September 5, 2024How to Evaluate Hybrid-Cloud Network Policies and Enhance Security
September 18, 2024DORA and PCI DSS 4.0: Scale Your Mainframe Security Strategy Among Evolving Regulations
September 26, 2024Harnessing the Power of Automation to Boost Enterprise Cybersecurity
October 3, 2024
[Virtual Event] The Essential Guide to Cloud Management
October 17, 2024Black Hat Europe - December 9-12 - Learn More
December 10, 2024SecTor - Canada's IT Security Conference Oct 22-24 - Learn More
October 22, 2024