Skip to content

Commit

Permalink
Merge pull request #107 from VedRatan/issue_94
Browse files Browse the repository at this point in the history
added examples for params in the context of escape-to-host
  • Loading branch information
shivaccuknox authored May 19, 2024
2 parents 5bd2740 + 1e4712d commit b4db009
Show file tree
Hide file tree
Showing 2 changed files with 62 additions and 0 deletions.
34 changes: 34 additions & 0 deletions examples/clusterscoped/escape-to-host-si-sib-with-params.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
apiVersion: intent.security.nimbus.com/v1
kind: SecurityIntent
metadata:
name: escape-to-host
spec:
intent:
id: escapeToHost
description: "A attacker can breach container boundaries and can gain access to the host machine"
action: Block
params:
psa_level: ["restricted"]
---
apiVersion: intent.security.nimbus.com/v1
kind: ClusterSecurityIntentBinding
metadata:
name: escape-to-host-binding
spec:
intents:
- name: escape-to-host
selector:
resources:
- kind: Pod
name: pod1
namespace: ns1
matchLabels:
app: db
env: dev

- kind: Pod
name: pod1
namespace: ns2
matchLabels:
app: mongo
env: prod
28 changes: 28 additions & 0 deletions examples/namespaced/escape-to-host-with-params.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
apiVersion: intent.security.nimbus.com/v1
kind: SecurityIntent
metadata:
name: escape-to-host
spec:
intent:
id: escapeToHost
description: "A attacker can breach container boundaries and can gain access to the host machine"
action: Block
params:
psa_level: ["restricted"]

---

apiVersion: intent.security.nimbus.com/v1
kind: SecurityIntentBinding
metadata:
name: escape-to-host-binding
spec:
intents:
- name: escape-to-host
selector:
any:
- resources:
kind: Pod
namespace: default
matchLabels:
app: nginx

0 comments on commit b4db009

Please sign in to comment.