Skip to main content
For guidance on choosing between formats, see Format Comparison.

Interim JSON Format

The default output format containing detailed cryptographic asset information optimized for the SCANOSS ecosystem. The interim report is the primary findings artifact. It contains finding metadata such as finding_id, but it does not currently embed the finding-centric reachability slices produced by --export-callgraph.

Format Specification

Version 1.1 introduced the rules array field (replacing single rule field) to support per-line deduplication. Version 1.2 added source and dependency_info for dependency scanning attribution. Version 1.3 adds finding_id for cross-referencing with the callgraph export. Dependency-backed file_path values are dependency-root-relative; the package identity stays in dependency_info. Reachability slices such as call_chains are emitted by the dedicated call graph export, not by the interim report. See Dependency Scanning for details.

Field Descriptions

Call Graph Export

When --export-callgraph is enabled, Crypto Finder also writes a separate finding-centric call graph JSON file. This export contains the reachability slices and value-flow details associated with findings from the interim report.
Schema note: call graph export version 6.4 is the current customer-facing reachability contract. Version 6.4 adds method_role, role_provenance, and parameter_roles — contracts-KB-derived method/parameter role classification (factory/config/output/operation on method_role; per-parameter operation-determining/metadata-contributing/none with a contributes: {property, derivation} block on parameter_roles). method_role/role_provenance appear on crypto_entry_points; parameter_roles appears on crypto_entry_points and on the supporting-call declaration, index-aligned with parameter_types — never on call-site parameter literals. As of 6.4, these fields are populated on the live (--export-callgraph) and graph-fragment export paths and carried through the stitched/served path (role-bearing crypto_entry_points are merged into the served output by function_key, enriching an existing reachability entry or appending a role: operation catalog entry with no reachable finding). Version 6.3 added the optional per-finding forward_calls block — the finding anchor’s forward call closure (deduped nodes with depth/crypto_relevant/supporting_category, plus traversed edges whose entry_call carries the call-site argument data-flow), emitted only when the stitch runs with StitchOptions.ForwardClosure; caps (depth/nodes/edges) are surfaced via max_depth and an explicit truncated flag, never silently. Version 6.0 removed the legacy entry_point_index projection and made crypto_entry_points[] canonical. Version 4.3 added Java runtime provenance in scan_metadata for JDK-aware platform signature enrichment.
  • Each top-level record stays keyed by finding_id, which is the join key back to the interim report.
  • call_chains is the primary value-flow structure. Each chain is ordered from the first reachable caller to the function that contains the matched crypto call.
  • Each chain node contains a fully qualified function_name, a normalized file_path, start_line, optional dependency_info, and optional entry_call.
  • entry_call describes how execution entered the current node from the previous step. Its file_path and line refer to the call site in the previous node’s source file.
  • The last node in each chain carries crypto_call, which is the matched crypto-relevant call for the finding.
  • entry_call.parameters[] and crypto_call.parameters[] both use the same parameter model: parameter_index (always 0-based), best-effort type, argument_expression, resolved_value, variable_name for simple identifiers only, and recursive source_nodes.
  • For Java scans, scan_metadata may also include java_requested_jdk_major, java_runtime_version, java_platform_signatures_used, java_platform_signature_source, and java_platform_signature_unavailable_reason to show which JDK major was requested and whether JDK platform signatures contributed to type enrichment.
  • source_nodes can span multiple wrapper hops. A local PARAMETER node may contain nested upstream provenance such as PARAMETER -> PARAMETER -> VALUE, and propagated nested nodes keep location.file_path plus location.line when known.
  • Method-call provenance is preserved as CALL_RESULT nodes. When the parser can resolve the invoked method, the node also exports call_target, and any traceable receiver value is nested under that CALL_RESULT via source_nodes (for example CALL_RESULT -> PARAMETER alg -> VALUE SignatureAlgorithm.HS256).
  • Findings missing a containing function or crypto-call match are still exported with finding_location and unresolved_reason.
  • crypto_entry_points[] is the stitch/API index. Each entry carries function_key, canonical/display symbols, aliases, and reachable_findings[] / reachable_supporting_calls[].
  • supporting_calls[] carries config/lifecycle/context crypto-adjacent calls, such as builder options or parameter setup. These calls are not findings and do not inflate finding_graphs[].
  • Constructor joins remain canonical (<init>), while display fields and aliases expose IBM-style names such as com.acme.Factory.Factory.
  • entry_point_index is not emitted by schema 6.0. Consumers should migrate to crypto_entry_points[].

Example Output

Example Output

Single Rule Detection:
Multiple Rules Detection (Deduplicated):

Use Cases

  • Integration with SCANOSS platform
  • Custom analysis pipelines
  • Detailed cryptographic asset tracking
  • Security auditing and compliance

Graph Fragment Export

