Skip to content
Access control Disclosed report Intermediate

Serverinfo endpoints are not bruteforce protected nor are tokens properly generated

The serverinfo app's API endpoints accept a custom token but lack brute-force protection, and the token is generated client-side in a way that is likely weak. An attacker could repeatedly guess tokens to gain access to the endpoints.

rtod Follow

Originally disclosed on HackerOne

  • Disclosed after 20 days

The serverinfo app allows accessing the endpoints also via a custom token.

https://github.com/nextcloud/serverinfo/blob/9ae9dde028a684e53a1b37c9ba8e964ffe42a97f/lib/Controller/ApiController.php#L121

The token is set/generated via https://github.com/nextcloud/serverinfo/blob/9ae9dde028a684e53a1b37c9ba8e964ffe42a97f/templates/settings-admin.php#L341

Impact

There is no bruteforce protection on this endpoint in general. So a attacker can just fire off request. Combine this with that they have to generate a token on their own (which is usually a lot weaker) and in a lot of cases obtaining acccess should not be horribly hard.

I'd recommend

  1. Add bruteforce protection to the endpoint
  2. Have a button in the UI to generate a proper long random string

The original report as published on HackerOne, by rtod. 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

Likely the endpoint lacks rate limiting, and the token is generated in a way that is usually weaker.

Impact

An attacker could brute-force the token and in many cases obtain access to the serverinfo endpoints.

What the attacker needed

Access to the serverinfo endpoint

The fix

The reporter recommends adding brute-force protection and a UI button to generate a long random token.

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.

Some web apps let you access data by including a secret token in the request. If the app does not limit how many guesses someone can make, an attacker can try many tokens quickly until one works. Here the token is also created in a way that may make it easier to guess.

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.

More by rtod

View all

33 more disclosed reports, best first.

More from Nextcloud

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Broken access control

The lesson behind this report.

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.