Security Scanning

4-layer automated security scanning protects the Renewa One codebase and container images.

Scanning Layers

ToolPurposeBlocking LevelScope
TrivyContainer/filesystem vulnerabilitiesMEDIUM+Images, filesystem
npm/bun auditDependency CVEsMEDIUM+ (with ignore list)package.json deps
SemgrepStatic application security testingCRITICAL/HIGHSource code
GitleaksSecret detectionAll findingsGit history + staged

Workflow Configuration

WorkflowTriggerPurpose
.github/workflows/security-scan.ymlDaily 2 AM UTC + PRAll 4 scanning layers
.github/workflows/container-security-scan.ymlOn image buildTrivy container-specific scan

Scans run as part of CI-CD Workflows and report to the GitHub Security Tab under Code Scanning.

False Positive Management

ToolConfig FilePurpose
Semgrep.semgrepignoreExclude paths/rules
Trivyrenewa-one/.trivyignoreIgnore specific CVEs
Gitleaks.gitleaks.tomlExclude known safe patterns

CVE ignore example — when a vulnerability has no available fix:

# renewa-one/.trivyignore
CVE-2026-32280  # Atlas Go stdlib x509 DoS - no upstream fix

Results

  • GitHub Security Tab Code scanning alerts
  • PR comments with scan summaries
  • Blocking: PRs cannot merge with unresolved MEDIUM+ findings (Trivy/audit) or CRITICAL/HIGH (Semgrep)

Key Principles

  • All 4 layers must pass for ci-gate to go green
  • Scheduled daily scans catch newly disclosed CVEs
  • Coding Guidelines enforce secure coding patterns (XSS protection, input sanitization)
  • Secret management via GitHub Environment Secrets only (see Deployment Pipeline)

Key Files

  • .github/workflows/security-scan.yml
  • .github/workflows/container-security-scan.yml
  • renewa-one/.trivyignore
  • .semgrepignore
  • .gitleaks.toml

See Also