How sraisl/polyscan-action works
PolyScan is a GitHub Action that runs selected security scanners against a workspace, normalizes their findings, then evaluates a quality gate and writes reports. The README also documents broad language and artifact capabilities; unsampled engine adapters are represented collectively. Edges follow the visible entry-point dispatch and report calls, or documented responsibilities; unsampled implementation details are not inferred.
Main entry points: main.ts Action entry · betterleaks.ts Betterleaks · trivy.ts Trivy · gosec.ts Gosec
Components 21
Action orchestration
- Action entry
src/main.ts - Engine selection
src/engines.ts - Scan scheduler
src/scheduler.ts
Security scanners
- Semgrep parsers
src/engines/semgrep-json.ts - Betterleaks
src/engines/betterleaks.ts - Detekt
src/engines/detekt.ts - Gosec
src/engines/gosec.ts - SpotBugs
src/engines/spotbugs.ts - Trivy
src/engines/trivy.ts - Trufflehog
src/engines/trufflehog.ts - Other engine adapters
src/engines
Shared runtime
- Workspace paths
src/target.ts - Process execution
src/exec.ts - Tool management
src/tools.ts - Pinned tool versions
src/tool-versions.ts - Finding schema
src/schema.ts
Results and reports
- Quality gate
src/gate.ts - SARIF output
src/sarif.ts - CycloneDX SBOM
src/sbom.ts - Job summary
src/summary.ts
Other components
- GitHub workflow
Connections 36
- GitHub workflow → Action entry: starts action
README.md - Action entry → Engine selection: resolves engines
src/main.ts - Action entry → Workspace paths: resolves paths
src/main.ts - Action entry → Scan scheduler: schedules scans
src/main.ts - Action entry → Semgrep parsers: dispatches scan
src/main.ts - Action entry → Betterleaks: dispatches scan
src/main.ts - Action entry → Detekt: dispatches scan
src/main.ts - Action entry → Gosec: dispatches scan
src/main.ts - Action entry → SpotBugs: dispatches scan
src/main.ts - Action entry → Trivy: dispatches scan
src/main.ts - Action entry → Trufflehog: dispatches scan
src/main.ts - Action entry → Other engine adapters: dispatches scans
README.md - Action entry → Quality gate: evaluates findings
src/main.ts - Action entry → SARIF output: writes SARIF
src/main.ts - Action entry → CycloneDX SBOM: writes SBOM
src/main.ts - Action entry → Job summary: renders summary
src/main.ts - Action entry → Finding schema: counts findings
src/main.ts - Betterleaks → Process execution: runs command
src/engines/betterleaks.ts - Betterleaks → Tool management: prepares binary
src/engines/betterleaks.ts - Betterleaks → Pinned tool versions: gets tool metadata
src/engines/betterleaks.ts - Betterleaks → Workspace paths: resolves target
src/engines/betterleaks.ts - Betterleaks → Finding schema: returns findings
src/engines/betterleaks.ts - Gosec → Process execution: runs scanner
src/engines/gosec.ts - Gosec → Tool management: prepares binary
src/engines/gosec.ts - Gosec → Pinned tool versions: gets tool metadata
src/engines/gosec.ts - Gosec → Finding schema: returns findings
src/engines/gosec.ts - SpotBugs → Process execution: runs builds and scanner
src/engines/spotbugs.ts - SpotBugs → Tool management: prepares binaries
src/engines/spotbugs.ts - SpotBugs → Pinned tool versions: gets tool metadata
src/engines/spotbugs.ts - SpotBugs → Finding schema: returns findings
src/engines/spotbugs.ts - Trivy → Process execution: runs scanner
src/engines/trivy.ts - Trivy → Tool management: prepares binary
src/engines/trivy.ts - Trivy → Pinned tool versions: gets tool metadata
src/engines/trivy.ts - Trivy → Workspace paths: resolves target
src/engines/trivy.ts - Trivy → Finding schema: returns findings
src/engines/trivy.ts - Action entry → Job summary: publishes summary
src/main.ts