From 0de823d0c746396b7678ef741f237a0b1cf57eeb Mon Sep 17 00:00:00 2001 From: hotsauce-v2 Date: Wed, 25 Nov 2020 00:30:06 -0500 Subject: [PATCH 1/7] Update Install_rpm.md --- TheHive4/Installation/Install_rpm.md | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/TheHive4/Installation/Install_rpm.md b/TheHive4/Installation/Install_rpm.md index ec1ea83..b6e579c 100644 --- a/TheHive4/Installation/Install_rpm.md +++ b/TheHive4/Installation/Install_rpm.md @@ -2,7 +2,7 @@ This page is a step by step installation and configuration guide to get an TheHive 4 instance up and running on systems using DEB packages repositories. -## Table of content +## Table of contents - [Java Virtual Machine](#java-virtual-machine) - [Cassandra database](#cassandra-database) @@ -63,7 +63,14 @@ yum install -y cassandra By default, data is stored in `/var/lib/cassandra`. +- Start the service + +```bash +service cassandra start +``` + ### Configuration +⚠️ **Note** Python3 is not supported in Cassandra v 3.11 (v 2.7 required for cqlsh) Start by changing the `cluster_name` with `thp`. Run the command `cqlsh`: From 8b948e5e9dd473decc6af0958cecb0135c1e6733 Mon Sep 17 00:00:00 2001 From: hotsauce-v2 Date: Wed, 25 Nov 2020 00:37:18 -0500 Subject: [PATCH 2/7] Update Install_rpm.md --- TheHive4/Installation/Install_rpm.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/TheHive4/Installation/Install_rpm.md b/TheHive4/Installation/Install_rpm.md index b6e579c..8eac33e 100644 --- a/TheHive4/Installation/Install_rpm.md +++ b/TheHive4/Installation/Install_rpm.md @@ -1,6 +1,6 @@ # Installation Guide on RedHat-like OS -This page is a step by step installation and configuration guide to get an TheHive 4 instance up and running on systems using DEB packages repositories. +This page is a step by step installation and configuration guide to get an TheHive 4 instance up and running on systems using RPM packages repositories. ## Table of contents From ed6ee13e1791a2062a11a745d19c215b14c472bf Mon Sep 17 00:00:00 2001 From: hotsauce-v2 Date: Wed, 25 Nov 2020 01:11:27 -0500 Subject: [PATCH 3/7] Update Install_rpm.md --- TheHive4/Installation/Install_rpm.md | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/TheHive4/Installation/Install_rpm.md b/TheHive4/Installation/Install_rpm.md index 8eac33e..93115df 100644 --- a/TheHive4/Installation/Install_rpm.md +++ b/TheHive4/Installation/Install_rpm.md @@ -84,7 +84,12 @@ Then run: nodetool flush ``` -Configure Cassandra by editing `/etc/cassandra/conf/cassandra.yaml` file. +Configure Cassandra by backing up and then editing `/etc/cassandra/conf/cassandra.yaml` file. + +```bash +cd /etc/cassandra +cp cassandra.yaml cassandra.yaml.backup +``` ```yml # content from /etc/cassandra/conf/cassandra.yaml From b435b8d84b80a936a07049b8fd3a92b3da251e2a Mon Sep 17 00:00:00 2001 From: hotsauce-v2 Date: Wed, 25 Nov 2020 01:19:25 -0500 Subject: [PATCH 4/7] Update Install_rpm.md --- TheHive4/Installation/Install_rpm.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/TheHive4/Installation/Install_rpm.md b/TheHive4/Installation/Install_rpm.md index 93115df..dee03ee 100644 --- a/TheHive4/Installation/Install_rpm.md +++ b/TheHive4/Installation/Install_rpm.md @@ -87,7 +87,7 @@ nodetool flush Configure Cassandra by backing up and then editing `/etc/cassandra/conf/cassandra.yaml` file. ```bash -cd /etc/cassandra +cd /etc/cassandra/conf cp cassandra.yaml cassandra.yaml.backup ``` From cf6c414536f2ee7eb45ce4f99ec185e6ba6e69cc Mon Sep 17 00:00:00 2001 From: hotsauce-v2 Date: Wed, 25 Nov 2020 01:52:25 -0500 Subject: [PATCH 5/7] Update Cassandra_security.md --- TheHive4/Administration/Cassandra_security.md | 35 ++++++++++++++++++- 1 file changed, 34 insertions(+), 1 deletion(-) diff --git a/TheHive4/Administration/Cassandra_security.md b/TheHive4/Administration/Cassandra_security.md index d9459ba..0721900 100644 --- a/TheHive4/Administration/Cassandra_security.md +++ b/TheHive4/Administration/Cassandra_security.md @@ -5,7 +5,40 @@ ## Authentication with Cassandra -### Cassandra Configurration + +### Cassandra Configuration + +Enable Password Authentication in /etc/cassandra/conf/cassandra.yaml (by default, authentication is set to allow all) + +```yml +authenticator: PasswordAuthenticator +``` + +Create new Super User + +```bash +cqlsh -u cassandra -p cassandra +``` + +```sql +CREATE ROLE root_user_name with SUPERUSER = true AND LOGIN = true and PASSWORD = 'password'; +``` + +```bash +EXIT; +``` + +Authenticate with new Super User Role and Drop Default cassandra role + +```sql +LIST ROLES; + +DROP ROLE cassandra; + +LIST ROLES; +``` + +Creation of TheHive ```sql CREATE ROLE thehive WITH PASSWORD = 'thehive1234' AND LOGIN = true; From 415b9c061d9dced338b2f8ad5464152e9ae62ca7 Mon Sep 17 00:00:00 2001 From: hotsauce-v2 Date: Wed, 25 Nov 2020 02:21:37 -0500 Subject: [PATCH 6/7] Update Cassandra_security.md --- TheHive4/Administration/Cassandra_security.md | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/TheHive4/Administration/Cassandra_security.md b/TheHive4/Administration/Cassandra_security.md index 0721900..2b98ed0 100644 --- a/TheHive4/Administration/Cassandra_security.md +++ b/TheHive4/Administration/Cassandra_security.md @@ -22,9 +22,6 @@ cqlsh -u cassandra -p cassandra ```sql CREATE ROLE root_user_name with SUPERUSER = true AND LOGIN = true and PASSWORD = 'password'; -``` - -```bash EXIT; ``` @@ -32,13 +29,11 @@ Authenticate with new Super User Role and Drop Default cassandra role ```sql LIST ROLES; - DROP ROLE cassandra; - LIST ROLES; ``` -Creation of TheHive +Creation of TheHive Role ```sql CREATE ROLE thehive WITH PASSWORD = 'thehive1234' AND LOGIN = true; From 8a1180793dd03270459a300489cfb10d5e1efe43 Mon Sep 17 00:00:00 2001 From: hotsauce-v2 Date: Wed, 25 Nov 2020 02:23:11 -0500 Subject: [PATCH 7/7] Update Install_rpm.md --- TheHive4/Installation/Install_rpm.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/TheHive4/Installation/Install_rpm.md b/TheHive4/Installation/Install_rpm.md index dee03ee..747d16a 100644 --- a/TheHive4/Installation/Install_rpm.md +++ b/TheHive4/Installation/Install_rpm.md @@ -44,7 +44,7 @@ Apache Cassandra is a scalable and high available database. TheHive supports ver ### Install from repository -- Add the Apache repository of Cassandra to `/etc/yum.repos.d/cassandra.repo` +- Add the Apache repository of Cassandra by creating and editing `/etc/yum.repos.d/cassandra.repo` ```bash [cassandra]