Commit 9536666
fix: Check for corrupted repeat/define lengths in Parquet headers (facebookincubator#16511)
Summary:
Pull Request resolved: facebookincubator#16511
We currently do not validate the correctness of the repeat/define lengths we read in the Parquet header,
this can lead us to access memory outside the data buffer.
Add checks to validate we do not go off the end of the pageData_ buffer.
Reviewed By: Yuhta
Differential Revision: D94270200
fbshipit-source-id: 1e78b2c09748fddc52bc01cbda58c2c6cb6a0f1e1 parent f447471 commit 9536666
File tree
3 files changed
+354
-3
lines changed- velox/dwio/parquet
- reader
- tests/reader
3 files changed
+354
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
232 | 232 | | |
233 | 233 | | |
234 | 234 | | |
| 235 | + | |
235 | 236 | | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
236 | 241 | | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
237 | 249 | | |
238 | 250 | | |
239 | 251 | | |
240 | 252 | | |
241 | 253 | | |
242 | 254 | | |
| 255 | + | |
243 | 256 | | |
244 | 257 | | |
245 | 258 | | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
246 | 263 | | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
247 | 271 | | |
248 | 272 | | |
249 | 273 | | |
| |||
288 | 312 | | |
289 | 313 | | |
290 | 314 | | |
| 315 | + | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
291 | 322 | | |
292 | 323 | | |
293 | 324 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
65 | 65 | | |
66 | 66 | | |
67 | 67 | | |
68 | | - | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
69 | 71 | | |
70 | 72 | | |
71 | | - | |
72 | | - | |
| 73 | + | |
| 74 | + | |
73 | 75 | | |
74 | 76 | | |
75 | 77 | | |
| |||
0 commit comments