ci: harden OSS CI with CodeQL, Scorecard, Dependabot, and SECURITY.md (closes #282, closes #277) - #290
Open
Madhumasa84 wants to merge 1 commit into
Open
Conversation
|
You are seeing this message because GitHub Code Scanning has recently been set up for this repository, or this pull request contains the workflow file for the Code Scanning tool. What Enabling Code Scanning Means:
For more information about GitHub Code Scanning, check out the documentation. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
The repository currently lacks automated static code analysis (CodeQL), supply-chain posture analysis (OpenSSF Scorecard),
automated weekly dependency version updates (Dependabot), continuous dependency vulnerability auditing (
pip-audit), and aformal vulnerability disclosure policy (
SECURITY.md). Without these, dependency updates and vulnerability scans must bemaintained manually, and security researchers lack a dedicated private disclosure path.
Closes #282
Closes #277
Prior art - what already exists
Followed standard GitHub Actions and OpenSSF workflow conventions alongside existing CI workflows (
oss-guard.yml,security-regression.yml).Tangential updates: None.
Solution - high level
.github/dependabot.ymlto automate weekly updates across GitHub Actions, Python root dependencies, and adapter npmpackages.
.github/workflows/codeql.ymlfor CodeQL SAST scanning across Python and JavaScript/TypeScript..github/workflows/scorecard.ymlfor OpenSSF Scorecard supply-chain evaluation..github/workflows/dependency-scan.ymlfor automatedpip-auditCVE checks on pushes and PRs.SECURITY.mddefining supported versions, private reporting channels (GitHub Advisories &security@prismor.dev),and response SLAs.
Deep dive - how it works
codeql.yml): Analyzes Python and JavaScript/TypeScript codebases withgithub/codeql-action/init@v3andanalyze@v3. Configured with least-privilege permissions (security-events: write,contents: read).scorecard.yml): Scans weekly withossf/scorecard-action@v2.4.0and exports SARIF results toGitHub Security with
publish_results: true.dependabot.yml): Configured with version 2 syntax covering 4 package ecosystems:github-actionsin/,pipin/, andnpmin/adapters/mastraand/adapters/vercel-ai.dependency-scan.yml): Installspip-auditand project dependencies (pip install .) to checkagainst known CVE databases (OSV/PyPI).
SECURITY.md): Contains responsible disclosure instructions, 48h acknowledgment SLA, and scopedefinitions without any emojis or external dependencies.
Files changed
.github/dependabot.yml.github/workflows/codeql.yml.github/workflows/scorecard.yml.github/workflows/dependency-scan.ymlpip-auditSECURITY.mdTesting
python3 scripts/check_oss_safe.py bash scripts/verify_registry.sh pytest tests/test_oss_guard.py tests/test_policies.py tests/test_policy_engine.py tests/test_hooks.py python3 -c "import yaml; [yaml.safe_load(open(f)) for f in ['.github/dependabot.yml','.github/workflows/codeql.yml','.github/workflows/scorecard.yml','.github/workflows/dependency-scan.yml']]"[✓] bash scripts/run_security_tests.sh passes
[✓] Added or updated tests covering the new behavior
[✓] If an integration changed: bash scripts/verify_registry.sh
[✓] All 369 core tests passed; YAML syntax validated on all 4 configuration files
[✓] OSS safety guard passed (449 files scanned, 0 leaks)
Security checklist
[✓] No detection patterns hardcoded in Python — all rules live in YAML
[✓] No real secrets, keys, or credentials in code, tests, fixtures, or docs
[✓] No real secret values printed, logged, or serialized (used @@secret:@@)
[✓] No guardrail weakened; if one was, it is called out and justified above
[✓] Docs that describe this behavior (SKILL.md, docs/, AGENTS.md) are still accurate
Diff size
Lines changed: +227 / -0 · Justification if large: 5 new configuration and documentation files only; zero existing runtime code
modified.