SITF technique T-C004: Workflow Script Injection
Component: CI/CDStage: Initial AccessID: T-C004
Attacker injects malicious code into workflow through user-controlled input.
SITF technique T-C004 (Workflow Script Injection) is a Initial Access technique in the SDLC Infrastructure Threat Framework (SITF). It targets the CI/CD component (Continuous Integration/Deployment systems).
Risks that enable this technique
- Misconfigured repo - visibility
- Misconfigured workflow - script injection
- Default workflow permissions set to WRITE
- Default workflow permissions set to approve PR
- Workflow with excessive permissions
- Workflow with access to secrets
Protective controls
- Branch protection rules (VCS)
OWASP SPVS: V1.5 Source Code Management Hardening - Private repo (VCS)
OWASP SPVS: V1.5 Source Code Management Hardening - Minimal workflow permissions
OWASP SPVS: V3.1 Security of Pipeline Environment; V5.1 Access Audit - Code review for workflows
OWASP SPVS: V2.3 Code Review and Analysis
Detective controls
- CICD scanning tools
OWASP SPVS: V5.4 Detection & Monitoring
Observed in
- s1ngularity (incident)
- Ultralytics (incident)
Explore
- Open T-C004 in the interactive technique library
- Map an attack using T-C004 in the SITF flow builder
- Previous CI/CD technique: T-C003 PWN Request / Poisoned Pipeline Execution
- Next CI/CD technique: T-C005 Secret Exfiltration from Workflow
How to reference
Cite as SITF technique T-C004 (Workflow Script Injection), SDLC Infrastructure Threat Framework (SITF), https://wiz-sec-public.github.io/SITF/techniques/T-C004.html.