Escaping the Front-End: How a Captcha Bypass Attempt Leaked a Goo
An oversized captcha token caused the Node.js backend to fail when calling Google's siteverify API, and the unhandled error was returned to the client as a raw stack trace. This exposed the Google reCAPTCHA secret key in plaintext, which an attacker could use to authenticate as the company and abuse its quota.
In bug bounty, the most critical vulnerabilities often hide behind seemingly mundane functionality. You might start out looking for a simple logical bypass, only to stumble upon an architectural flaw that compromises backend infrastructure.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely an unhandled Promise rejection: the backend did not catch the error from the Axios request to Google's siteverify API, so the full error object, including the request URL with the secret key, was returned to the client.
Impact
An attacker with the leaked secret key could authenticate as the victim company to Google's API, potentially consuming the company's reCAPTCHA quota and incurring financial charges, and the stack trace also leaked internal container paths.
What the attacker needed
Access to the support ticket form; ability to intercept and modify requests
The fix
The report recommends wrapping asynchronous network requests in try/catch blocks, sanitising error outputs to avoid returning raw exceptions, and validating input length before using it in downstream API calls; it does not state that the issue was fixed.
How it was found
- Navigate to the support ticket form and intercept the POST request.
- Locate the captcha parameter in the multipart body.
- Replace the captcha token with an oversized string containing repeated tokens and carriage returns.
- Send the request and observe the HTTP 500 response containing a stack trace with the secret key.
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 write-up has not been written yet. The Original tab links to the source.
A website used Google's reCAPTCHA to check that visitors are human. The server sends the visitor's captcha answer to Google along with a private key. When the answer was too long, Google rejected the request, and the website's code did not handle that rejection properly, so it showed the full error message to the visitor. That error message included the private key, which should never be visible to users.
What is Info disclosure?
Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.