Commit 9126f86
Prevent snprintf vulnerability
Summary:
With a very big name for a `ParameterRange`, the `snprintf` call from `combination_name` can end up having a negative second parameter, causing a memory overflow, which can lead to a serious security issue.
We can checking that the second parameter is always >= 0 and throw an exception if not.
See the new GTEST.
Reviewed By: mdouze
Differential Revision: D46856956
fbshipit-source-id: 91c657ec028c462d4b808b595811342034e001331 parent 8ac4e41 commit 9126f86
1 file changed
+2
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
284 | 284 | | |
285 | 285 | | |
286 | 286 | | |
| 287 | + | |
| 288 | + | |
287 | 289 | | |
288 | 290 | | |
289 | 291 | | |
| |||
0 commit comments