Repository navigation
Commit fafec77
committed
fix(common): harden param encoding against prototype pollution
The parameter encoding was using a plain object literal lookup to determine how to encode specific characters. This makes it vulnerable to prototype pollution.
These changes mitigate the issue by storing the mapping in a native `Map` instead.
(cherry picked from commit 01c883e)1 parent 68c6c57 commit fafec77
1 file changed
Lines changed: 2 additions & 18 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
96 | 96 | | |
97 | 97 | | |
98 | 98 | | |
99 | | - | |
100 | | - | |
101 | | - | |
102 | | - | |
103 | | - | |
104 | | - | |
105 | | - | |
106 | | - | |
107 | | - | |
108 | | - | |
109 | | - | |
110 | | - | |
111 | | - | |
112 | | - | |
| 99 | + | |
113 | 100 | | |
114 | 101 | | |
115 | | - | |
116 | | - | |
117 | | - | |
118 | | - | |
| 102 | + | |
119 | 103 | | |
120 | 104 | | |
121 | 105 | | |
| |||
0 commit comments