Skip to content

Commit fe560ac

Browse files
Feature/docs/281 add documentation on advanced installation and configuration (#286)
Co-authored-by: Maarten de Kruijf <[email protected]>
1 parent d1ada75 commit fe560ac

File tree

20 files changed

+1163
-141
lines changed

20 files changed

+1163
-141
lines changed

docs/content/en/docs/_index.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,6 @@ SOARCA currently supports the following transport mechanisms:
3939
{{% card header="SSH - Native" %}}
4040
[![Ssh](/SOARCA/images/logos-external/ssh.svg)](/docs/soarca-extensions/native-capabilities/#ssh-capability)
4141
{{% /card %}}
42-
</div>
4342

4443
{{% card header="PowerShell WinRM - Native" %}}
4544
[![PowerShell](/SOARCA/images/logos-external/powershell.svg)](/docs/soarca-extensions/native-capabilities/#powershell-capability)

docs/content/en/docs/concepts/executable-playbooks.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ resources:
1212
SOARCA is build on top of the [CACAO Security Playbook Version 2.0](https://docs.oasis-open.org/cacao/security-playbooks/v2.0/cs01/security-playbooks-v2.0-cs01.html) standard.
1313

1414
{{% alert title="Warning" color="warning" %}}
15-
SOARCA v1.0 only implements a part of the CACAO v2 spec. Only `start`, `end`, and `action` steps are supported at this time.
15+
SOARCA v1.0 only implements a part of the CACAO v2 spec. Only `start`, `end`, `action`, and `if/else` steps are supported at this time.
1616
{{% /alert %}}
1717

1818
A CACAO playbook is a structured document that outlines a series of orchestrated actions to address specific security events, incidents, or other security-related activities. These playbooks allow for the automation of security steps.
@@ -390,4 +390,4 @@ This is de JSON data of the playbook used throughout this page.
390390
}
391391
}
392392
}
393-
```
393+
```

docs/content/en/docs/core-components/_index.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: Design
3-
weight: 5
3+
weight: 6
44
description: >
55
The design of SOARCA
66
@@ -12,7 +12,6 @@ SOARCA consists of several key components:
1212
2. **SOARCA Native Capabilities**: These are the functionalities explicitly defined in the Cacao v2 specification and are integral to the core. They are also represented in green.
1313
3. **Fins**: These are the extension capabilities, also known as Fins. They enhance the functionality and integration of SOARCA and are depicted in orange. These are not (yet) part of this repository, but may be implemented by partners or TNO in the future.
1414

15-
1615
![core](/SOARCA/images/core_color.png)
1716

1817
## Core component overview

docs/content/en/docs/core-components/api-reporter.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ weight: 2
99

1010
# Endpoint description
1111

12-
We will use HTTP status codes <https://en.wikipedia.org/wiki/List_of_HTTP_status_codes>
12+
We will use HTTP status codes https://en.wikipedia.org/wiki/List_of_HTTP_status_codes
1313

1414
```plantuml
1515
@startuml

docs/content/en/docs/getting-started/_index.md

Lines changed: 11 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ date: 2024-03-18
99

1010
## Prerequisites
1111

12-
Before you begin, you might need to install the following tools (Linux Ubuntu 22.04 adapt for your needs):
12+
Before you begin, you might need to install the following tools (Linux Ubuntu 22.04 adapt for your needs):
1313

1414
- [golang](https://go.dev/doc/install)
1515
- go gin `go get -u github.com/gin-gonic/gin`
@@ -34,9 +34,6 @@ cd docker/soarca && sudo docker compose up -d
3434
{{< /tab >}}
3535
{{< /tabpane >}}
3636

37-
38-
39-
4037
{{% alert title="Tip" %}}
4138
Output will be similar to:
4239
{{< tabpane langEqualsHeader=false >}}
@@ -53,17 +50,18 @@ swag init
5350
{{< /tabpane >}}
5451
{{% /alert %}}
5552

56-
Compiled binary files can be found under `/bin`.
53+
Compiled binary files can be found under `/bin`.
5754

5855
### Playbook execution
5956

6057
You can use the following commands to execute the example playbooks via the terminal while SOARCA is running assuming on localhost. Alternatively you can go to `http://localhost:8080/swagger/index.html` and use the trigger/playbook endpoint.
6158

62-
6359
Example playbooks:
6460
{{< tabpane langEqualsHeader=false >}}
6561
{{< tab header="ssh" lang="sh" >}}
62+
6663
# make sure an ssh server is running on adres 192.168.0.10
64+
6765
curl -X POST -H "Content-Type: application/json" -d @./example/ssh-playbook.json localhost:8080/trigger/playbook
6866
{{< /tab >}}
6967
{{< tab header="http" lang="sh" >}}
@@ -74,14 +72,15 @@ curl -X POST -H "Content-Type: application/json" -d @./example/openc2-playbook.j
7472
{{< /tab >}}
7573
{{< /tabpane >}}
7674

77-
7875
## Configuration
7976

8077
SOARCA reads its configuration from the environment variables or a `.env` file. An example of a `.env` is given below:
8178

8279
{{< tabpane langEqualsHeader=false >}}
8380
{{< tab header="`.env`" lang="txt" >}}
8481
PORT: 8080
82+
SOARCA_ALLOWED_ORIGINS: "*"
83+
GIN_MODE: "release"
8584
MONGODB_URI: "mongodb://localhost:27017"
8685
DATABASE_NAME: "soarca"
8786
DB_USERNAME: "root"
@@ -98,11 +97,14 @@ LOG_FORMAT: "json"
9897
ENABLE_FINS: false
9998
MQTT_BROKER: "localhost"
10099
MQTT_PORT: 1883
101-
VALIDATION_SCHEMA_URL: ""
100+
101+
HTTP_SKIP_CERT_VALIDATION: false
102102
{{< /tab >}}
103103
{{< /tabpane >}}
104104

105-
### Docker hub
105+
106+
For more custom and advanced deployment instructions go [here](/docs/installation-configuration/_index.md).
107+
### Docker hub
106108

107109
`docker pull cossas/soarca`
108110

@@ -114,23 +116,3 @@ make build
114116
cp .env.example .env
115117
./build/soarca
116118
```
117-
118-
### Configuring SOARCA
119-
120-
|variable |content |description
121-
|---|---|---|
122-
|PORT |port |Set the exposed port of SOARCA the default is `8080`
123-
|DATABASE |true \| false | Set if you want to run with external database default is `false`
124-
|MONGODB_URI |uri |Set the Mongo DB uri default is `mongodb://localhost:27017`
125-
|DATABASE_NAME |name |Set the Mongo DB database name when using docker default is `soarca`
126-
|DB_USERNAME |user |Set the Mongo DB database user when using docker default is `root`
127-
|DB_PASSWORD |password |Set the Mongo DB database users password when using docker default is `rootpassword`. IT IS RECOMMENDED TO CHANGE THIS IN PRODUCTION!
128-
|MAX_REPORTERS |number |Set the maximum number of downstream reporters default is `5`
129-
|LOG_GLOBAL_LEVEL |[Log levels] |One of the specified log levels. Defaults to `info`
130-
|LOG_MODE |development \| production |If production is chosen the `LOG_GLOBAL_LEVEL` is used for all modules defaults to `production`
131-
|LOG_FILE_PATH |filepath |Path to the logfile you want to use for all logging. Defaults to `""` (empty string)
132-
|LOG_FORMAT |text \| json |The logging can be in plain text format or in JSON format. Defaults to `json`
133-
|MQTT_BROKER | dns name or ip | The broker address for SOARCA to connect to, for communication with fins default is `localhost`
134-
|MQTT_PORT | port | The broker address for SOARCA to connect to, for communication with fins default is `1883`
135-
|ENABLE_FINS| true \| false | Enable fins in SOARCA defaults to `false`
136-
|VALIDATION_SCHEMA_URL|url| Set a custom validation schema to be used to validate playbooks defaul is `""` to use internal. NOTE: changing this heavily impacts performance.
Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
2+
---
3+
4+
description: Everything you need to install and configure SOARCA
5+
title: Advanced Installation and Configuration
6+
categories: [documentation, configuration]
7+
tags: [extension, security]
8+
weight: 4
9+
---
10+
11+
After completing the [Getting Started](/docs/getting-started/_index.md) setup for SOARCA, you may find that certain advanced configurations or customizations are necessary to optimize SOARCA for your specific use cases, for example integrating with The Hive. This section provides in-depth guidance on additional steps you can take to enhance, secure, and integrate SOARCA with your infrastructure, ensuring it meets your unique operational needs.
12+
13+
### Configuring SOARCA
14+
15+
| Variable | Content | Description |
16+
|----------------------------|-----------------------------------|-----------------------------------------------------------------------------|
17+
| PORT | `8080` | Set the exposed port of SOARCA. Default is `8080`. |
18+
| ENABLE_TLS | `false` | Enable TLS for secure communication. Default is `false`. |
19+
| CERT_FILE | `"/certs/server.crt"` | Path to the TLS certificate file. Default is `"/certs/server.crt"`. |
20+
| CERT_KEY_FILE | `"/certs/server.key"` | Path to the TLS certificate key file. Default is `"/certs/server.key"`. |
21+
| MAX_EXECUTIONS | `1000` | The number of historical executions saved, including the current one. Default is `1000`. |
22+
| SOARCA_ALLOWED_ORIGINS | `*` | Set allowed origins for cross-origin requests. Default is `*`. |
23+
| GIN_MODE | `release` | Set the GIN mode. Default is `release`. |
24+
| DATABASE | `false` | Set if you want to run with an external database. Default is `false`. |
25+
| MONGODB_URI | `mongodb://localhost:27017` | Set the MongoDB URI. Default is `mongodb://localhost:27017`. |
26+
| DATABASE_NAME | `soarca` | Set the MongoDB database name when using Docker. Default is `soarca`. |
27+
| DB_USERNAME | `root` | Set the MongoDB database user when using Docker. Default is `root`. |
28+
| DB_PASSWORD | `rootpassword` | Set the MongoDB database user password when using Docker. **Change this in production!** Default is `rootpassword`. |
29+
| PLAYBOOK_API_LOG_LEVEL | `trace` | Set the log level for the playbook API. Default is `trace`. |
30+
| MAX_REPORTERS | `5` | Set the maximum number of downstream reporters. Default is `5`. |
31+
| LOG_GLOBAL_LEVEL | `info` | One of the specified log levels. Default is `info`. |
32+
| LOG_MODE | `development` | Set the logging mode. If `production`, `LOG_GLOBAL_LEVEL` is used for all modules. Default is `development`. |
33+
| LOG_FILE_PATH | `""` | Path to the logfile for all logging. Default is `""` (empty string). |
34+
| LOG_FORMAT | `json` | Set the logging format. Either `text` or `json`. Default is `json`. |
35+
| ENABLE_FINS | `false` | Enable FINS in SOARCA. Default is `false`. |
36+
| MQTT_BROKER | `localhost` | The broker address for SOARCA to connect to for communication with FINS. Default is `localhost`. |
37+
| MQTT_PORT | `1883` | The port for the MQTT broker. Default is `1883`. |
38+
| HTTP_SKIP_CERT_VALIDATION | `false` | Set whether to skip certificate validation for HTTP connections. Default is `false`. |
39+
| VALIDATION_SCHEMA_URL | `""` | Set a custom validation schema to validate playbooks. Default is `""` to use the internal schema. **Note:** Changing this can heavily impact performance. |
40+
41+
-----
42+
43+
### Integrations
44+
45+
#### The Hive
46+
47+
| Variable | Content | Description |
48+
|----------------------|-----------------------------------|---------------------------------------------------------|
49+
| THEHIVE_ACTIVATE | `false` | Enable integration with The Hive. Default is `false`. |
50+
| THEHIVE_API_TOKEN | `your_token` | Set the API token for The Hive integration. |
51+
| THEHIVE_API_BASE_URL | `http://your.thehive.instance/api/v1/` | Set the base URL for The Hive API. Default is `""`. |
52+
53+
-----
54+
55+
### Authentication
56+
57+
{{% alert title="Note" color="primary" %}}
58+
More information on setting up authentication can be found [here](/docs/installation-configuration/authentication.md).
59+
{{% /alert %}}
60+
| Variable | Content | Description |
61+
|------------------------|---------------------------------------------|---------------------------------------------------------------------------------------------|
62+
| AUTH_ENABLED | `false` | Enable authentication. Default is `false`. |
63+
| OIDC_ISSUER | `https://localhost:9443/application/u/test/` | The OIDC issuer URL. |
64+
| OIDC_CLIENT_ID | `SOME_CLIENT_ID` | Set the OIDC client ID. |
65+
| OIDC_CLIENT_SECRET | `SOME_CLIENT_SECRET` | Set the OIDC client secret. |
66+
| OIDC_REDIRECT_URL | `http://localhost:8081/auth/soarca_gui/callback` | Set the OIDC redirect URL. |
67+
| COOKIE_SECRET_KEY | `SOME_COOKIE_SECRET` | Optional: Secret key for cookies. Generate using `openssl rand -base64 32` or `head -c 32 /dev/urandom | base64`. |
68+
| OIDC_SKIP_TLS_VERIFY | `true` | Set whether to skip TLS verification. Default is `true`. |
69+
| AUTH_GROUP | `soarca_admin` | Specify the group users must belong to for authentication against SOARCA. |

0 commit comments

Comments
 (0)