other
- Location
scripts/patch-qrcode-terminal.sh:25- Finding
WeChat Login QR Payload Disclosed to a Third-Party Service
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
This setup skill is for a real WeChat/OpenClaw workflow, but it exposes login QR contents to a third-party QR service and persistently rewrites an installed dependency.
Review this carefully before installing. Prefer a version-pinned installer and a local QR rendering method that does not send WeChat login QR contents to a third-party service. If used anyway, run it only in a controlled OpenClaw environment, understand that it rewrites the installed qrcode-terminal dependency, and be prepared to restore the backup or reinstall the plugin.
scripts/patch-qrcode-terminal.sh:25WeChat Login QR Payload Disclosed to a Third-Party Service
scripts/patch-qrcode-terminal.sh:20Installed QR Dependency Is Rewritten In Place
SKILL.md:21Mutable Latest Package Release Is Downloaded and Executed
The trigger description includes very broad phrases such as general references to WeChat/微信, which can cause the skill to activate during ordinary conversation rather than an explicit installation request. Over-broad activation increases the chance that users are steered into running setup, patching files, or initiating external connections without clear intent.
The skill installs and executes a package via npx ...@latest, which fetches whatever version is current at runtime rather than a reviewed, pinned release. That creates a supply-chain execution risk: if the package is compromised or a breaking/malicious update is published, users will run attacker-controlled code immediately during setup.
These instructions modify code to send QR payload data to a third-party service and require opening the resulting URL in a browser, but they do not clearly warn the user that login material will be transmitted off-host. In this context, the QR content may represent sensitive authentication or session bootstrap data, so silent external transmission materially increases credential/session exposure risk.
The patch rewrites QR rendering so the raw QR payload is URL-encoded and sent to api.qrserver.com, a third-party external service. If that payload contains authentication material for WeChat/OpenClaw login, the service and any intermediary logs gain access to sensitive token/bootstrap data, enabling account linkage abuse or session compromise.
sed -i '/var qrcode = new QRCode(-1, this.error);/c\
// Patched: output image URL instead of ASCII\
var encoded = encodeURIComponent(input);\
var imageUrl = "https://api.qrserver.com/v1/create-qr-code/?size=400x400&data=" + encoded;\
var output = "\\n📷 扫码链接(复制到浏览器打开或微信扫一扫):\\n" + imageUrl + "\\n";\
if (cb) cb(output); else console.log(output);\
return;\n' "$QR_MAIN"
This shell script performs direct file write operations by copying the target file to a backup and then editing the original file in place with sed. While the script has brief comments and a success message, it does not clearly warn the user beforehand that it will alter installed plugin code on disk or prompt for confirmation before making the change.
The patch changes QR rendering so the QR payload is embedded into a third-party URL at api.qrserver.com, causing the WeChat login/connection token to be transmitted to an external service. In this context, the QR contents are likely authentication material or session bootstrap data, so exposing them to an unrelated remote service could allow account/session hijacking or unauthorized linkage of the bot if the URL is logged, intercepted, or retained by that service.
sed -i '/var qrcode = new QRCode(-1, this.error);/c\
// Patched: output image URL instead of ASCII\
var encoded = encodeURIComponent(input);\
var imageUrl = "https://api.qrserver.com/v1/create-qr-code/?size=400x400&data=" + encoded;\
var output = "\\n📷 扫码链接(复制到浏览器打开或微信扫一扫):\\n" + imageUrl + "\\n";\
if (cb) cb(output); else console.log(output);\
return;\n' "$QR_MAIN"
The inserted string literal presents the QR-code instructions only in Chinese, which imposes a specific language on users regardless of their locale. There is no indication in the script that this is a region-specific tool or that users can opt into or select the output language.
No suspicious patterns detected.