mirror of
https://github.com/denoland/deno.git
synced 2025-08-09 21:38:08 +00:00
Remove Object.prototype.__proto__ (#4341)
This commit is contained in:
parent
64a35acd64
commit
2f4be6e944
5 changed files with 24 additions and 0 deletions
5
cli/tests/proto_exploit.js
Normal file
5
cli/tests/proto_exploit.js
Normal file
|
@ -0,0 +1,5 @@
|
|||
const payload = `{ "__proto__": null }`;
|
||||
const obj = {};
|
||||
console.log("Before: " + obj);
|
||||
Object.assign(obj, JSON.parse(payload));
|
||||
console.log("After: " + obj);
|
Loading…
Add table
Add a link
Reference in a new issue