How pdfm06/ssa-aula10 works
This repository is a local DevSecOps classroom lab: users can explore a synthetic-data FastAPI app, while learners progressively build and run a Jenkins security pipeline. The app serves a home page, health check, and owner-filtered works; the works route delegates to an intentionally unsafe SQL lookup. The README describes the intended pipeline stages, but says the checked-in pipeline initially only checks out code and verifies Docker. Scanner-stage links therefore describe documented additions, not verified current Jenkins wiring.
Main entry points: Jenkinsfile Pipeline definition · main.py FastAPI app · security.py Works lookup · compose.yaml Jenkins service
Components 17
Classroom app
- FastAPI app
app/main.py - Home and health
app/main.py - Works route
app/main.py
Works lookup
- Works lookup
app/security.py - In-memory SQLite
app/security.py
Lab pipeline
- Jenkins service
compose.yaml - Pipeline definition
Jenkinsfile - App image build
Dockerfile - App startup
app/main.py
Security checks
- Dependency SCA
requirements.txt - Bandit SAST
ci/Dockerfile.bandit - Image scan
Jenkinsfile - ZAP Baseline
ci/zap-rules.tsv - Report evaluation
ci/evaluate.py
Other components
- Learner
- App visitor
- Forked repository
Connections 15
- App visitor → FastAPI app: opens app
README.md - FastAPI app → Home and health: serves routes
app/main.py - FastAPI app → Works route: serves routes
app/main.py - Works route → Works lookup: calls lookup
app/main.py - Works lookup → In-memory SQLite: queries
app/security.py - Learner → Forked repository: commits changes
README.md - Forked repository → Jenkins service: checks out SCM
README.md - Jenkins service → Pipeline definition: runs pipeline
README.md - Pipeline definition → Dependency SCA: add SCA stage
README.md - Pipeline definition → Bandit SAST: add SAST stage
README.md - Pipeline definition → App image build: add image build
README.md - Pipeline definition → Image scan: add image scan
README.md - Pipeline definition → App startup: add app startup
README.md - Pipeline definition → ZAP Baseline: add baseline scan
README.md - Pipeline definition → Report evaluation: evaluate reports