Cross-Tenant AWS Vulnerability Exposed Account Resources


A cross-tenant vulnerability in Amazon Web Services (AWS) could have allowed attackers to abuse AWS AppSync to gain access to resources in an organization's account.

A cross-tenant vulnerability in Amazon Web Services (AWS) could have allowed attackers to abuse AWS AppSync to gain access to resources in an organization’s account.

An attacker could exploit the AWS AppSync service to assume identity and access management (IAM) roles in other AWS accounts, gaining access to resources within those accounts, cloud security company Datadog Security Labs explains.

The AppSync service allows developers to create GraphQL and Pub/Sub APIs, each with an associated data source, as well as to invoke AWS APIs directly, creating integrations with AWS services, which requires defining roles with IAM permissions.

The identified vulnerability is described as the “confused deputy problem”, because it allows a less-privileged entity (the attacker) to trick a more-privileged entity (AppSync) to perform specific actions on its behalf.

To prevent such attacks, during the creation of a data source, AWS validates the role’s unique identifier called Amazon Resource Name (ARN) against the AWS account. If they do not match, the API displays an error.

Datadog Security Labs discovered that “the API would accept JSON payloads with properties that used mixed case” during validation. The ARN is passed in the serviceRoleArn parameter that could be used to bypass the validation process if provided in a different casing.

Essentially, the mechanism allowed the cloud security firm to “provide an ARN of a role in a different AWS account”.

“By bypassing the ARN validation, we were able to create AppSync data sources tied to roles in other AWS accounts. This would allow an attacker to interact with any resource associated with a role which trusts the AWS AppSync service in any account,” Datadog notes.

The security defect, the company explains, could be exploited to create AppSync APIs data sources pointing to resources in other AWS accounts, essentially accessing data in those accounts.

Datadog, which has published proof-of-concept (PoC) code targeting the vulnerability, reported the issue to AWS on September 1. A patch was rolled out by September 6.

This week, AWS published an advisory on this vulnerability, confirming that it could have been abused to bypass AppSync’s cross-account role usage validations and access resources in other customer accounts.

“No customers were affected by this issue, and no customer action is required. Analysis of logs going back to the launch of the service have been conducted and we have conclusively determined that the only activity associated with this issue was between accounts owned by the researcher. No other customer accounts were impacted,” AWS notes.


By Ionut Arghire on Wed, 23 Nov 2022 13:51:54 +0000
Original link