Skip to content

[static-analysis] Suppress RGS-018 false positive in daily-workflow-security-model #73436

Done

Description

@github-actions

Caution

Protected files were modified in this change.
This pull request is in request-review mode and requires explicit human scrutiny before merge.

Protected files: .github/workflows/daily-workflow-security-model.md

Allow intentional protected-file changes

If this workflow is intended to modify these files, add specific filenames or folder prefixes to safe-outputs.create-pull-request.protected-files.exclude in the workflow Markdown frontmatter. For example, to allow .changeset/*, exclude the folder using .changeset/:

safe-outputs:
  create-pull-request:
    protected-files:
      policy: request-review
      exclude:
        - .changeset/

Keep your existing policy and exclusions. Folder exclusions use path prefixes, not glob patterns, and allow all files beneath that folder, including subfolders. Other protected files still require review. If allowed-files is configured, these paths must also match it. Run gh aw compile after updating the workflow.

Warning

Changes to workflow YAML files were excluded from this changeset to avoid GitHub token workflow-write restrictions. Run gh aw compile again on this branch and commit the regenerated .lock.yml files using credentials permitted to update GitHub Actions workflows before merging.

Summary

  • runner-guard (RGS-018, high) flagged the "Prepare pinned TLA+ runtime" step in .github/workflows/daily-workflow-security-model.md as a suspicious payload-execution pattern.
  • Root cause: the step downloads a pinned JRE and TLA+ tooling release and verifies each against a hardcoded sha256 checksum before use — a standard secure download pattern. One checksum's hex string (...e5a5e87d38328b64eec2c5b500) coincidentally contains a b64e-like substring, which matched a base64-decode threat-signature fragment rather than indicating any payload decoding.
  • Fix: added an inline # runner-guard:ignore RGS-018 comment as the first line of the step's script body (not a YAML sibling comment before run:), because the gh-aw compiler parses and re-serializes custom steps: from markdown frontmatter, which drops standalone YAML comments outside scalar values. Placing the comment inside the run: | block scalar preserves it through compilation — the same technique already used successfully elsewhere in the repo, e.g. .github/workflows/daily-geo-optimizer.md.

Evidence

Finding from the static-analysis compile run:

.github/workflows/daily-workflow-security-model.lock.yml:620:1: error: [high] RGS-018: Suspicious Payload Execution Pattern - ...

The flagged step does curl --fail ... --output "$tools/jre.tar.gz" then printf '%s %s\n' <hardcoded-sha256> "$tools/jre.tar.gz" | sha256sum --check --strict (and the same pattern for the TLA+ tools jar), extracting only after verification succeeds. There is no dynamic/attacker-controlled content — only literal checksum strings that happen to contain a short substring resembling a base64 marker.

Validation

  • ./gh-aw compile .github/workflows/daily-workflow-security-model.md --validate --verbose recompiles cleanly.
  • Confirmed the comment actually survives compilation this time (an earlier attempt placing it between - name: and run: | was silently dropped by the YAML round-trip — caught and corrected before this PR by diffing the regenerated .lock.yml).
  • scripts/agent-report-progress.sh confirms the regenerated lock file is up to date with no drift from the source change.
  • Could not rerun the Docker-based runner-guard scanner itself in this sandbox (Docker-in-Docker is unsupported here). Verified by inspection instead: the comment is 1 line above the step's first command, well within runnerGuardIgnoreLookAhead = 35 lines, matching the pattern validated by go test ./pkg/cli/... -run 'RunnerGuard' (passing).

Note: .lock.yml changes are stripped from pull request delivery by this workflow's configuration; a maintainer must run gh aw compile again and commit the regenerated lock (included here for validation) before merge.

🔍 Static analysis source: workflow run #41169478968


Note

This was originally intended as a pull request, but the git push operation failed.

Original error: ERR_SYSTEM: git push failed (exit code 1): To https://github.com/github/gh-aw.git ! [remote rejected] static-analysis/rgs-018-security-model-a3421ac624ad2dfe -> static-analysis/rgs-018-security-model-a3421ac624ad2dfe (refusing to allow a GitHub App to create or update workflow `.github/workflows/daily-workflow-security-model.md` without `workflows` permission) error: failed to push some refs to 'https://github.com/github/gh-aw.git'

Workflow Run: View run details and download bundle artifact

The bundle file is available in the agent artifact in the workflow run linked above.

Create the pull request manually
# Download the artifact from the workflow run
gh run download '41169478968' -n agent -D '/tmp/agent-41169478968'

# Resolve the bundle source ref, fetch it into a temporary ref, then create the local branch
bundle_path='/tmp/agent-41169478968/aw-github-gh-aw-static-analysis-rgs-018-security-model.bundle'
temp_ref='refs/bundles/create-pr-static-analysis-rgs-018-security-model-a3421ac624ad2dfe-6763f5cb'
target_ref='refs/heads/static-analysis/rgs-018-security-model-a3421ac624ad2dfe'
bundle_source_ref=$(git bundle list-heads "$bundle_path" | awk '$2 ~ /^refs\/heads\// { print $2 }')
if [ -z "$bundle_source_ref" ]; then
  bundle_source_ref=$(git bundle list-heads "$bundle_path" | awk '$2 == "HEAD" { print $2 }')
fi
if [ "$(printf '%s\n' "$bundle_source_ref" | sed '/^$/d' | wc -l | tr -d ' ')" != "1" ]; then
  echo "Expected exactly one bundle source ref, found: $bundle_source_ref" >&2
  exit 1
fi
git fetch "$bundle_path" "${bundle_source_ref}:${temp_ref}"
git update-ref "$target_ref" "$temp_ref"
git checkout 'static-analysis/rgs-018-security-model-a3421ac624ad2dfe'
# Ensure the working tree matches the updated branch
git reset --hard
# Remove the temporary bundle ref
git update-ref -d "$temp_ref"

# Push the branch to the target remote
git push 'origin' 'static-analysis/rgs-018-security-model-a3421ac624ad2dfe'

# Create the pull request
gh pr create --title '[static-analysis] Suppress RGS-018 false positive in daily-workflow-security-model' --base 'main' --head 'static-analysis/rgs-018-security-model-a3421ac624ad2dfe' --repo 'github/gh-aw'

Generated by 📊 Static Analysis Report · claude · agent · ~593 AIC · ⌖ ~2 AIC · ⊞ 4.9K · ◷

  • expires on Nov 6, 2026, 9:39 PM UTC-08:00

Activity

  1. github-actions commented on Nov 3, 2026

    @github-actions
    ContributorAuthor

    🍪 Issue Monster selected this for Cloclo

    I've identified this issue as a good candidate for automated resolution and requested a Cloclo workflow run to fix it.

    If dispatch succeeds, Cloclo will analyze the issue and create a pull request with the fix.

    Om nom nom! 🍪

    🍪 Om nom nom by Issue Monster · pi · gpt50 · ~1 AIC · ⌖ ~2 AIC · ⊞ 13.3K · ◷

  2. github-actions commented on Nov 4, 2026

    @github-actions
    ContributorAuthor

    🍪 Issue Monster selected this for Copilot

    I've identified this issue as a good candidate for automated resolution and requested assignment to the Copilot coding agent.

    If assignment succeeds, Copilot will analyze the issue and create a pull request with the fix.

    Om nom nom! 🍪

    🍪 Om nom nom by Issue Monster · pi · gpt50 · ~1 AIC · ⌖ ~1 AIC · ⊞ 13.4K · ◷

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

agentic-workflowsautomationcookiesecurity

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions