Skip to content
RCE Write-up Intermediate

SSTI in Google Maps

The 'place name' field in Google Maps timeline was inserted into a server-side template without proper validation, allowing template syntax injection. An attacker could cause server errors or alter page content, but no further exploitation (like reading environment variables or running code) was achieved.

Zohar Shacha Follow

Published on ehpus.com

A while back I was researching Google Maps ‘timeline’ feature, and specifically the capability to add your own ‘places’. I was trying to replicate a previous XSS I found in the ‘export as KML’ feature, and thought the custom place ‘name’ could be a good spot to place my payload.

Zohar Shacha, on ehpus.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 server used the user-supplied place name directly in a template without sanitising template syntax characters.

Impact

An attacker could cause server errors and inject harmless content, but could not read sensitive data or execute code.

What the attacker needed

Access to Google Maps timeline; ability to add a place

How it was found

  1. Enter a place name containing a curly bracket, such as 'aaa{}'.
  2. Observe a 500 error from the server and the GUI hanging.
  3. Enter a place name ending with a single quote to reproduce the 'placeholder' display issue.
  4. Craft a payload of the form 'ANYTEXT}=2 {ANYTEXT}ANYTEXT{ANYTEXT'' to inject harmless content without breaking the template.

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 template engine is a tool that builds web pages by filling in placeholders with data. Here, the place name was treated as part of the template itself, so special characters like curly brackets or quotes could break the page or inject content. This is called server-side template injection (SSTI).

What is RCE?

Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.

More by Zohar Shacha

View all

4 more disclosed reports, best first.

More from Google

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Remote code execution

The lesson behind this report.

Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.