Skip to content
Info disclosure Disclosed report Beginner

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.

shubham_srt Follow

Originally disclosed on HackerOne

Critical View original
  • 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:

  1. Go to https://www.mtn.com/wp-json/wp/v2/users/ [ Allows anyone to view active usernames ]
image.png
image.png From the original on HackerOne

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.

JavaScript
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.

The original report as published on HackerOne, by shubham_srt. Images and videos are our own copies; raw HTML is shown as text. View it on HackerOne.

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.

More from MTN Group

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Information disclosure

The lesson behind this report.

Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.