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: guides/k8s/k8s.md
+2Lines changed: 2 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,8 @@
1
1
# Example Setup with kubernetes(k8s)
2
2
3
3
**WARNING:** It takes into account that you already have k8s cluster setup.
4
+
**WARNING-2:** this document is not yet up to date, it will be fixed in [https://github.com/commjoen/wrongsecrets-ctf-party/issues/79](https://github.com/commjoen/wrongsecrets-ctf-party/issues/79).
Copy file name to clipboardExpand all lines: guides/production-notes/production-notes.md
+7-1Lines changed: 7 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -4,10 +4,12 @@ To ensure MultiJuicer runs as smoothly during your CTF's / trainings / workshops
4
4
5
5
1. Set `.balancer.cookie.cookieParserSecret` to a random alpha-numeric value (recommended length 24 chars), this value is used to sign cookies. If you don't set this, each `helm upgrade` you run will generate a new one, which invalidates all user sessions, forcing users to rejoin their team.
6
6
2. As you are running this with https (right?), you should set `balancer.cookie.secure` to `true`. This marks the cookie used to associate a browser with a team to transmitted via https only.
7
-
3. Make sure the value you have configured for `juiceShop.maxInstances` fits your CTF / training / whatever you are running. The default is set to only allow 10 instances. Set to -1 to remove any restrictions.
7
+
3. Make sure the value you have configured for `wrongsecrets.maxInstances` & `virtualdesktop.maxInstances` fits your CTF / training / whatever you are running. The default is set to only allow 10 instances. Set to -1 to remove any restrictions.
8
8
4. Set `balancer.replicas` to at least 2, so that you have at least one fall back JuiceBalancer when one crashes or the node it lives on goes down.
9
9
5. When running a CTF with JuiceShop challenge flags, make sure to change `juiceShop.ctfKey` from the default. Otherwise users will be able to generate their own flags relatively easily. See
10
10
6. When using prometheus metrics, e.g. when you have followed the [Monitoring SetUp Guide](https://github.com/iteratec/multi-juicer/blob/main/guides/monitoring-setup/monitoring.md) you'll want to change `balancer.metrics.basicAuth.password` to a non default values. Otherwise users can use the default value to access the technical metrics of the JuiceBalancer pods.
11
+
7. If you host this CTF in a public domain, change the `balancer.env.REACT_APP_ACCESS_PASSWORD` to a password you communicate to your users at the start of teh CTF.
12
+
8. Make sure to rotate the `balancer.env.REACT_APP_CREATE_TEAM_HMAC_KEY` HMAC key for anti-infra-creation-fuzzing as well into something else than 'hardcodedkey' when you see players generating 100s of instances in minutes.
Copy file name to clipboardExpand all lines: helm/wrongsecrets-ctf-party/values.yaml
+10-9Lines changed: 10 additions & 9 deletions
Original file line number
Diff line number
Diff line change
@@ -63,15 +63,16 @@ balancer:
63
63
# -- If set to true this skips setting ownerReferences on the teams JuiceShop Deployment and Services. This lets MultiJuicer run in older kubernetes cluster which don't support the reference type or the app/v1 deployment type
REACT_APP_MOVING_GIF_LOGO : 'https://i.gifer.com/9kGQ.gif'#displayed at the frontend when you enter the CTF
67
+
REACT_APP_HEROKU_WRONGSECRETS_URL : 'https://wrongsecrets-ctf.herokuapp.com'#required for 3 domain setup
68
+
REACT_APP_CTFD_URL : 'https://ctfd.io'#requierd for 2 and 3 domain setup
69
+
REACT_APP_S3_BUCKET_URL : 's3://funstuff'#the s3 bucket you use for teh aws challenges, don't forget to make it accessible!
70
+
K8S_ENV: 'k8s'#or 'aws'
71
71
REACT_APP_ACCESS_PASSWORD: ''#DEFAULT NO PASSWORD, PLAYING THIS IN PUBLIC? PUT A FANCY STRING HERE, BUT BE GENTLE: USERS NEED TO BE ABLE TO COPY THAT STUFF...
See [production notes](./guides/production-notes/production-notes.md) for a checklist of values you'll likely need to configure before using MultiJuicer in proper events.
108
-
109
-
### Installation Guides for specific Cloud Providers / Environments
110
-
111
-
Generally MultiJuicer runs on pretty much any kubernetes cluster, but to make it easier for anybody who is new to kubernetes we got some guides on how to setup a kubernetes cluster with MultiJuicer installed for some specific Cloud providers.
See [production notes](./guides/production-notes/production-notes.md) for a checklist of values you'll likely need to configure before using Wrongsecrets-ctf-party in proper events.
118
95
119
96
### Customizing the Setup
120
97
121
-
You got some options on how to setup the stack, with some option to customize the JuiceShop instances to your own liking.
122
-
You can find the default config values under: [helm/multi-juicer/values.yaml](helm/wrongsecrets-ctf-party/values.yaml)
98
+
You got some options on how to setup the stack, with some option to customize the WrongSecrets and Virtual desktop instances to your own liking.
99
+
You can find the default config values under: [helm/wrongsecrets-ctf-party/values.yaml](helm/wrongsecrets-ctf-party/values.yaml)
123
100
124
101
Download & Save the file and tell helm to use your config file over the default by running:
### How much compute resources will the cluster require?
139
-
140
-
To be on the safe side calculate with:
141
-
142
-
-_1GB memory & 1CPU overhead_, for the balancer & co
143
-
-_200MB & 0.2CPU \* number of participants_, for the individual JuiceShop Instances
144
-
145
-
The numbers above reflect the default resource limits. These can be tweaked, see: [Customizing the Setup](#customizing-the-setup)
146
-
147
-
### How many users can MultiJuicer handle?
148
-
149
-
There is no real fixed limit. (Even thought you can configure one 😉)
150
-
The custom LoadBalancer, through which all traffic for the individual Instances flows, can be replicated as much as you'd like.
151
-
You can also attach a [Horizontal Pod Autoscaler](https://kubernetes.io/docs/tasks/run-application/horizontal-pod-autoscale/) to automatically scale the LoadBalancer.
152
-
153
115
### Why a custom LoadBalancer?
154
116
155
117
There are some special requirements which we didn't find to be easily solved with any pre build load balancer:
@@ -168,19 +130,22 @@ There are some pretty good reasons for this:
168
130
- To ensure that pods are still properly associated with teams after a pod gets recreated. This is a non problem with separate deployment and really hard with scaled deployments.
169
131
- The ability to embed the team name in the deployment name. This seems like a stupid reason but make debugging SOOO much easier, with just using `kubectl`.
170
132
171
-
### How to manage JuiceShop easily using `kubectl`?
133
+
### How to manage WrongSecrets easily using `kubectl`?
172
134
173
-
You can list all JuiceShops with relevant information using the custom-columns feature of kubectl.
174
-
You'll need to down load the juiceShop.txt from the repository first:
135
+
You can list all WrongSecrets with relevant information using the custom-columns feature of kubectl.
136
+
You'll need to down load the wrongsecrets.txt from the repository first:
175
137
176
138
```bash
177
-
kubectl get -l app=wrongsecrets -o custom-columns-file=juiceShop.txt deployments
139
+
kubectl get -l app=wrongsecrets -o custom-columns-file=wrongsecrets.txt deployments
178
140
```
179
141
142
+
There are a few more ways how you can check whether all is going well: have a look in the [/scripts](/scripts/) folder for various tools that can help you to see if there are too many namespaces created for instance. This does require you to export the teams and players from ctfd.
143
+
144
+
180
145
### Did somebody actually ask any of these questions?
181
146
182
147
No 😉
183
148
184
149
## Talk with Us!
185
150
186
-
You can reach us in the `#project-juiceshop` channel of the OWASP Slack Workspace. We'd love to hear any feedback or usage reports you got. If you are not already in the OWASP Slack Workspace, you can join via [this link](https://owasp.slack.com/join/shared_invite/enQtNjExMTc3MTg0MzU4LWQ2Nzg3NGJiZGQ2MjRmNzkzN2Q4YzU1MWYyZTdjYjA2ZTA5M2RkNzE2ZjdkNzI5ZThhOWY5MjljYWZmYmY4ZjM)
151
+
You can reach us in the `#project-wrongsecrets` channel of the OWASP Slack Workspace. We'd love to hear any feedback or usage reports you got. If you are not already in the OWASP Slack Workspace, you can join via [this link](https://owasp.slack.com/join/shared_invite/enQtNjExMTc3MTg0MzU4LWQ2Nzg3NGJiZGQ2MjRmNzkzN2Q4YzU1MWYyZTdjYjA2ZTA5M2RkNzE2ZjdkNzI5ZThhOWY5MjljYWZmYmY4ZjM)
0 commit comments