Skip to content
Leaked secrets Write-up Beginner

My First Accepted HackerOne Report: Finding Exposed Weglot API Ke

Websites using the Weglot translation service exposed their API keys in page source and JavaScript files. An attacker who found such a key could make translation requests against the paid service, causing unauthorised use and unexpected billing.

Ziadali Follow

Published on medium.com

Good evening everyone. This writeup is about my first report accepted on HackerOne and how I found the same issue on 5 different targets.

Ziadali, on medium.com

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 the Weglot API key was embedded in client-side HTML or JavaScript, where any visitor can read it.

Impact

An exposed key could allow unauthorised use of the paid translation service, resource abuse and unexpected billing costs.

What the attacker needed

Target uses Weglot; key visible in page source or JS

How it was found

  1. Open the target website
  2. View the page source
  3. Search the source for 'weglot'
  4. Search for keys starting with 'wg_'
  5. Test whether the exposed key is still active with a translation request

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.

Many websites use outside services, and to talk to those services they store a password-like string called an API key. Here the key was left visible in the website's code that anyone can view, so a stranger could use the company's paid translation account. The author found this on several sites and reported it.

What is Leaked secrets?

Keys, tokens or passwords left in public code, apps, logs or responses, that grant real access.

Similar reports

View all

Same bug class and techniques, clearest first.

Leaked secrets and credentials

The lesson behind this report.

Keys, tokens or passwords left in public code, apps, logs or responses, that grant real access.