Unauthenticated user creation in AWS Cognito user Pool
The login page exposed AWS Cognito configuration values, including the user pool ID and web client ID, in the page source. An attacker could use these leaked identifiers with AWS Cognito APIs to create new user accounts in the pool, even though the official web interface did not allow sign-up.
- Accepted in 3 months
- Fixed in 5 months
- Disclosed after 5 months
Summary by National Aeronautics and Space Administration (NASA) - Vulnerability Disclosure Program
The Agency has mitigated the risk
Summary by 1-day
Summary
It was observed that the webpage at https://loginapp.prosams.nasa.gov/login-legal-notices exposed several AWS Cognito configuration values upon scrolling, including UserPoolId and UserPoolWebClientId. These values could be leveraged to interact with the associated AWS Cognito user pool.
Although user creation was not possible via the official web interface, it was determined that a new user could be successfully created within the user pool using the leaked identifiers and AWS Cognito APIs.
This behavior may allow unauthorized access attempts or user enumeration, depending on additional configuration and permission settings associated with the user pool.
The following command was used to perform the sign-up:
aws cognito-idp sign-up \
--client-id 3nll4je3qqgc8exxxxxxxxxxxx \
--username [email protected] \
--password "Testpassword1234**" \
--user-attributes Name=email,[email protected] Name=UserSub,Value=true \
--region us-west-1
This was the response from the server:
The user creation was successfully processed despite no exposed web functionality allowing this behavior, indicating that the leaked credentials could potentially be abused if further permissions or misconfigurations exist.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the web application embedded AWS Cognito configuration values (user pool ID and web client ID) in client-side code, and the Cognito user pool allowed self sign-up through the API even though the web interface did not expose that feature.
Impact
This could allow unauthorised access attempts or user enumeration, depending on additional configuration and permission settings associated with the user pool.
What the attacker needed
Access to the login page; AWS CLI or ability to call Cognito APIs
The fix
The agency mitigated the risk, likely by disabling self sign-up in the Cognito user pool or removing the exposed configuration values.
How it was found
- Visit the login page and scroll to find the exposed AWS Cognito configuration values.
- Extract the UserPoolId and UserPoolWebClientId from the page.
- Use the AWS CLI to call the Cognito sign-up API with the leaked client ID, a chosen username, password, and email attribute.
- Observe that the server successfully creates the new user account.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
The website's login page accidentally showed some internal identifiers that are normally kept secret. These identifiers let someone talk directly to the login service and create a new account, even though the website itself had no sign-up button. This could let unauthorised people get into the system or find out which email addresses already have accounts.
What is Access control?
A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.