Wordpress users Disclosure [ /wp-json/wp/v2/users/ ]
The WordPress REST API endpoint /wp-json/wp/v2/users/ was publicly accessible, exposing usernames and some personal information of site authors. An attacker could collect these usernames to conduct more targeted brute-force attacks.
Originally disclosed on HackerOne
- Fixed in 13 days
- Disclosed after 44 days
Summary:
Using REST API, we can see all the WordPress users/author with some of their information. Which can even be Personal information of employees/author. The file v2/users at: https://www.mtn.com/wp-json/wp/v2/users/ is enabled and this give the attacker many users names like: Amogelang Maluleka Greg Davies karenbyamugisha Marc Ilunga mitchprinsloo
Steps To Reproduce:
- Go to https://www.mtn.com/wp-json/wp/v2/users/ [ Allows anyone to view active usernames ]

Supporting Material/References:
https://hackerone.com/reports/356047 https://hackerone.com/reports/370777
###Fix: Use this code will hide the users list and give 404 as the result, while rest of the api calls keep running as they were.
add_filter( 'rest_endpoints', function( $endpoints ){
if ( isset( $endpoints['/wp/v2/users'] ) ) {
unset( $endpoints['/wp/v2/users'] );
}
if ( isset( $endpoints['/wp/v2/users/(?P<id>[\d]+)'] ) ) {
unset( $endpoints['/wp/v2/users/(?P<id>[\d]+)'] );
}
return $endpoints;
});
Impact
Malicious counterpart could collect the usernames disclosed (and the admin user) and be focused throughout BF attack (as the usernames are now known), making it less harder to penetrate the data.gov systems.
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
The WordPress REST API users endpoint was left enabled, allowing unauthenticated enumeration of usernames.
Impact
An attacker could collect the disclosed usernames, including the admin user, to conduct brute-force attacks, making it easier to compromise accounts.
What the attacker needed
None
The fix
The report suggests removing the users endpoints from the REST API via a filter to return 404 while keeping other API calls working.
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.
WordPress has a feature that lets other programs ask for a list of users. This site left that feature turned on for anyone to use, so anyone could see the usernames of people who write for the site. Knowing usernames makes it easier for an attacker to guess passwords.
What is Info disclosure?
Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.