Your source code never leaves the runner — discovery executes in-pipeline.
The pipeline — four steps
- Discover — scan code, certificates and TLS for cryptography.
- CBOM — export a schema-valid CycloneDX 1.6 Crypto-BOM (artifact).
- Score — quantum-risk + harvest-now-decrypt-later per asset.
- Gate — fail the build when findings breach your policy.
GitHub Actions
# .github/workflows/crypto-inventory.yml - name: Discover cryptography run: cryptagion scan code --path . --languages python,java,go,javascript,c --reset --exclude-tests - name: Generate CycloneDX 1.6 CBOM run: cryptagion export cbom --output cbom.json - name: Quantum-risk scoring run: cryptagion risk score -c confidential -y 10 --output assessments.json - name: Upload CBOM + assessment # audit trail for GRC uses: actions/upload-artifact@v4 with: { path: "cbom.json\nassessments.json" } - name: Crypto policy gate # + SARIF for the Security tab run: cryptagion gate --fail-on critical --max-allowed 0 -c confidential -y 10 --sarif crypto.sarif --base-path . - name: Upload SARIF to code scanning uses: github/codeql-action/upload-sarif@v3 with: { sarif_file: crypto.sarif, category: cryptagion }
GitLab CI works the same way. Full examples and the policy options ship with the product.
What a blocked merge looks like
✗ GATE FAILED — 15 finding(s) at/above 'critical' (max allowed: 0).
critical 100 key_manager.py:42 → ml-dsa
critical 100 sha1_hasher.py:12 → sha2
…
→ exit 2 → pull request blocked
The failing step turns the check red, and the log points at the worst offenders with file, line and recommended replacement. With --sarif, every finding also lands in GitHub's Security tab as a code-scanning alert — exact file and line, severity badge, dismissal workflow. No dashboard to build.
What the policy distinguishes
A useful gate separates broken cryptography from future migration work and from cryptography you should keep. CRYPTAGION's policy is built from:
- Severity threshold —
--fail-on low|medium|high|criticalsets the risk category that breaks the build;--max-allowedtolerates a known number of findings while you migrate. - Quantum status — each finding is classed as quantum-vulnerable, transitional or quantum-safe. In SARIF that maps to error, warning and note, so retained cryptography such as AES-256 does not flood the Security tab.
- Data sensitivity — a
.cryptagion.yamlpolicy (--policy) gives each path its own classification and confidentiality lifetime, so long-lived secrets score higher than public traffic. - Source scope — findings are tagged production, test, example or vendor;
--exclude-testsand--exclude-vendorkeep fixtures and third-party code out of the gate.
The first assessment creates the baseline. The CI gate keeps cryptographic debt from re-entering the codebase.
Cryptographic drift, release over release
Treat cryptographic architecture as something continuously observable. A snapshot records the inventory at each release; a diff shows exactly what changed — new RSA, a new certificate, a deprecated hash coming back.
$ cryptagion trend diff
▸ Posture regressed: total 75→78 (+3), vulnerable +2, critical +1, 3 added.
Added (3):
+ rsa-2048 src/billing/signer.go:58
+ sha1-? src/legacy/checksum.py:14
+ ecdsa-256 certs/partner-api.pem
trend diff also writes JSON (--output) for your pipeline or GRC tooling, and cryptagion watch re-scans on an interval and alerts on cryptography that appears or disappears between runs. Trend tracking and watch mode are part of the Platform tier.
Two ways to integrate
- CLI in CI — install the CLI in the runner (private index or a self-hosted image). Simplest, like syft/grype.
- API service (Platform tier) — run the CRYPTAGION FastAPI service on-prem (token-auth) and call
POST /scan/code,GET /inventory/summaryfor centralised SOAR/GRC integration.
Roll it out safely
Start the gate in report-only mode (a high threshold), baseline your estate, then tighten the policy wave by wave — so you never block a build on day one.
Want to see the gate in action? In the call we run CRYPTAGION's CI gate live on a public repository that matches your stack — no access to your code, no payment until you've seen it block a real change.
Request a free demo →