curl Missing Sec-WebSocket-Accept Verification Enables MITM WebSocket Session Hijacking
该报告还没有中文解读。
原文摘录
摘自原文(4696 字符中的一小部分)
curl's `Curl_ws_accept()` function in `lib/ws.c` processes the 101 Switching Protocols response to a client WebSocket upgrade request. RFC 6455 Section 4.1 mandates that the client MUST verify the `Sec-WebSocket-Accept` response header by computing the SHA-1 hash of the concatenation of the …
原文中的代码
#!/usr/bin/env python3 """PoC: send 101 without Sec-WebSocket-Accept — curl accepts it.""" import socket, struct, sys, time PORT = int(sys.argv[1]) if len(sys.argv) > 1 else 8766 s = socket.socket(socket.AF_INET, socket.SOCK_STREAM) s.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1) …
默认不展示报告全文。以上为简短摘录,完整复现过程请阅读原文。版权归研究员与 curl 所有。
时间线
- 报告提交
- 公开披露
阅读 HackerOne 原文 ↗作者 @kiyin · 版权归作者与 curl 所有