← 返回地图破甲

server filename with control characters printed to terminal (`-J`)

注入与走私 / Improper Neutralization of Escape, Meta, or Control Sequences / #4130124

厂商
curl
严重程度
低危
赏金
—
弱点
Improper Neutralization of Escape, Meta, or Control Sequences
研究员
@gube-dev
披露日期
2026-10-26
资产
https://github.com/curl/curl
CVE
—

该报告还没有中文解读。

原文摘录

摘自原文(3017 字符中的一小部分)
Summary: With `-OJ`, curl takes the filename from the server's `Content-Disposition` header. `parse_filename()` in `src/tool_cb_hdr.c` does not remove control characters such as ESC (0x1b). When a warning prints that name, the escape sequences reach the terminal.
原文中的代码
   import http.server

   class H(http.server.BaseHTTPRequestHandler):
       def do_GET(self):
           self.send_response(200)
           self.send_header('Content-Disposition',
               'attachment; filename="ok\x1b[2J\x1b[31mPWNED.txt"'
               .encode('latin-1', …

默认不展示报告全文。以上为简短摘录,完整复现过程请阅读原文。版权归研究员与 curl 所有。

时间线

阅读 HackerOne 原文 ↗作者 @gube-dev · 版权归作者与 curl 所有

同类报告

Unescaped username in SASL DIGEST-MD5 response allows injectioncurl · 2026-03-17Camo Image Proxy Bypass with CSS Escape SequencesChaturbate · 2019-12-18Terminal Output Not Greatcurl · 2025-12-11