Heap-use-after-free in CURLOPT_REFERER when passed a CURLINFO_REFERER pointer
该报告还没有中文解读。
原文摘录
摘自原文(3704 字符中的一小部分)
Setting `CURLOPT_REFERER` with a pointer previously obtained from `CURLINFO_REFERER` on the same easy handle triggers a heap-use-after-free. The `CURLOPT_REFERER` handler frees `data->state.referer` (line `lib/setopt.c:2089`) before `Curl_setstropt` reads from the now-dangling pointer (line …
原文中的代码
// lib/setopt.c:2085-2091
case CURLOPT_REFERER:
Curl_bufref_free(&data->state.referer); // frees the buffer
result = Curl_setstropt(data, STRING_SET_REFERER, ptr); // reads from ptr
break;默认不展示报告全文。以上为简短摘录,完整复现过程请阅读原文。版权归研究员与 curl 所有。
时间线
- 报告提交
- 公开披露
阅读 HackerOne 原文 ↗作者 @giant_anteater · 版权归作者与 curl 所有