Usage of unsafe random function in undici for choosing boundary
密码学缺陷 / Use of Insufficiently Random Values / #2913312
该报告还没有中文解读。
原文摘录
摘自原文(2974 字符中的一小部分)
**Summary:** [Undici uses Math.random()](https://github.com/nodejs/undici/blob/8b06b8250907d92fead664b3368f1d2aa27c1f35/lib/web/fetch/body.js#L113) to choose the boundary for a `multipart/form-data` request. It is known that the output of `Math.random()` can be predicted if several of its generated …
原文中的代码
#!/usr/bin/env node
const express = require('express')
const BACKEND_API = 'http://localhost:2000/order.php'
const app = express()
app.use(express.urlencoded({ extended: false }))
app.get('/trigger-webhook',(req,res)=>{
let url = req.query.url
let data = new FormData() …默认不展示报告全文。以上为简短摘录,完整复现过程请阅读原文。版权归研究员与 Node.js 所有。
时间线
- 报告提交
- 公开披露
阅读 HackerOne 原文 ↗作者 @parrot409 · 版权归作者与 Node.js 所有