AI › Module 7 › Lesson 4
Lab — Secure Dev
Secure AI dev lab on `$AI_LAB` — SDLC checklist, eval matrix, secrets audit bundled.
Visual · t32_secure_dev_lab
Lab: secure dev pack on YOUR $AI_LAB toy repo. Original Cyberlium.
Opening
Ship secure AI development artifacts from YOUR toy repo — SDLC, eval, secrets — zero jailbreak kits or prod key paste.
On YOUR `$AI_LAB` per brief: (1) scope proof — toy repo labeled YOUR account; (2) secure AI SDLC checklist Module 7-1; (3) eval test matrix Module 7-2; (4) secrets audit Module 7-3; (5) CI gate stub (eval before merge category); (6) integrity — `$AI_LAB` only, authorized eval YOUR apps, no jailbreak weaponization, no prod keys; (7) chmod 600 pack. Cross-link Module 6 app security — SDLC gates reference Top 10 and output rows.
1. Lab deliverables
SDLC + eval + secrets — single toy repo cross-index.
CI gate stub documents eval-before-merge literacy.
Command guide
Try these commands — Lab deliverables
═══ TOOLS & WEBSITES ═══ Browse / read these (authorized learning only — stay in YOUR lab / program scope)
OWASP LLM cheatsheet — https://cheatsheetseries.owasp.org/cheatsheets/LLM_Top_10_Cheat_Sheet.html NIST AI RMF — https://www.nist.gov/itl/ai-risk-management-framework OpenAI evals — https://platform.openai.com/docs/guides/evals
═══ INSTALL ═══
Linux (Debian/Ubuntu):
Command — copy this
sudo apt install python3
macOS:
Command — copy this
brew install python3
Windows: Download https://python.org/downloads/
═══ LINUX / macOS ═══
Command — copy this
export AI_LAB=${AI_LAB:-$HOME/cyberlium-lab/t32-ai}
cat > "$AI_LAB/eval/secure-dev-lab-summary.md" <<'EOF'
# Secure AI Dev Lab Summary — YOUR lab
- secure-sdlc-ai-checklist.md reviewed
- eval-checklist.md + poisoning-eval-checklist.md linked
- echo_bot.py refuses secret/injection probes
- system-prompt-stub.txt + allow-deny-list.txt drafted
## Refusals
- No stranger API scraping; no malware/deepfake/jailbreak weaponization
EOFCommand — copy this
grep -E 'echo_bot|Refusals|allow-deny' "$AI_LAB/eval/secure-dev-lab-summary.md" python3 "$AI_LAB/bot/echo_bot.py" test && grep DENY "$AI_LAB/bot/allow-deny-list.txt"
═══ WINDOWS ═══
Command — copy this
Get-Content $HOME/cyberlium-lab/t32-ai/eval/eval-checklist.md | Select-String injection
Primary tools to practice this lesson: grep, python3. Reference sites: OWASP LLM cheatsheet (https://cheatsheetseries.owasp.org/cheatsheets/LLM_Top_10_Cheat_Sheet.html); NIST AI RMF (https://www.nist.gov/itl/ai-risk-management-framework); OpenAI evals (https://platform.openai.com/docs/guides/evals). Run every command in the box — install first, then the usage lines — only on YOUR lab / program scope.
2. Quality bar
Eval scope states YOUR app only — no stranger targets.
Zero prod keys or jailbreak kits in any file.
3. Teardown
Rotate lab keys stub; secure notes chmod 600.
No repo pushed public with accidental secrets.
4. What you ship: secure dev lab pack
SDLC + eval + secrets + CI stub + integrity — chmod 600.
5. What you record before the next lesson
Secure dev lab pack path.
6. Wrong vs right: stranger SaaS vs YOUR toy LLM
Worked failure — same MSF word, opposite target. Right never needs a café Wi-Fi or classmate laptop.
Wrong
Secure dev lab includes jailbreak weaponization repo as eval artifact.
Right
Secure dev lab pack on `$AI_LAB` toy repo. Next: quiz.
Mission: secure dev lab
1) Scope and repo proof. 2) SDLC checklist and eval matrix. 3) Secrets audit three rows. 4) Integrity block; chmod 600.
Stuck? Ask Cyberlium AI Mentor
Ask Mentor: “CI eval gate — minimum stub?”
Knowledge Check
APPLY: Secure dev lab scope:
Multiple choice
Knowledge Check
APPLY: True or False: AI red team means stranger app jailbreak kits.
True or False
Knowledge Check
APPLY: Secure dev pack includes:
Multiple choice