You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
JCL in-stream payload grammar: SQL DCL/DDL and IDCAMS/DSN commands under DD * have no owner #3002
gitgalaxy#2990's JCL verb-coverage census (tests/tools/embedded_verb_coverage.py jcl) anchors its operand/statement scan to real // control-statement lines, which correctly excludes bare in-stream data (see the fix in that PR — an unanchored scan swept up a whole CICS SIT-parameter deck, DFH$SIP1.jcl, as if it were JCL syntax). That fix is scoped correctly, but it means the actual content carried in //SYSIN DD * payload blocks is invisible to the coverage table by design, and it is real, unowned surface:
in-stream verb
occurrences (language-crucible v1.2.0)
DSN SYSTEM
52
RUN PROGRAM
33
GRANT
24
DROP
17
DELETE
15
BIND
14
DEFINE CLUSTER
10
REPRO
2
FREE
2
These are Db2 DSN command processor / IDCAMS utility control-statement grammars, carried as plain text data cards that a real z/OS batch job feeds to a program via SYSIN/SYSTSIN.
The existing posture (why this isn't fixed in #2990)
#2751/#2486 established that JCL's high_risk_execution measures the step (does it run a caller-supplied command?), not the step's payload — IDCAMS/IEHPROGM/ADRDSSU are explicitly excluded there as "destructive-capable utilities but execute a fixed command language." That reasoning argues against a rule change here too. But GRANT/DROP are genuinely security-relevant (the same class EXEC SQL GRANT/REVOKE is for embedded SQL, gitgalaxy#2990's cobol.py table), and this issue exists so that judgment call gets its own review rather than being silently absent.
Ask
Decide (and, if a rule is warranted, implement): does JCL need an io/safety/high_risk_execution extension that reads inside DD * payload blocks for a fixed set of Db2/IDCAMS command keywords, or does the step-level posture stand and this surface is recorded as intentionally out of scope? Either outcome should land as a ledger-style note the way #2751's reasoning is documented in jcl.py's own comments.
Found by: gitgalaxy#2990 (COBOL/JCL semantic-coverage assessment).
Reviewed the nine verbs against docs/high_risk_execution_rule_contract.md (#2878) individually rather than as one blob. Full per-verb reasoning is landed as a ledger-style comment in jcl.py above high_risk_execution, and the ownership call is now tracked (not just decided) via tests/tools/embedded_verb_coverage.py's EXPECTED_JCL table.
Verdict: eight of the nine verbs need no rule change:
GRANT / DROP / DELETE / DEFINE CLUSTER / REPRO / FREE are IDCAMS's/DSN's own fixed command grammar — the same reasoning that already excludes IDCAMS itself from high_risk_execution (the rm/rm -rf / analogy). Per the contract's C4, DELETE/FREE specifically are cleanup's question, and JCL's cleanup rule already models this exact teardown idiom via DISP=(...,DELETE). GRANT/DROP (table-level, not DROP DATABASE) don't fit any of the contract's five families at all — recorded none_owned the same way cobol's EXEC SQL GRANT/REVOKE already is (same auth-surface gap, not ad hoc).
BIND is the one genuine gap — it installs an executable Db2 package (contract family (c), "loading or rewriting code"), and nothing counts it today. It needs a bounded DD */DD DATA payload scanner this engine doesn't have anywhere yet (every jcl.py rule anchors a single // line), which is real engine plumbing with its own golden-master bless — split out to its own issue rather than bundled here: #3010.
PR: #3014 (verified against language-crucible v1.2.0: 0 GAP/MISMATCH, and no existing engine rule spuriously fires on in-stream payload text, validating every none_owned call).
Activity
squid-protocol commentedon Sep 14, 2026
Reviewed the nine verbs against
docs/high_risk_execution_rule_contract.md(#2878) individually rather than as one blob. Full per-verb reasoning is landed as a ledger-style comment injcl.pyabovehigh_risk_execution, and the ownership call is now tracked (not just decided) viatests/tools/embedded_verb_coverage.py'sEXPECTED_JCLtable.Verdict: eight of the nine verbs need no rule change:
RUN PROGRAM/DSN SYSTEMrun inside a DSN session anIKJEFT01step already gets counted for (high_risk_execution) — a payload-level hit would recount the same execution decision at finer grain, the jcl: high_risk_execution counts every EXEC PGM=, so a compiler step and IEFBR14 score as arbitrary execution (design question) #2751 problem in miniature.GRANT/DROP/DELETE/DEFINE CLUSTER/REPRO/FREEare IDCAMS's/DSN's own fixed command grammar — the same reasoning that already excludes IDCAMS itself fromhigh_risk_execution(therm/rm -rf /analogy). Per the contract's C4,DELETE/FREEspecifically arecleanup's question, and JCL'scleanuprule already models this exact teardown idiom viaDISP=(...,DELETE).GRANT/DROP(table-level, notDROP DATABASE) don't fit any of the contract's five families at all — recordednone_ownedthe same way cobol'sEXEC SQL GRANT/REVOKEalready is (same auth-surface gap, not ad hoc).BINDis the one genuine gap — it installs an executable Db2 package (contract family (c), "loading or rewriting code"), and nothing counts it today. It needs a boundedDD */DD DATApayload scanner this engine doesn't have anywhere yet (everyjcl.pyrule anchors a single//line), which is real engine plumbing with its own golden-master bless — split out to its own issue rather than bundled here: #3010.PR: #3014 (verified against language-crucible v1.2.0: 0 GAP/MISMATCH, and no existing engine rule spuriously fires on in-stream payload text, validating every
none_ownedcall).fix(jcl): record #3002's in-stream DSN/IDCAMS payload verbs as owned/…