How It Works
When CybeDefend scans your codebase, it automatically detects Dockerfile files and performs comprehensive security analysis alongside your source code scanning. This integrated approach ensures both your application code and container configurations are secure.Automatic Detection
CybeDefend automatically identifies and scans:Dockerfile
files in your repository- Multi-stage build configurations
- Docker Compose files with build contexts
- Custom Dockerfile variants (e.g.,
Dockerfile.prod
,Dockerfile.dev
)
Security Analysis
The scanner examines multiple aspects of your Dockerfile:-
Base Image Security
- Identifies vulnerable base images
- Recommends secure alternatives
- Checks for outdated image versions
-
Configuration Issues
- Detects insecure configurations
- Identifies privilege escalation risks
- Finds exposed sensitive data
-
Best Practice Violations
- Running containers as root user
- Missing health checks
- Inefficient layer management
Types of Issues Detected
Vulnerable Base Images
Detection of base images with known CVEs and security vulnerabilities
Secrets Exposure
Hard-coded passwords, API keys, or sensitive data in Dockerfile instructions
Privilege Escalation
Containers running as root or with unnecessary elevated privileges
Network Security
Exposed ports and insecure network configurations
Integration with Code Scanning
Dockerfile scanning is seamlessly integrated into your regular code scanning workflow:Automatic Inclusion
- No additional configuration required
- Scans run alongside SAST, SCA, and IaC analysis
- Results appear in the same vulnerability dashboard
Scan Triggers
- Repository Scans: Includes all Dockerfiles in the repository
- CI/CD Integration: Scans Dockerfiles in pull requests and commits
- Manual Scans: On-demand analysis of container configurations
Results Integration
- Dockerfile issues appear with other security findings
- Severity levels aligned with overall vulnerability scoring
- Remediation guidance provided for each issue
Dockerfile security scanning is automatically enabled when you scan repositories containing Docker configurations. No additional setup is required beyond your regular code scanning configuration.
Related: Container Image Scanning · IaC Security · Scan Parameters