You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+16-18Lines changed: 16 additions & 18 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -100,16 +100,7 @@ so that the barrier for entry here is low.
100
100
101
101
# Crowdsec
102
102
1. Install crowdsec using this compose file: https://github.com/ZoeyVid/NPMplus/blob/develop/compose.crowdsec.yaml
103
-
2. open `/opt/crowdsec/conf/acquis.d/appsec.yaml` and fill it with:
104
-
```yaml
105
-
listen_addr: 0.0.0.0:7422
106
-
appsec_config: crowdsecurity/virtual-patching
107
-
name: myAppSecComponent
108
-
source: appsec
109
-
labels:
110
-
type: appsec
111
-
```
112
-
3. open `/opt/crowdsec/conf/acquis.d/npmplus.yaml` and fill it with:
103
+
2. open `/opt/crowdsec/conf/acquis.d/npmplus.yaml` and fill it with:
113
104
```yaml
114
105
filenames:
115
106
- /opt/npm/nginx/access.log
@@ -127,15 +118,22 @@ container_name:
127
118
- npmplus
128
119
labels:
129
120
type: modsecurity
121
+
---
122
+
listen_addr: 0.0.0.0:7422
123
+
appsec_config: crowdsecurity/virtual-patching
124
+
name: appsec
125
+
source: appsec
126
+
labels:
127
+
type: appsec
130
128
```
131
-
4. make sure to use `network_mode: host` in your compose file
132
-
5. run `docker exec crowdsec cscli bouncers add npmplus -o raw` and save the output
133
-
6. open `/opt/npm/etc/crowdsec/crowdsec.conf`
134
-
7. set `ENABLED` to `true`
135
-
8. use the output of step 5 as `API_KEY`
136
-
9. save the file
137
-
10. set LOGROTATE to `true` in your `compose.yaml`
138
-
11. redeploy the `compose.yaml`
129
+
3. make sure to use `network_mode: host` in your compose file
130
+
4. run `docker exec crowdsec cscli bouncers add npmplus -o raw` and save the output
131
+
5. open `/opt/npm/etc/crowdsec/crowdsec.conf`
132
+
6. set `ENABLED` to `true`
133
+
7. use the output of step 5 as `API_KEY`
134
+
8. save the file
135
+
9. set LOGROTATE to `true` in your `compose.yaml`
136
+
10. redeploy the `compose.yaml`
139
137
140
138
# coreruleset plugins
141
139
1. Download the plugin (all files inside the `plugins` folder of the git repo), most time: `<plugin-name>-before.conf`, `<plugin-name>-config.conf` and `<plugin-name>-after.conf` and sometimes `<plugin-name>.data` and/or `<plugin-name>.lua` or somilar files
0 commit comments