-
Notifications
You must be signed in to change notification settings - Fork 153
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'plugin-docs' into 'main'
Plugin documentation See merge request reportcreator/reportcreator!775
- Loading branch information
Showing
9 changed files
with
128 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
# Plugins | ||
<span style="color:orange;">:octicons-alert-fill-24: Experimental. Expect breaking changes.</span> | ||
|
||
The functionality of SysReptor can be extended by plugins. | ||
Plugins can hook into the SysReptor core and provide additional features both in the API and the web UI. | ||
|
||
All plugins are disabled by default. To enable a plugin, add it to the [`ENABLED_PLUGINS`](./configuration.md#plugins) setting. | ||
|
||
|
||
## Official Plugins | ||
|
||
Official plugins are maintained by the SysReptor team and are included in official docker images. | ||
|
||
| Plugin | Description | | ||
| ------ | ----------- | | ||
| [cyberchef](https://github.com/Syslifters/sysreptor/tree/main/plugins/cyberchef) | CyberChef integration | | ||
| [graphqlvoyager](https://github.com/Syslifters/sysreptor/tree/main/plugins/graphqlvoyager) | GraphQL Voyager integration | | ||
| [checkthehash](https://github.com/Syslifters/sysreptor/tree/main/plugins/checkthehash) | Hash identifier | | ||
| [customizetheme](https://github.com/Syslifters/sysreptor/tree/main/plugins/customizetheme) | Customize UI themes per instance | | ||
| [demoplugin](https://github.com/Syslifters/sysreptor/tree/main/plugins/demoplugin) | A demo plugin that demonstrates the plugin system | | ||
| [projectnumber](https://github.com/Syslifters/sysreptor/tree/main/plugins/projectnumber) | Automatically adds an incremental project number to new projects | | ||
| [webhooks](https://github.com/Syslifters/sysreptor/tree/main/plugins/webhooks) | Send webhooks on certain events | | ||
|
||
|
||
<!-- | ||
## Custom Plugins | ||
It is possible to develop and load custom plugins. | ||
The plugin system is currently experimental. Expect breaking changes anytime. Use at own risk. | ||
--> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# Hash Identifier Plugin | ||
Identify hash possible hash types |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
# Customize Theme | ||
|
||
This plugin allows to customize the theme of the SysReptor frontend. | ||
It allows to change settings of light and dark globally per instance. | ||
|
||
|
||
|
||
## Configuration | ||
`PLUGIN_CUSTOMIZETHEME_CONFIG` accepts a JSON object with theme configs. | ||
The provided configurations override the [default theme configs](../../packages/nuxt-base-layer/src/vuetify.config.ts). | ||
All theme configurations provided by Vuetify are supported. See the [Vuetify documentation](https://vuetifyjs.com/en/features/theme/) for more information. | ||
Options in `all` apply to both light and dark mode. Options in `light` and `dark` apply to the respective mode only. | ||
|
||
``` | ||
ENABLED_PLUGINS="customizetheme" | ||
PLUGIN_CUSTOMIZETHEME_CONFIG='{"light": {...}, "dark": {...}, "all": {...}}' | ||
``` | ||
|
||
|
||
## Examples | ||
### Custom Risk Colors | ||
You want to use the same colors for risk levels in the web UI as in the report PDFs? | ||
|
||
```json | ||
{ | ||
"all": { | ||
"colors": { | ||
"risk-critical": "#8c00fc", | ||
"risk-high": "#ed0003", | ||
"risk-medium": "#f0d400", | ||
"risk-low": "#009dff", | ||
"risk-info": "#00bc00" | ||
} | ||
} | ||
} | ||
``` | ||
|
||
### Headers in Corporate Colors | ||
```json | ||
{ | ||
"all": { | ||
"colors": { | ||
"header": "#ff00ff" | ||
} | ||
} | ||
} | ||
``` | ||
|
||
### Matrix Dark Theme | ||
```json | ||
{ | ||
"dark": { | ||
"colors": { | ||
"on-background": "#74ee15", | ||
"on-surface": "#74ee15", | ||
"on-drawer": "#74ee15", | ||
"on-header": "#74ee15" | ||
} | ||
} | ||
} | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
# CyberChef Plugin | ||
Integrate CyberChef into SysReptor. | ||
|
||
``` | ||
ENABLED_PLUGINS="cyberchef" | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
# Demoplugin | ||
|
||
This is a demo plugin that demonstrates the plugin system. | ||
Use this plugin as a reference to develop your own plugins. | ||
|
||
Plugins are loaded as [Django apps](https://docs.djangoproject.com/en/5.1/ref/applications/). Plugins can add API endpoints, views, models, admin pages, signal handlers, and more. | ||
Data can be stored in the database via Django models. Migrations are supported. | ||
|
||
Plugins can extend the frontend by adding pages and menu entries. Each frontend plugin provides an entrypoint script named [`plugin.js`](./frontend/public/plugin.js) as static file. This script is called when the web application is loaded in the browser and performs the necessary plugin setup (e.g. register new routes, add menu entries, etc.). | ||
Plugin pages are loaded as iframes. This allows you to develop frontend plugins with any frontend framework you like, add custom dependencies, or include existing third-party applications. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
# GraphQL Voyager Plugin | ||
Integrate GraphQL Voyager into SysReptor. | ||
|
||
``` | ||
ENABLED_PLUGINS="graphqlvoyager" | ||
``` |