Skip to content

Plugins Command

Official plugins: https://github.com/rootcausescan/plugins

The plugins module helps manage plugins within the SAST workflow.

bash
$>rootcause plugins -h
Manage plugins for extending RootCause functionality

Usage: rootcause plugins <COMMAND>

Commands:
  verify   Verify that a plugin works correctly
  ping     Ping a plugin to verify connectivity
  init     Initialise a new plugin from a template
  install  Install a plugin from a local path or remote repository
  list     List all installed plugins
  remove   Remove an installed plugin
  disable  Disable an installed plugin
  enable   Enable a previously disabled plugin
  config   Configure plugin parameters
  help     Print this message or the help of the given subcommand(s)

Options:
  -h, --help  Print help

Plugin location

By default, RootCause installs plugins in:

  • ~/.config/rootcause/plugins (Linux/macOS)
  • %APPDATA%\rootcause\plugins (Windows)

Plugin configuration

Plugins are configured in the config.toml file:

toml
[plugins]
[plugins.pdf-report]
enabled = true
output = "report.pdf"
output_dir = "/tmp/output.pdf"

[plugins.rust-analyze]
enabled = false

Using plugins during scans

Plugins can be used during scans with the following options:

bash
# Specify a plugin
rootcause scan . --plugin ./my-plugin

# Multiple plugins
rootcause scan . --plugin ./plugin1 --plugin ./plugin2

# Plugin options
rootcause scan . --plugin ./my-plugin --plugin-opt param1=value1 --plugin-opt param2=value2

# Plugin configuration file
rootcause scan . --plugin ./my-plugin --plugin-config ./config.json

Plugin types

RootCause supports different plugin types depending on their capabilities:

TypeDescription
DiscoverDiscover files and directories for analysis
TransformTransform content before analysis
AnalysePerform additional code analysis
RulesProvide custom rules
ReportGenerate reports in specific formats

RootCause - Modular Static Analysis Engine