Skip to content

Commit 46ccc2a

Browse files
authored
fix(vulnerability): Prototype Pollution Vulnerability (#105)
* fix: prevent prototype injection/derivatives bugs * fix: indent * fix: indent
1 parent daa2d86 commit 46ccc2a

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

Diff for: index.coffee

+4
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@ cleanParsingErrors = (string) =>
1414
if typeof done is 'undefined' and typeof options is 'function'
1515
done = options
1616
options = {}
17+
18+
if addr == '__proto__'
19+
done new Error 'lookup: __proto__ is not allowed to lookup'
20+
return
1721

1822
_.defaults options,
1923
follow: 2

0 commit comments

Comments
 (0)