Repository navigation
Description
Summary
The open PR queue has 65 entries and zero have been merged since #12 (2026-09-10). main was last
pushed 2026-09-14 — 42 days ago. Because most security-relevant PRs touch the same two validator
files, they conflict with each other in ways that are invisible until merge time.
This issue is not about a defect in any single PR. It is about the merge queue itself: the order in
which these PRs are merged will decide which fixes survive, and two of them cannot both be applied
as written.
The blocking pair: #63 and #97
Both are mergeable_state: clean against main separately, so CI is green on each branch and neither
looks problematic in isolation. Merging them together produces a content conflict:
$ git fetch origin pull/63/head:pr63 pull/97/head:pr97
$ git checkout -b test-merge pr63 && git merge pr97
Auto-merging skills/security-audit/validate-findings.cjs
CONFLICT (content): Merge conflict in skills/security-audit/validate-findings.cjs
The conflicting hunk is the CLI entry point:
// #63
if (require.main === module) {
const args = process.argv.slice(2);
process.exit(run(args.length === 1 ? args[0] : undefined));
}
// #97
if (require.main === module) process.exit(run(process.argv[2], process.argv.slice(3)));The two rules are semantically incompatible:
- Reject extra CLI arguments instead of validating only the first file #63 says the CLI accepts exactly one argument. A second argument is a usage error.
- Ground-truth claimed finding paths with --target #97 adds
--target <repository-root>, which is two arguments.
Whichever lands second breaks. And the breakage is not hypothetical — it is silent in one direction:
$ node validate-findings.cjs findings.json --target /repo
Usage: node validate-findings.cjs <path-to-findings.json>
# exit 1 — a legitimate invocation is rejectedMeanwhile, if #97 lands first and #63 is rebased naively on top, the --target flag stops working while
the tool still reports PASS for every other input.
Note that #63's own "Overlap" section states: "No open PR changes argument handling in
validate-findings.cjs." That was accurate when written on 2026-09-28; #97 was opened on 2026-10-23.
The note is now stale.
A resolution that satisfies both
Accepting a single path, or a path plus flag/value pairs, keeps both behaviours:
if (require.main === module) {
const args = process.argv.slice(2);
const rest = args.slice(1);
// Accept [path], or [path, --flag, value, ...]. A second bare path is a
// usage error. Flags are passed through so run() can name an unknown one.
const flagValuePairs =
rest.length > 0 && rest.every((a, i) => (i % 2 === 0 ? a.startsWith("--") : true));
const valid = args.length === 1 || flagValuePairs;
process.exit(run(valid ? args[0] : undefined, rest));
}With this resolution the merged tree passes 70/70 tests (38 findings + 32 ledger), and the
behaviour matrix is:
| Invocation | Exit | Output |
|---|---|---|
validate-findings.cjs findings.json |
0 | PASS: 1 findings valid |
validate-findings.cjs findings.json --target <repo> |
0 | PASS: 1 findings valid |
validate-findings.cjs findings.json --bogus |
1 | Unknown argument: --bogus |
validate-findings.cjs findings.json findings.json |
1 | Usage: node validate-findings.cjs ... |
validate-findings.cjs phantom.json --target <repo> |
1 | "src/PHANTOM.c" does not exist under the target repository |
Wider conflict surface
Running git merge-tree pairwise over every open PR that touches a validator .cjs file gives
77 conflicting pairs among current-base PRs (42 of them in validator source files, not just
tests). The highest-degree PRs are:
| PR | conflicts with | notes |
|---|---|---|
| #48 | 13 | validate-coverage-ledger.cjs + docs |
| #96 | 13 | validate-coverage-ledger.cjs + SKILL.md |
| #75 | 10 | both validators + docs |
| #84 | 9 | validate-coverage-ledger.cjs + docs |
| #63 | 9 | both validators |
| #62 | 8 | reorganises the skill into references/ + scripts/ — conflicts with 8 PRs by directory layout alone |
Two clusters account for most of it:
- Artifact-sharing fixes — fix(coverage-ledger): verify local-check artifacts exist on disk #25, fix: validate on-disk existence and integrity of local-check artifacts #26, Allow multiple local checks in an archived attempt to share an artifact #70, fix: allow artifact sharing within an archived attempt #82, fix: allow checks in one attempt to share a promoted artifact #87, fix: allow checks in one attempt to share a promoted artifact #91, fix: allow artifact sharing within an attempt #106 all touch the same
validate-coverage-ledger.cjsartifact-promotion logic. They are 7 PRs solving overlapping variants
of the same problem (issues validate-coverage-ledger.cjs rejects artifact sharing within a single attempt #81 and friends). - CLI argument handling — Read validator CLI input safely on Windows #59, Ground-truth claimed finding paths with --target #97, fix: support platforms without O_NOFOLLOW/O_NONBLOCK #99, fix: keep validators usable where O_NOFOLLOW is unavailable (Windows) #113 all rewrite the same entry point for different
reasons (extra-arg rejection,--targetground-truthing, Windows-safe input).
Three PRs (#7, #8, #9) are mergeable_state: dirty against main — their merge-base is 2026-07-06,
before the "Rework the audit workflow, findings contract, and validators end to end" change (#12). They
will conflict with essentially everything and likely need a rebase rather than a merge.
Why this matters for the fixes that are actually wanted
Several of the blocked fixes are security-relevant, and they are all in this queue:
- Derive run paths and prior-run identity from a sanitized repo ID, not the raw repo name #95 / Harden the audit workflow against target-influenced results #96 — target-controlled repo name drives the output path (issue Target-controlled repo name drives output path and prior-run reuse (path escape, cross-target prior-run poisoning) #94, path escape)
- Treat target content as untrusted data in every agent prompt #108 — treat target content as untrusted data in every agent prompt
- fix: reject duplicate object keys in findings.json #102 / fix: reject duplicate object keys in coverage-ledger.json #103 — reject duplicate object keys (a tampered
fingerprintcurrently passes validation) - Enforce the 1,000-field object limit in validate-findings.cjs #111 — object-field limit in
validate-findings.cjs(issue Asymmetric parser hardening: validate-findings.cjs lacks pre-parse and in-memory objectFields limits, exposing parent workflow to key-amplification DoS #107) - Read validator input safely on Windows #69 / fix: support platforms without O_NOFOLLOW/O_NONBLOCK #99 / fix: keep validators usable where O_NOFOLLOW is unavailable (Windows) #113 — validators cannot read any input on Windows (issue Validator CLIs cannot read any input on Windows #53)
Whichever of these is merged last will need re-resolution against the accumulated state of the others.
Suggested approach
- Land the Reject extra CLI arguments instead of validating only the first file #63 + Ground-truth claimed finding paths with --target #97 combination first, with the argument parsing above, so the CLI contract is
settled before the rest of the queue lands on top of it. - Merge the artifact-sharing cluster (fix(coverage-ledger): verify local-check artifacts exist on disk #25, fix: validate on-disk existence and integrity of local-check artifacts #26, Allow multiple local checks in an archived attempt to share an artifact #70, fix: allow artifact sharing within an archived attempt #82, fix: allow checks in one attempt to share a promoted artifact #87, fix: allow checks in one attempt to share a promoted artifact #91, fix: allow artifact sharing within an attempt #106) as one reconciled change
rather than seven sequential merges — they address the same code region and issue validate-coverage-ledger.cjs rejects artifact sharing within a single attempt #81. - Rebase or close Add a real /cloudflare-security-audit slash command #7, feat: add findings.json → SARIF 2.1.0 converter #8, fix: reject invalid trace line numbers #9 — their base predates the validators rewrite.
- Consider a merge queue or a
merge-trainso that conflicts surface in CI rather than at review time.
Reproduction
git clone https://github.com/cloudflare/security-audit-skill.git
cd security-audit-skill
git fetch origin pull/63/head:pr63 pull/97/head:pr97
git checkout -b test-merge pr63
git merge pr97 # → CONFLICT (content) in skills/security-audit/validate-findings.cjsFor the full pairwise sweep:
git fetch origin '+refs/pull/*/head:refs/remotes/pr/*'
for a in $(git for-each-ref --format='%(refname:short)' refs/remotes/pr/); do
for b in $(git for-each-ref --format='%(refname:short)' refs/remotes/pr/); do
git merge-tree --write-tree --name-only "$a" "$b" >/dev/null 2>&1 || echo "conflict: $a $b"
done
doneEnvironment
- Repo:
cloudflare/security-audit-skill mainatc1c8a8c1471069fb0e188eeaff69b8e8db6564a8(2026-09-14)- Node v26.7.0, macOS 15.8.1
Activity
iraptor93 commentedon Oct 27, 2026
I need more Lemon pledge.
panditbhavik15 commentedon Oct 31, 2026
i had send the pull request
validators: enforce one CLI contract and support --target
zachshallbetter commentedon Nov 18, 2026
The overlap is the real problem here. The same few validator changes show up in three or four PRs each: Windows input handling in #59, #99, #113, #131 and #145, artifact sharing in #70, #82, #87, #91 and #106, and artifact existence in #25, #26 and #48.
I'm opening a small governance PR with a CONTRIBUTING.md that asks people to search open PRs and build on an existing one instead of opening a parallel copy. It won't untangle what's already here, but it should slow the pile-up. If a maintainer can pick one PR per cluster, the rest can be closed against it.