Cyberlium
Cyberlium
Cyberlium on Android·Google Play Store

Learn cybersecurity with hands-on labs and AI mentor support on your phone.

Mod 7 · Les 1/5
In progress
Module 7•Lesson 1 of 5•⏱️ 15 min read•Beginner+39 XP

SAST Named

Static analysis finds patterns in source — run on YOUR $REPO, never stranger codebases without scope.

SAST Named
00:00/02:41

Visual · t17_sast_named

SAST = analyze source without running the app. Original Cyberlium.

SAST reads your mistakes before attackers do — but only on repos you are allowed to scan.

Static Application Security Testing tools (Semgrep, CodeQL, Bandit, ESLint security plugins) pattern-match source for injection, hardcoded secrets, weak crypto, and dangerous APIs. SAST runs in IDE or CI on commits you own. Learn tool categories and false-positive culture on $REPO — never point scanners at employer monoliths, open-source projects for 'practice,' or classmate private repos without permission. Defenders gate merges on SAST; attackers hope you skip it.

1. What SAST sees

Source paths, AST patterns, taint flows (in advanced tools), config files in repo.

Cannot fully verify runtime config — complements DAST and review.

Command guide

Try these commands — What SAST sees

═══ LINUX / BASH (Network & Reconnaissance Audit) ═══

Scan target host for open ports and service version signatures

Command — copy this

nmap -sS -sV -p 80,443,8080 -Pn ${LAB_HOST:-127.0.0.1}

DNS and WHOIS reconnaissance on authorized domain

Command — copy this

dig +short A target.local
dig +short MX target.local
whois target.local 2>/dev/null | grep -iE "(Registrar|Creation Date|Name Server)" | head -6

Inspect HTTP headers for technology stack fingerprinting

Command — copy this

curl -s -I "http://${LAB_HOST:-127.0.0.1}:8080" | grep -iE "(Server|X-Powered-By|Set-Cookie|Content-Security-Policy)"

Primary tools to practice this lesson: grep, python3. Reference sites: SAST (https://cheatsheetseries.owasp.org/cheatsheets/Source_Code_Analysis_Tools_Cheat_Sheet.html); Bandit (https://bandit.readthedocs.io/). Run every command in the box — install first, then the usage lines — only on YOUR lab / program scope.

2. Tool families

Language-specific (Bandit for Python, gosec for Go) vs multi-language (Semgrep).

IDE plugins for fast feedback; CI for team gate.

3. Scope

Default lab: clone and scan YOUR $REPO or course starter you forked.

No bulk scanning GitHub orgs you do not own — rate limits and ethics apply.

4. What you ship: SAST vocabulary

SAST definition + two tool names + $REPO-only scan rule.

5. What you record before the next lesson

SAST named paragraph.

6. Wrong vs right: stranger apps vs YOUR repo

Worked failure — same MSF word, opposite target. Right never needs a café Wi-Fi or classmate laptop.

  • Wrong: Run Semgrep against employer private repo without authorization.
  • Right: Name SAST and tools. Next: findings triage.
Hands-on Exercise

Mission: SAST literacy sheet

1) Define SAST in one sentence. 2) Name two tools for your stack. 3) Write NEVER scan stranger repos.

Pro Tip

Stuck? Ask Cyberlium AI Mentor

Ask Mentor: “Semgrep vs CodeQL tradeoff?”

Practice QuizQuestion 1
Multiple choice
Q1

APPLY: SAST analyzes:

Practice QuizQuestion 2
True or False
Q2

APPLY: True or False: Scanning classmate private repo without OK is lab.

Practice QuizQuestion 3
Multiple choice
Q3

APPLY: SAST runs best early:

Answer 3 practice quiz questions to unlock XP reward. (0/3 answered)
Skip quiz & read next →