How I found my first ever bug.
A Google Maps API key was found in a JavaScript file and was not properly restricted, allowing anyone to make requests to the Static Maps and Street View APIs. This could cause financial damage to the organisation because the API key is paid.
osintteam.blog
Published on osintteam.blog
If you are new here, I am a beginner bug hunter and cyber security enthusiast, I am currently learning bug hunting.
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 Google Maps API key was not restricted to specific APIs or referrers, so it could be used by anyone.
Impact
Anyone could make requests using the API key, which could cause financial damage to the organisation because the key is paid.
What the attacker needed
None
How it was found
- Use katana to collect JavaScript file URLs from the target website.
- Run SecretFinder on each JavaScript file to look for secrets.
- Identify a Google Maps API key in the SecretFinder output.
- Use gmapsapiscanner to test whether the key is vulnerable.
- Manually confirm that the key allows requests to Static Maps and Street View.
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 a Google Maps key to show maps. That key was left open so anyone could use it, and since Google charges for map requests, the website owner could get a big bill. The hunter found the key by looking through the website's code files.
What is Leaked secrets?
Keys, tokens or passwords left in public code, apps, logs or responses, that grant real access.