QWED Security rule catalog
Generated fromscan_rules.py at rule set qwed-security-ruleset/5. Every rule ID used in a QWED annotation anchors here as #<rule-id>.
This page intentionally contains live trip strings. Findings on it are covered by narrowly scoped base-branch policy entries (see .qwed.yml) — NOT by inline markers: on introduced lines the pipeline voids inline suppression comments as self-suppression, and a voided inline marker then shadows the policy entry that would otherwise apply. Never add qwed-ignore to generated trip lines.
Policy: non-downgradable categories
These categories are never downgraded to INFO for sitting in a non-executable context (comment, docstring, test, demo):Rule reference
eval-call
Enginepattern_scan · category dynamic_execution · base action BLOCK · source: PATTERN_RULES
eval() executes untrusted code. In agentic pipelines, LLM- or caller-controlled expressions reach this sink.
exec-call
Enginepattern_scan · category dynamic_execution · base action BLOCK · source: PATTERN_RULES
exec() executes untrusted code. In agentic pipelines, LLM- or caller-controlled expressions reach this sink.
dynamic-import
Enginepattern_scan · category dynamic_import · base action WARNING · source: PATTERN_RULES
Dynamic import() call should be reviewed.
compile-call
Enginepattern_scan · category code_generation · base action WARNING · source: PATTERN_RULES
compile() can be part of dynamic code generation.
os-system
Enginepattern_scan · category shell_execution · base action BLOCK · source: PATTERN_RULES
os.system() shell execution primitive detected.
subprocess-call
Enginepattern_scan · category external_process · base action WARNING · source: PATTERN_RULES
subprocess invocation detected.
os-popen
Enginepattern_scan · category shell_execution · base action BLOCK · source: PATTERN_RULES
os.popen() shell execution primitive detected.
path-traversal
Enginepattern_scan · category path_traversal · base action BLOCK · source: PATTERN_RULES
Path traversal sequence detected.
hardcoded-secret
Enginepattern_scan · category secret_exposure · base action BLOCK · source: PATTERN_RULES
Hardcoded credential-like material detected.
hardcoded-secret-dict
Enginepattern_scan · category secret_exposure · base action BLOCK · source: PATTERN_RULES
Hardcoded credential-like material in dictionary/config literal detected.
url-embedded-credential
Enginepattern_scan · category secret_exposure · base action BLOCK · source: PATTERN_RULES
Credential embedded in URL userinfo (user:pass@) — the value is a connection string, not a reference.
url-query-credential
Enginepattern_scan · category secret_exposure · base action BLOCK · source: PATTERN_RULES
Credential in URL query or fragment parameter (?token=…, #password=…).
url-unknown-param-credential
Enginepattern_scan · category secret_exposure · base action BLOCK · source: PATTERN_RULES
Credential-shaped value on an unknown URL parameter — unknown names with key-material values are secrets.
url-path-credential
Enginepattern_scan · category secret_exposure · base action BLOCK · source: PATTERN_RULES
Credential material embedded in URL path segment (/bearer/<token>, /reset/<secret>).
openai-secret
Enginepattern_scan · category secret_exposure · base action BLOCK · source: PATTERN_RULES
OpenAI-style secret token detected.
github-secret
Enginepattern_scan · category secret_exposure · base action BLOCK · source: PATTERN_RULES
GitHub token-like secret detected.
github-fine-grained-pat
Enginepattern_scan · category secret_exposure · base action BLOCK · source: PATTERN_RULES
GitHub fine-grained personal access token detected.
github-oauth-token
Enginepattern_scan · category secret_exposure · base action BLOCK · source: PATTERN_RULES
GitHub OAuth/server-to-server token detected.
gitlab-pat
Enginepattern_scan · category secret_exposure · base action BLOCK · source: PATTERN_RULES
GitLab personal access token detected.
slack-token
Enginepattern_scan · category secret_exposure · base action BLOCK · source: PATTERN_RULES
Slack token detected.
stripe-live-key
Enginepattern_scan · category secret_exposure · base action BLOCK · source: PATTERN_RULES
Stripe live secret key detected.
anthropic-key
Enginepattern_scan · category secret_exposure · base action BLOCK · source: PATTERN_RULES
Anthropic API key detected.
google-api-key
Enginepattern_scan · category secret_exposure · base action BLOCK · source: PATTERN_RULES
Google API key detected.
jwt-token
Enginepattern_scan · category secret_exposure · base action WARNING · source: PATTERN_RULES
JWT-like token detected; verify it is not a live credential.
aws-secret
Enginepattern_scan · category secret_exposure · base action BLOCK · source: PATTERN_RULES
AWS access-key-like secret detected.
private-key-block
Enginepattern_scan · category secret_exposure · base action BLOCK · source: PATTERN_RULES
Private key material detected — a committed PEM/DER key block is a credential, whatever the file’s name or extension.
sql-fstring-select
Enginepattern_scan · category sql_injection · base action WARNING · source: PATTERN_RULES
Potential SQL query interpolation via f-string.
sql-fstring-insert
Enginepattern_scan · category sql_injection · base action WARNING · source: PATTERN_RULES
Potential SQL query interpolation via f-string.
sql-fstring-delete
Enginepattern_scan · category sql_injection · base action WARNING · source: PATTERN_RULES
Potential SQL query interpolation via f-string.
sql-fstring-update
Enginepattern_scan · category sql_injection · base action WARNING · source: PATTERN_RULES
Potential SQL query interpolation via f-string.
pickle-load
Enginepattern_scan · category unsafe_deserialization · base action BLOCK · source: PATTERN_RULES
pickle deserialization executes embedded code — treat pickle input as code execution, especially in agent pipelines.
yaml-load
Enginepattern_scan · category unsafe_deserialization · base action WARNING · source: PATTERN_RULES
yaml.load without an explicit Loader is unsafe — and raises TypeError on PyYAML >= 6.0.1. Use yaml.safe_load.
marshal-load
Enginepattern_scan · category unsafe_deserialization · base action BLOCK · source: PATTERN_RULES
marshal deserialization can execute untrusted state.
shelve-open
Enginepattern_scan · category unsafe_deserialization · base action WARNING · source: PATTERN_RULES
shelve uses pickle under the hood and needs trust review.
bind-all-interfaces
Enginepattern_scan · category network_binding · base action WARNING · source: PATTERN_RULES
Binding to 0.0.0.0 exposes the service broadly.
weak-random
Enginepattern_scan · category insecure_random · base action WARNING · source: PATTERN_RULES
Non-cryptographic random usage detected.
mktemp
Enginepattern_scan · category insecure_tempfile · base action WARNING · source: PATTERN_RULES
tempfile.mktemp() is vulnerable to race conditions.
assert-validation
Enginepattern_scan · category weak_assert_validation · base action WARNING · source: PATTERN_RULES
assert should not be the only input-validation boundary.
config-password
Enginesecret_scan · category secret_exposure · base action BLOCK · source: SECRET_RULES
Password-like secret found in configuration.
config-secret
Enginesecret_scan · category secret_exposure · base action BLOCK · source: SECRET_RULES
Secret-like material found in configuration.
config-private-key
Enginesecret_scan · category secret_exposure · base action BLOCK · source: SECRET_RULES
Private key material found in configuration.
config-db-creds
Enginesecret_scan · category secret_exposure · base action BLOCK · source: SECRET_RULES
Database URL contains embedded credentials.
config-github-pat
Enginesecret_scan · category secret_exposure · base action BLOCK · source: SECRET_RULES
GitHub fine-grained personal access token in configuration.
config-gitlab-pat
Enginesecret_scan · category secret_exposure · base action BLOCK · source: SECRET_RULES
GitLab personal access token in configuration.
config-slack-token
Enginesecret_scan · category secret_exposure · base action BLOCK · source: SECRET_RULES
Slack token in configuration.
config-stripe-live
Enginesecret_scan · category secret_exposure · base action BLOCK · source: SECRET_RULES
Stripe live secret key in configuration.
fail-open-guard
Engineverification_integrity · category fail_open · base action WARNING · source: VERIFICATION_INTEGRITY_RULES
Multi-condition guard may be implicitly fail-open: if a middle field is None/missing, the entire check is skipped. Prefer checking each field independently.
exception-info-leak
Engineverification_integrity · category information_disclosure · base action WARNING · source: VERIFICATION_INTEGRITY_RULES
str(exc) may leak internal stack traces, file paths, or credentials to API clients. Use a sanitized error message instead.
empty-except-pass
Engineverification_integrity · category error_suppression · base action WARNING · source: VERIFICATION_INTEGRITY_RULES
Empty except block silently swallows errors. This can hide security failures and verification boundary violations.
Known engine gap: the live pattern scanner matches line-by-line, so this multi-line shape is currently undetectable in production (tracked in issue #88). The trip below documents the rule definition, not a live detection.
codeguard-getattr-builtins
Enginecodeguard · category dynamic_execution · base action BLOCK · source: CODEGUARD_RULES
getattr() on builtins enables sandbox escape and hidden code execution. Note: builtins is a dict at module scope, a module in main — both forms signal evasion.
codeguard-builtins-dict
Enginecodeguard · category dynamic_execution · base action BLOCK · source: CODEGUARD_RULES
Direct builtins.dict access enables hidden function lookup.
codeguard-b64-payload
Enginecodeguard · category obfuscation · base action WARNING · source: CODEGUARD_RULES
base64-decoded payload detected; decoded content is unscannable and requires review.
codeguard-chr-obfuscation
Enginecodeguard · category obfuscation · base action WARNING · source: CODEGUARD_RULES
chr() string concatenation is a common obfuscation technique.
curl-pipe-shell
Engineshell_safety · category shell_execution · base action BLOCK · source: SHELL_RULES
Pipe-to-shell pattern detected.
wget-pipe-shell
Engineshell_safety · category shell_execution · base action BLOCK · source: SHELL_RULES
Pipe-to-shell pattern detected.
chmod-777
Engineshell_safety · category permission_broadening · base action WARNING · source: SHELL_RULES
chmod 777 grants overly broad permissions.
chmod-setuid
Engineshell_safety · category privilege_escalation · base action BLOCK · source: SHELL_RULES
setuid bit can introduce privilege-escalation paths.
dd-disk-write
Engineshell_safety · category disk_write · base action BLOCK · source: SHELL_RULES
Direct disk write detected.
js-eval
Enginejs_patterns · category dynamic_execution · base action BLOCK · source: JS_PATTERN_RULES
DYNAMIC_EXECUTION_BOUNDARY violation: eval in JavaScript enables arbitrary code execution.
js-innerhtml
Enginejs_patterns · category xss · base action BLOCK · source: JS_PATTERN_RULES
XSS_BOUNDARY violation: innerHTML assignment enables XSS attacks.
js-document-write
Enginejs_patterns · category xss · base action WARNING · source: JS_PATTERN_RULES
XSS_BOUNDARY violation: document.write can introduce XSS.
js-dangerously-set
Enginejs_patterns · category xss · base action BLOCK · source: JS_PATTERN_RULES
XSS_BOUNDARY violation: React dangerouslySetInnerHTML bypasses XSS protection.
js-proto-pollution
Enginejs_patterns · category prototype_pollution · base action BLOCK · source: JS_PATTERN_RULES
PROTOTYPE_POLLUTION_BOUNDARY violation: prototype pollution vector detected.
js-constructor-proto
Enginejs_patterns · category prototype_pollution · base action WARNING · source: JS_PATTERN_RULES
PROTOTYPE_POLLUTION_BOUNDARY violation: prototype pollution via constructor.
js-new-function
Enginejs_patterns · category dynamic_execution · base action BLOCK · source: JS_PATTERN_RULES
DYNAMIC_EXECUTION_BOUNDARY violation: new Function is equivalent to eval.
js-settimeout-string
Enginejs_patterns · category dynamic_execution · base action WARNING · source: JS_PATTERN_RULES
setTimeout with a string arg evaluates code (and throws TypeError in Node.js — pass a function callback).
js-setinterval-string
Enginejs_patterns · category dynamic_execution · base action WARNING · source: JS_PATTERN_RULES
DYNAMIC_EXECUTION_BOUNDARY violation: setInterval with string arg executes code.
js-child-process
Enginejs_patterns · category shell_execution · base action WARNING · source: JS_PATTERN_RULES
SHELL_EXECUTION_BOUNDARY violation: child_process module enables shell execution.
js-exec-concat
Enginejs_patterns · category shell_execution · base action BLOCK · source: JS_PATTERN_RULES
child_process exec with string concatenation or template interpolation enables command injection.
js-require-fs
Enginejs_patterns · category path_traversal · base action WARNING · source: JS_PATTERN_RULES
PATH_TRAVERSAL_BOUNDARY violation: direct fs require enables file system access.
go-exec-shell
Enginego_patterns · category shell_execution · base action BLOCK · source: GO_PATTERN_RULES
SHELL_EXECUTION_BOUNDARY violation: exec.Command invoking a shell interpreter enables command injection.
go-exec-command
Enginego_patterns · category external_process · base action WARNING · source: GO_PATTERN_RULES
EXTERNAL_PROCESS_BOUNDARY: exec.Command launches an external process; verify arguments are not attacker-controlled.
go-unsafe-import
Enginego_patterns · category low_level_module · base action WARNING · source: GO_PATTERN_RULES
LOW_LEVEL_BOUNDARY: importing “unsafe” disables Go type-safety guarantees.
go-unsafe-pointer
Enginego_patterns · category low_level_module · base action WARNING · source: GO_PATTERN_RULES
LOW_LEVEL_BOUNDARY: unsafe.Pointer bypasses type safety; requires memory-safety review.
go-sql-concat
Enginego_patterns · category sql_injection · base action WARNING · source: GO_PATTERN_RULES
SQL_INJECTION_BOUNDARY: SQL built by string concatenation; use parameterized queries.
go-sql-sprintf
Enginego_patterns · category sql_injection · base action WARNING · source: GO_PATTERN_RULES
SQL_INJECTION_BOUNDARY: SQL built with fmt.Sprintf; use parameterized queries.
go-tls-skip-verify
Enginego_patterns · category network_binding · base action BLOCK · source: GO_PATTERN_RULES
NETWORK_BOUNDARY: TLS certificate verification disabled; enables man-in-the-middle attacks.
go-weak-md5
Enginego_patterns · category insecure_random · base action WARNING · source: GO_PATTERN_RULES
MD5 is cryptographically broken; use SHA-256 or stronger for security purposes.
go-weak-sha1
Enginego_patterns · category insecure_random · base action WARNING · source: GO_PATTERN_RULES
SHA-1 is cryptographically weak; use SHA-256 or stronger for security purposes.
go-template-html
Enginego_patterns · category xss · base action WARNING · source: GO_PATTERN_RULES
XSS_BOUNDARY: template.HTML marks content as safe and bypasses auto-escaping; verify it is not user-controlled.
go-hardcoded-secret
Enginego_patterns · category secret_exposure · base action BLOCK · source: GO_PATTERN_RULES
SECRET_EXPOSURE_BOUNDARY: hardcoded credential-like material detected.
rust-unsafe-block
Enginerust_patterns · category low_level_module · base action WARNING · source: RUST_PATTERN_RULES
LOW_LEVEL_BOUNDARY: unsafe block disables Rust memory-safety guarantees; audit for UB.
rust-unsafe-fn
Enginerust_patterns · category low_level_module · base action WARNING · source: RUST_PATTERN_RULES
LOW_LEVEL_BOUNDARY: unsafe fn/impl/trait shifts safety proof obligations to every caller.
rust-command-shell
Enginerust_patterns · category shell_execution · base action BLOCK · source: RUST_PATTERN_RULES
SHELL_EXECUTION_BOUNDARY violation: Command::new invoking a shell interpreter enables command injection.
rust-command
Enginerust_patterns · category external_process · base action WARNING · source: RUST_PATTERN_RULES
EXTERNAL_PROCESS_BOUNDARY: Command::new launches an external process; verify arguments are not attacker-controlled.
rust-transmute
Enginerust_patterns · category low_level_module · base action WARNING · source: RUST_PATTERN_RULES
LOW_LEVEL_BOUNDARY: mem::transmute reinterprets memory across types; requires unsafe and careful review.
rust-sql-format
Enginerust_patterns · category sql_injection · base action WARNING · source: RUST_PATTERN_RULES
SQL_INJECTION_BOUNDARY: SQL built with format!; use parameterized queries.
rust-sql-concat
Enginerust_patterns · category sql_injection · base action WARNING · source: RUST_PATTERN_RULES
SQL_INJECTION_BOUNDARY: SQL built by string concatenation; use parameterized queries.
rust-weak-md5
Enginerust_patterns · category insecure_random · base action WARNING · source: RUST_PATTERN_RULES
MD5 is cryptographically broken; use SHA-256 or stronger for security purposes.
rust-weak-sha1
Enginerust_patterns · category insecure_random · base action WARNING · source: RUST_PATTERN_RULES
SHA-1 is cryptographically weak; use SHA-256 or stronger for security purposes.
rust-deref-raw
Enginerust_patterns · category low_level_module · base action WARNING · source: RUST_PATTERN_RULES
LOW_LEVEL_BOUNDARY: raw pointer operation; requires unsafe and memory-safety review.
rust-hardcoded-secret
Enginerust_patterns · category secret_exposure · base action BLOCK · source: RUST_PATTERN_RULES
SECRET_EXPOSURE_BOUNDARY: hardcoded credential-like material detected.
docker-run-root
Enginedocker_scan · category privilege_escalation · base action WARNING · source: DOCKER_RULES
PRIVILEGE_ESCALATION_BOUNDARY violation: container runs as root user.
docker-latest-tag
Enginedocker_scan · category supply_chain · base action WARNING · source: DOCKER_RULES
SUPPLY_CHAIN_BOUNDARY violation: using :latest tag, pin to specific version.
docker-malformed-from
Enginedocker_scan · category supply_chain · base action WARNING · source: DOCKER_RULES
Malformed FROM reference: multiple tags in one image line. Use a single tag or a digest.
docker-add-remote
Enginedocker_scan · category supply_chain · base action BLOCK · source: DOCKER_RULES
SUPPLY_CHAIN_BOUNDARY violation: ADD from remote URL, use COPY + verified download.
docker-env-secret
Enginedocker_scan · category secret_exposure · base action BLOCK · source: DOCKER_RULES
SECRET_EXPOSURE_BOUNDARY violation: secret hardcoded in Dockerfile ENV.
docker-expose-22
Enginedocker_scan · category network_binding · base action WARNING · source: DOCKER_RULES
NETWORK_BINDING_BOUNDARY violation: SSH port exposed in container.
ci-unpinned-action
Engineci_scan · category supply_chain · base action WARNING · source: CI_RULES
SUPPLY_CHAIN_BOUNDARY violation: GitHub Action pinned to branch, not SHA.
ci-script-injection
Engineci_scan · category code_injection · base action BLOCK · source: CI_RULES
CODE_INJECTION_BOUNDARY violation: potential script injection via github.event context.
ci-pull-request-target
Engineci_scan · category privilege_escalation · base action WARNING · source: CI_RULES
PRIVILEGE_ESCALATION_BOUNDARY violation: pull_request_target gives write access to forks.
ci-permissions-write-all
Engineci_scan · category privilege_escalation · base action WARNING · source: CI_RULES
PRIVILEGE_ESCALATION_BOUNDARY violation: overly broad CI permissions.
ci-curl-pipe
Engineci_scan · category shell_execution · base action BLOCK · source: CI_RULES
SHELL_EXECUTION_BOUNDARY violation: curl pipe to shell in CI workflow.
high-entropy-secret
Engineentropy_scan · category secret_exposure · base action BLOCK · source: ENTROPY_ASSIGNMENT_REGEX
High-entropy credential-like value assigned to a sensitive variable name (>= 4.5 bits/char).
Generic assignment of a long random-looking string to a credential-named variable; the value must clear 4.5 bits/char Shannon entropy to BLOCK.
qwed-sdk-mock-no-direct
Engineverification_integrity · category weak_test_coverage · base action WARNING · source: detect_qwed_sdk_mock() (structural detector)
QWED SDK client/verifier is mocked without any direct SDK invocation in the same context. The test verifies the mock contract, not the real verification boundary. Prefer an integration test against the local engine or assert on the mock’s call arguments.
Trips:
qwed-disabled-env
Engineverification_integrity · category fail_open · base action WARNING · source: detect_disabled_guard() (structural detector)
QWED_ENABLED=false disables the QWED verification boundary. If this is a permanent production configuration it violates the fail-closed trust model.
Trips:
qwed-disable-call
Engineverification_integrity · category fail_open · base action WARNING · source: detect_disabled_guard() (structural detector)
qwed.disable() turns off the verification boundary at runtime. Confirm this is intentional and scoped to non-production paths only.
Trips:
qwed-guard-disabled
Engineverification_integrity · category fail_open · base action WARNING · source: detect_disabled_guard() (structural detector)
A QWED guard is explicitly disabled. Review whether the guard can be safely bypassed for this code path.
Trips:
qwed-suppression-fatigue
Engineverification_integrity · category suppression_abuse · base action WARNING · source: detect_suppression_fatigue() (structural detector)
5+ qwed-ignore suppressions in this file. High suppression density indicates the verification boundary is being systematically silenced. Review whether the suppressions are justified or indicate a systemic issue.
Trips:
developer-field-promotion-leak
Engineverification_integrity · category release_boundary_violation · base action BLOCK · source: detect_developer_fields_token_leak() (structural detector)
Credential-like key in developer_fields will be merged into the public API response payload by merge_diagnostic_result, exposing the credential to clients. Store such material in enforcement function args (not response metadata) and expose only proof_ref to the response consumer.
Block: storing attestation/jwt/token material in developer_fields when
Trips:
round-in-verification-evidence
Engineverification_integrity · category artifact_boundary_ambiguity · base action WARNING · source: detect_round_in_verification_fields() (structural detector)
round(…, n) inside verification metadata (developer_fields/evidence) preserves floating-point semantics incompatible with QWED SYMBOLIC MATH contracts. Serialize via Decimal or string with ROUND_HALF_UP instead.
Informational: developer_fields populated with round(…, n) violates
Trips:
mocked-verifier-no-direct
Engineverification_integrity · category weak_test_coverage · base action WARNING · source: detect_mocked_verifier_no_execution() (structural detector)
Verifier engine is mocked but never executed in this test. The test regression boundary has zero coverage against the engine branch. Assert on the branch-specific output fields not generic status fallbacks.
Hits when test file mocks a verifier engine without direct execution.
Trips:
Generated by
generate_rule_catalog.py from scan_rules.py. Regenerate with python generate_rule_catalog.py; CI fails on drift.