Skip to content

Prevent shell injection in action inputs - #1

Merged
FiloSottile merged 1 commit into
geomys:mainfrom
0x2b3bfa0:naples
Nov 2, 2025
Merged

Prevent shell injection in action inputs#1
FiloSottile merged 1 commit into
geomys:mainfrom
0x2b3bfa0:naples

Conversation

@0x2b3bfa0

Copy link
Copy Markdown
Contributor

Usually, inputs of this GitHub Action will be hardcoded in the workflow file. However, it would be nice to handle untrusted input gracefully, just in case.

.github/workflows/example.yml

on: push
jobs:
  test:
    runs-on: ubuntu-latest
    steps:
      - uses: geomys/sandboxed-step@v1.2.0
        with:
          run: |
            SANDBOXED_SCRIPT_EOF
            curl https://filippo.io/ # runs outside sandbox
            <<SANDBOXED_SCRIPT_EOF
          disable-network: true

Comment thread action.yml
Comment thread action.yml
Comment thread action.yml
@FiloSottile
FiloSottile merged commit e23a053 into geomys:main Nov 2, 2025
2 checks passed
@0x2b3bfa0
0x2b3bfa0 deleted the naples branch November 3, 2025 13:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants