Repository navigation
Feature/lab7 - #1814
Closed
sedimentt wants to merge 13 commits into
Closed
Feature/lab7#1814sedimentt wants to merge 13 commits into
sedimentt wants to merge 13 commits into
Conversation
feat(lab1): juice shop deploy + PR template + triage report
feat(lab2): threat model, secure variant, auth flow
test: first signed commit
feat(lab4): juice shop SBOM + grype and trivy comparison
feat(lab5): zap baseline and authenticated, semgrep, correlation
feat(lab6): checkov and kics findings, custom policy
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Goal
Scan the Juice Shop image and a sample Dockerfile with Trivy, run Juice Shop in k3d under the
restrictedPod Security Standard, and make it run with a read-only root filesystem.Changes
labs/lab7/k8s/namespace.yaml—juice-shopnamespace withenforce/warn/labs/lab7/k8s/serviceaccount.yaml— dedicated ServiceAccount`automountServiceAcclabs/lab7/k8s/deployment.yaml— image pinned by digest, runsUID 65532, seccomp ``, requests/limits,readOnlyRootFilesystem: true, emptyDir volumes plus a `seed` initContainerlabs/lab7/k8s/service.yaml— ClusterIP service on port 3000 -labs/lab7/k8s/netny for Ingress andEgress; ingress only from Traefik on TCP 3000, egress only DNS tkube-dns ## Testing -trivy image bkimmverity HIGH,CRITICAL→ 11 CRITICAL / 74 HIGH; 77 of 85 have a fix -trivy configon lures:DS-0002(HIGH),DS-0001,DS-0004,DS-0026-kubectl -n juice-dy pod -lapp=juice-shop→1/1 Running, 0 restarts - The process runs aCapEff: 0,NoNewPrivs: 1,Seccomp: 2, and no ServiceAccount token mount-kubectl run --dryod spec → rejected:violates PodSecurity "restricted:latest"- NetworkPolicy: reqspace to the app areblocked; egress from the app pod to1.1.1.1:443is refused; in-cluster DNS workstrivy k8sHIGH misconfigurations:juice-plain3 →juice-s(all severities: 16 e the same becausethe image is the same - Bonus: underreadites to the root FSfail withEROFSand writes to the volumes succeed. Throughport-forward,/,leand/ftp/legal.md` all return HTTP 200Artifacts & Screenshots
submissions/lab7.md- Manifests: `labs/ltrivy-image.json,trivy-k8s.json,pod-spec.are inlabs/lab7/rey for Lab 10 and are not committed, per.gitignoreChecklist
feat(lab7): trivy scans + PSS restricted deployment)