Commit 9f0504f
committed
fix: dogfood scan now actually scans what we ship
Three related fixes that surfaced from running `argus scan` against
the argus repo itself:
1) supply-chain scanner ran in 795ms doing nothing.
The Dockerfile sets ENTRYPOINT ["/bin/sh", "-c"] AND the scanner's
container_args() also returned ["sh", "-c", "<cmd>"]. Docker exec
resolved to `/bin/sh -c "sh" "-c" "<cmd>"` — the script was just
"sh" (start a no-op interactive shell, exit), and the real zizmor
+ actionlint commands never ran. Returns a single-element list now;
the entrypoint provides the shell. Empirical verification on
argus's own .github/workflows/: 44 zizmor findings (38 after
exclusion filtering) vs 0 before.
2) `argus scan --interface=browser` never auto-opened the browser.
`_launch_view_after_scan` called `browser_launch(root=...)` without
`open_browser=`, so it always defaulted to False. `argus view
--interface=browser` correctly TTY-checks and auto-opens; the
post-scan path now matches via `open_browser=sys.stdout.isatty()`.
3) argus.yml dogfood config wasn't linting our own Dockerfiles.
We have four Dockerfiles in docker/ but no Dockerfile-targeting
scanner was enabled. Enables `lint-dockerfile` (hadolint) so the
default scan flags missing USER directives, mutable image tags,
apt-without-flags, and friends. Also rewrites the inline comment
block on the disabled scanners to point at the right on-demand
commands (`argus scan container --discover .`, `argus scan zap
--target ...`) for clarity.
Tests updated for the supply-chain shape change. Full SDK suite
(1363 tests) green.1 parent 3144137 commit 9f0504f
4 files changed
Lines changed: 34 additions & 14 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
33 | | - | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
34 | 45 | | |
35 | 46 | | |
36 | 47 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1349 | 1349 | | |
1350 | 1350 | | |
1351 | 1351 | | |
1352 | | - | |
| 1352 | + | |
| 1353 | + | |
| 1354 | + | |
| 1355 | + | |
| 1356 | + | |
1353 | 1357 | | |
1354 | 1358 | | |
1355 | 1359 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
39 | 39 | | |
40 | 40 | | |
41 | 41 | | |
42 | | - | |
43 | | - | |
44 | | - | |
45 | | - | |
46 | | - | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
47 | 51 | | |
48 | 52 | | |
49 | | - | |
50 | 53 | | |
51 | 54 | | |
52 | 55 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
227 | 227 | | |
228 | 228 | | |
229 | 229 | | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
230 | 234 | | |
231 | | - | |
232 | | - | |
233 | | - | |
234 | | - | |
| 235 | + | |
| 236 | + | |
235 | 237 | | |
236 | 238 | | |
237 | 239 | | |
| |||
242 | 244 | | |
243 | 245 | | |
244 | 246 | | |
245 | | - | |
246 | | - | |
| 247 | + | |
| 248 | + | |
0 commit comments