This project provides an example for running OpenSCAP security scans on Red Hat Enterprise Linux 9 (UBI9) Container.
Run the scan script:
./runBuilder.shThe script automatically handles:
- Building the Docker image
- Creating a container from the image
- Running the OpenSCAP scan (using the STIG profile)
- Copying scan results (report.html, results.xml) to a timestamped folder under
scans
Open the generated report.html in your browser for a human-readable summary. The results.xml contains detailed scan data.
- Docker
- Internet access (to fetch latest SCAP Security Guide content)
- Red Hat UBI9 base image access
The container automatically fetches the latest SCAP Security Guide content from the ComplianceAsCode GitHub releases. This ensures you always use the most recent security scanning profiles and benchmarks.
- To change the scan profile, modify the
CMDline inubi9.dockerfile. - To automate or schedule scans, integrate
runBuilder.shinto your CI/CD or cron jobs.
MIT License