InterviewHubPRO
Section Overview
Q41

Question 41 of 50

Part 4: CI/CD Pipelines, GitOps & Progressive Delivery (36 - 42)

82%
DevOps & Kubernetes (50 Qs)•Part 4: CI/CD Pipelines, GitOps & Progressive Delivery (36 - 42)

Software Supply Chain Security & SLSA Framework: SBOM generation, container scanning (Trivy), and SAST.

Securing the Software Supply Chain

Modern attackers frequently target developer tooling and third-party dependencies rather than attacking production firewalls directly. The SLSA (Supply-chain Levels for Software Artifacts) framework provides end-to-end security verification.

scss
[ Source Code ] ---> [ Dependencies ] ---> [ Build Runner ] ---> [ Artifact / Image ] ---> [ Deploy ]
      |                     |                     |                      |                     |
  Git Signing         SBOM (Syft)          Ephemeral Runner        Cosign Signature       Admission Webhook
  & Branch Rules      Trivy Scanner        Isolated Network        Attestation Checks     (Kyverno blocks)

Core Security Layers in CI/CD

  1. SAST (Static Application Security Testing): Scans source code for hardcoded secrets, SQL injection, and buffer overflows using tools like Semgrep or SonarQube.
  2. SCA (Software Composition Analysis): Checks open-source packages in package.json or requirements.txt against known CVE vulnerability databases (Dependabot, Snyk).
  3. SBOM (Software Bill of Materials): A machine-readable inventory of all components, libraries, and licenses embedded in your software. Generated using Syft:
bash
# Generate CycloneDX SBOM
syft registry.example.com/api:v1.0.0 -o cyclonedx-json > sbom.json
  1. Container Image Scanning: Scans OS packages and application dependencies for critical CVEs using Trivy:
bash
# Fail CI build if any CRITICAL vulnerability exists
trivy image --exit-code 1 --severity CRITICAL registry.example.com/api:v1.0.0