Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add unverified_script_exec rule #129

Merged
merged 3 commits into from
Jun 18, 2024

Conversation

becojo
Copy link
Contributor

@becojo becojo commented Jun 18, 2024

  • Add a rule to detect curl|bash and related patterns
    • The rule is targeted to identify popular installation scripts that end up in workflows rather than all the possible ways a bash script can load external scripts.
    • The rule considers scripts loaded from a commit sha on a GitHub repository to have been "verified"
  • Add a test to validate that built-in rules have correct metadata for the SARIF level

Docs will be in the next pr

@becojo becojo requested a review from a team as a code owner June 18, 2024 13:37
@fproulx-boostsecurity fproulx-boostsecurity merged commit 4f6ca1b into main Jun 18, 2024
8 checks passed
@fproulx-boostsecurity fproulx-boostsecurity deleted the unverified-script-exec branch June 18, 2024 14:13
fproulx-boostsecurity added a commit to fproulx-boostsecurity/homebrew-core that referenced this pull request Jun 25, 2024
Created with `brew bump-formula-pr`.<details>
  <summary>release notes</summary>
  <pre># Changelog for `poutine` v0.12.0 🚀

## New Features 🌟
- **Quiet Mode**: Added a new `--quiet` option to minimize output verbosity during scans, helping streamline outputs for automated processes. ([Homebrew#134](boostsecurityio/poutine#134))
- **Security Rule**: Introduced the `unverified_script_exec` rule to detect potentially unsafe script executions in CI environments. ([Homebrew#129](boostsecurityio/poutine#129))

## Improvements 🔧
- **Custom References**: Enhanced the `analyze_repo` command to accept custom references, enabling more precise analysis across different repo states. ([Homebrew#131](boostsecurityio/poutine#131))
- **Homebrew Integration**: Updated documentation to refer to the new Homebrew core formula, simplifying installation processes. ([Homebrew#124](boostsecurityio/poutine#124))
- **Open Policy Agent (OPA)**: Exposed new JSON marshalling options in OPA, enhancing flexibility in policy definitions. ([Homebrew#133](boostsecurityio/poutine#133))

## Fixes 🛠️
- **Dependency Handling**: Improved error avoidance by preventing a second Rego compilation during JSON format operations. ([Homebrew#132](boostsecurityio/poutine#132))

## Dependency Updates ⬆️
- **Retryable HTTP**: Bumped `github.com/hashicorp/go-retryablehttp` to leverage enhancements in retry logic and error handling. ([Homebrew#135](boostsecurityio/poutine#135))

## Release process changes 🔧
- **Release Process**: Updated `.goreleaser.yaml` and removed reference to local tap. ([Homebrew#136](boostsecurityio/poutine#136)), ([Homebrew#128](boostsecurityio/poutine#128))

## Contributions 🤝
- Thanks to all contributors for continuing to improve `poutine`, ensuring it remains a robust tool for securing CI pipelines.

## Full Changelog 📜
For a detailed diff of everything new and updated, see the [full changelog](boostsecurityio/poutine@v0.11.0...v0.12.0).
</pre>
</details>
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