At GuardRails, we focus on security that doesn't get in your way. That means supporting a quick and easy installation, without any additional configuration.
Nonetheless, we understand that one size doesn't fit all. A great developer experience requires flexibility to configure GuardRails to your needs.
The default configuration looks like this:
enabled: true bundles: "auto" report: pullRequest: "onChangedFiles"
You can use this property to temporarily disable GuardRails, without having to uninstall the GitHub app.
Bundles are set of tools we use to detect security issues in repositories.
Currently, we have 6 bundles:
By default, we run the general bundle, along with the bundle(s) matching the language(s) we detect in your repository. It can happen that we don't detect (all) the language(s) of your repository properly, so you can override the bundles attribute to serve your needs:
You can even go further by overriding the tools that run within a bundle:
Here are all the possibilities:
This attribute enables you to control the behavior of GuardRails in your pull requests. Per default, we only notify you of security issues detected in the files that changed in your pull requests (
The ignore file can come handy if you notice GuardRails is alerting you on some code you deliberately know is vulnerable, or causes false positives. The ignore file follows the gitignore file pattern. Refer to the gitignore docs for more details. One example file is:
If you want to disable one line in particular, you need to add
guardrails-disable-line on the concerned line, usually as a comment.
const mySecret = 'e32kdjksw\'(&dej+' // guardrails-disable-line