Attacker can Add itself as admin user and can also change privileges of Existing Users [█████████]
An unprotected administrative directory allowed unauthenticated users to add new admin accounts and change existing user privileges. An attacker could create an admin account and log in with the credentials sent by email, compromising the entire site.
Originally disclosed on HackerOne
- Triaged in 28 hours
- Fixed in 3 days
- Disclosed after 47 days
Hi there, i have found a vulnerability on you domain. After directory bruteforcing i found an directory without having any kind of protection and authentication. so an attacker can add new user to the site As Admin and an attacker can also change privilege of the users without any authentication. for further read steps to reproducue.
Impact
The attacker can add itself as admin user and can also change user privileges without any authentication. this can lead to huge impact the entire site can be compromised.
System Host(s)
████
Affected Product(s) and Version(s)
CVE Numbers
Steps to Reproduce
- Visit ████████:1:0::::: you will see the website is asking to login
- Now change the 1 to 9 or directly visit this url.
- Navigate to
Add New User - enter email address, First name, Last name and choose agency to Non-Agency.
- Click on
add new user - check mail inbox you will recieve the username and password for the admin account you just created.
- Login with the creds you just got in you email.
NOTE: I CREATED 2 ACCOUNTS WHILE TESTING THIS ISSUE I HAVE PROVIED CREDS FOR THE BOTH ACCOUNT IN POC MAKE SURE TO CHECK THEM AS WELL
Suggested Mitigation/Remediation Actions
the website should have proper authentication for the url ████████::::: so that can any unauthorized user cannot add user or change the privileges of the existing users.
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 administrative user-management page lacked any authentication or authorisation check, so anyone who found the URL could use it.
Impact
An attacker could add themselves as an admin user and change user privileges without authentication, potentially compromising the entire site.
What the attacker needed
No account needed; knowledge of the unprotected URL
The fix
The administrative URL should require proper authentication and authorisation so that unauthorised users cannot add users or change privileges.
How it was found
- Visit the site and see that it asks for a login.
- Change the number in the URL from 1 to 9, or visit the alternate URL directly.
- Navigate to the 'Add New User' page.
- Enter an email address, first name, last name, and choose 'Non-Agency' for agency.
- Click 'add new user'.
- Check the email inbox to receive the username and password for the newly created admin 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.
A part of the website that should only be used by logged-in administrators was left open to anyone. By changing a number in the web address, a visitor could reach a page for adding new users and create an administrator account without logging in. The new account's login details were then emailed to the attacker, giving full control of the site.
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.