All vulnerabilities

Go

CVE-2026-34157

Wails: wildcardPatternToRegex allows Origin bypass via suffix match in BindingsAllowedOrigins

Severity
High
Published
27 Oct 2026
Last changed
5 Nov 2026
Added to UpHeron
23 Nov 2026
Fixed in
2.13.0
Exploit chance
0.6% in the next 30 daysHigher than 47% of CVEs. EPSS by FIRST, 24 Nov 2026
Weakness
CWE-625
Also known as
GHSA-47hv-j4px-h3c9, GO-2026-6862
Sources
OSV.dev and GitHub

Description

Wails v2 provides BindingsAllowedOrigins to restrict which web origins can invoke Go backend methods via IPC. The wildcard pattern matching in wildcardPatternToRegex converts to .` without anchoring subcomponents, allowing suffix-matched origins to bypass the restriction.

An attacker who controls a domain sharing a prefix with the allowed origin (e.g., myapp.community when myapp.com* is configured) can invoke arbitrary bound Go methods, potentially achieving file system access, data exfiltration, or code execution depending on the application's exposed API surface.

wildcardPatternToRegex converts a wildcard pattern to a regular expression by escaping special characters and replacing with .. The substituted .*` has no restriction — it matches any character sequence including dots and additional domain components.

The official comment in options.go gives https://.myapp.com as the example pattern (subdomain prefix wildcard). This pattern is not affected.

From the GitHub Advisory Database, CC BY 4.0. Shortened; the full text is there.

Affected software

SoftwareAffected versions
github.com/wailsapp/wails/v2Go · osv:Go:github.com/wailsapp/wails/v2
  • From 2.0.0 before 2.13.0

About github.com/wailsapp/wails/v2

Vulnerabilities in github.com/wailsapp/wails/v2

In our list
2
Published in the last 12 months
2
Critical, last 12 months
0
High, last 12 months
2
Known exploited
0
Search the list for github.com/wailsapp/wails/v2

References