When --export-graph-fragment <file> is enabled, Crypto Finder writes a reusable structural graph fragment for the scanned component: its call graph plus rules-versioned crypto annotations. Unlike the finding-centric call graph export (above), a fragment is designed to be composed with other fragments across a dependency tree to answer “what crypto is transitively reachable from artifact X?” The pure model and the stitcher that composes fragments live in the public package github.com/scanoss/crypto-finder/pkg/graphfrag, so downstream consumers can use one contract instead of reimplementing schema knowledge. Current schema version: graph-fragment-1.3. As of graph-fragment-1.3, a fragment is self-contained enough to reconstruct the two artifacts a live --scan-dependencies run would produce — see Rendered artifacts below.

Structure

Per-call data flow: entry_call (1.2+)

Every internal_edges[] and external_calls[] entry may carry an entry_call describing the call-site argument data-flow for that edge — the same model the finding-centric call graph export uses (see Call Graph Export above): entry_call.parameters[] each have parameter_index, best-effort type, argument_expression, resolved_value, variable_name (simple identifiers only), and recursive source_nodes provenance. Carrying it on the edge is what lets the stitcher rebuild full per-frame value flow when composing chains across components, so a stitched chain matches a live run frame-for-frame.

Crypto annotation fields (1.2+)

A graph-fragment-1.2+ crypto_annotations[] entry carries enough to reconstruct a full findings.json entry for the matched crypto call:

Rendered artifacts: ToCallgraphExport / ToFindingsEnvelope

Because a 1.3 fragment carries per-call data flow, full crypto-annotation, supporting-call, and entrypoint metadata, pkg/graphfrag can render a stitched Result into the same two artifacts a live --scan-dependencies run produces:
  • Result.ToCallgraphExport(root, meta) — renders the stitched result into a schema-6.0 callgraph, equivalent to a live --scan-dependencies --export-callgraph run. Dep-component findings get module@version/-prefixed finding_ids, matching live output.
  • ToFindingsEnvelope(root, deps, fragments, meta) — reconstructs the findings.json v1.3 envelope (asset metadata). Its finding_ids are computed with the same inputs as ToCallgraphExport, so the two agree: consumers join assets (envelope) to call chains (callgraph) by finding_id.
pkg/graphfrag/equiv is a semantic diff tool that asserts a stitched callgraph equals a live one minus the chains intentionally dropped by resolution suppression (see below) — the equivalence guarantee these renderers rely on.

Edge resolution metadata (v1.1+)

Every internal_edges[] and external_calls[] entry carries resolution metadata describing how confidently the edge was resolved. This lets a consumer distinguish exact typed calls from over-broad name/arity dispatch guesses, and refuse to present the latter as typed reachability proof. resolution values:
  • exact — the receiver’s static type was known and the method resolved to a unique declared target on that type (or an overload set on that exact type).
  • interface_dispatch — the target was found by expanding an interface/abstract method to concrete implementations matching name + arity within a namespace root. Trustworthy only when exactly one implementation is present in the dependency closure; otherwise it is an ambiguous guess.
  • name_only — the target was guessed by method name + arity (plus namespace heuristics) with no receiver-type anchor (e.g. fluent-chain fallback).
method_name + arity + the call-site line let a consumer group sibling candidates of one call site so ambiguity can be detected across edges that span the component boundary. The reference consumer (pkg/graphfrag’s stitcher) applies a tiered, fail-closed policy: traverse exact edges and interface_dispatch edges with exactly one implementation in the dependency closure; drop ambiguous interface dispatch (>1 impl) and name_only edges, recording them rather than emitting a chain. This is what prevents a DRBG’s generate() from name-colliding with BCrypt.generate#3 (or provider.get(...) fanning out to unrelated get(...) methods) from being reported as reachable crypto.
Fragments exported by older versions (without resolution) decode as unresolved and are treated as untrusted (fail-closed): under-report, never a false positive.

Example

In this slice, decryptPrivateKeyInfo has one exact edge to the real InputDecryptorProvider.get and one over-broad interface_dispatch edge to an unrelated get#1 from the same call site (line: 90). A stitcher that sees more than one implementation for that call site drops the ambiguous group.

CycloneDX Format

CycloneDX 1.6-compatible Cryptography Bill of Materials (CBOM) format for standardised reporting.

Features

  • Schema Validation: Output is validated against the CycloneDX 1.6 specification.
  • Standardised Components: Cryptographic assets are mapped to CycloneDX-defined component types.
  • Rich Metadata: Includes algorithm properties, evidence, and provenance information.

Supported Asset Types

Example Output

Converting Formats

Use the convert command to transform interim JSON to CycloneDX:

Integration

CycloneDX CBOM output can be consumed by tools including:
  • Dependency-Track (OWASP)
  • Software Bill of Materials (SBOM) aggregators
  • Security scanning platforms
  • Compliance reporting tools
  • Supply chain risk management systems

Format Comparison