Commit 5fff4b6
committed
fix: address code review findings
- Add --paginate flag to consumer repo search to handle >100 repos
- Add validation for SHA-pinned refs without version comments
- Replace unsafe heredoc PR body with printf to prevent command injection
- Add trap-based cleanup for temp directories to prevent resource leaks
- Move ROOT_COMMENT_ID validation to shared step for both auth paths
Fixes identified in strict code review:
- HIGH: Consumer repo pagination truncation
- MEDIUM: Command injection via FILE_PATH in PR body
- MEDIUM: Weak validation pattern for SHA pinning
- MEDIUM: Temp directory leaks on errors
- MEDIUM: Missing ROOT_COMMENT_ID validation in authorized path1 parent f02e258 commit 5fff4b6
2 files changed
+39
-16
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
144 | 144 | | |
145 | 145 | | |
146 | 146 | | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
147 | 156 | | |
148 | 157 | | |
149 | 158 | | |
| |||
219 | 228 | | |
220 | 229 | | |
221 | 230 | | |
222 | | - | |
| 231 | + | |
223 | 232 | | |
224 | 233 | | |
225 | 234 | | |
| |||
245 | 254 | | |
246 | 255 | | |
247 | 256 | | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
248 | 260 | | |
249 | 261 | | |
250 | 262 | | |
| |||
302 | 314 | | |
303 | 315 | | |
304 | 316 | | |
305 | | - | |
306 | | - | |
307 | | - | |
308 | | - | |
309 | | - | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
| 323 | + | |
| 324 | + | |
310 | 325 | | |
311 | 326 | | |
312 | 327 | | |
| |||
322 | 337 | | |
323 | 338 | | |
324 | 339 | | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
325 | 343 | | |
326 | 344 | | |
327 | 345 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
457 | 457 | | |
458 | 458 | | |
459 | 459 | | |
| 460 | + | |
| 461 | + | |
| 462 | + | |
| 463 | + | |
| 464 | + | |
| 465 | + | |
| 466 | + | |
| 467 | + | |
| 468 | + | |
| 469 | + | |
| 470 | + | |
| 471 | + | |
| 472 | + | |
| 473 | + | |
| 474 | + | |
460 | 475 | | |
461 | 476 | | |
462 | 477 | | |
| |||
509 | 524 | | |
510 | 525 | | |
511 | 526 | | |
512 | | - | |
513 | | - | |
514 | | - | |
515 | | - | |
516 | | - | |
517 | | - | |
518 | | - | |
519 | | - | |
520 | | - | |
521 | | - | |
522 | 527 | | |
523 | 528 | | |
524 | 529 | | |
| |||
0 commit comments