Spdx.Compliance
0.2.0
See the version list below for details.
dotnet add package Spdx.Compliance --version 0.2.0
NuGet\Install-Package Spdx.Compliance -Version 0.2.0
<PackageReference Include="Spdx.Compliance" Version="0.2.0" />
<PackageVersion Include="Spdx.Compliance" Version="0.2.0" />
<PackageReference Include="Spdx.Compliance" />
paket add Spdx.Compliance --version 0.2.0
#r "nuget: Spdx.Compliance, 0.2.0"
#:package Spdx.Compliance@0.2.0
#addin nuget:?package=Spdx.Compliance&version=0.2.0
#tool nuget:?package=Spdx.Compliance&version=0.2.0
Spdx.Compliance
Spdx.Compliance is an offline .NET 10 library for evaluating SPDX license fields and CycloneDX 1.6 component occurrences against a caller-supplied distribution policy.
dotnet add package Spdx.Compliance --version 0.2.0
- Load a schema 1 or 2 JSON policy with
CompliancePolicy.Load. Schema 2 supports optional SPDX term aliases, category rules, license preferences, profile overrides, global prohibitions, multiple notices and CycloneDX conclusion verification. An optional correction catalog must match the SHA-256 recorded in that policy. - Call
ComplianceEngine.Evaluatefor one field, with optional SPDX document scope, recorded choices for independent and nested ORs, and delivery evidence. ReadRegistryIdentityon the evaluation to record its embedded SPDX catalogue. - Call
ComplianceEngine.EvaluateParsedto reuse a successfully parsed expression under the policy's expression limits, orOrSelectionSet.ApplySelectionsto inspect and format the residual expression from a batch of choices without loading a policy. - Call
ComplianceEngine.CompareConclusionfor structural comparison of two original expressions, orComplianceEngine.EvaluateConclusionto audit the relationship and inspect the hypothetical replay. Opt in to accepting a unique inferred choice. - Call
ComplianceEngine.AnalyzeAlternativesorAnalyzeParsedAlternativesto inspect available routes and request a verified choice batch. Single-ID recommendations use the policy ranking or an in-memory override and apply to one prospective declaration. A combined assessment can still block advice for that occurrence. - Call
GetCategoryAnalysis()on an alternative analysis to inspect all term occurrences and summarize possible and required categories across structural or fully allowed routes. - Call
CycloneDxComplianceAnalyzer.Analyzefor a CycloneDX 1.6 JSON stream. Inspect each occurrence's decision, declared and observed licenses, and independent correction finding. - Call
CycloneDxComplianceAnalyzer.AnalyzeDetailedfor per-field JSON Pointers, source-bound replay and scan coverage. Choose how to interpret recorded conclusions independently of extending presence checks beyond the eligible pair. A mandatory denial in the compared declaration takes precedence over disagreement. Both causes remain visible. ReadSourceKeyon either report's evaluation for the JSON Pointer of its decoded source text. - Call
CompliancePolicy.VerifyCorrectionto check a correction against the pinned catalog and trusted occurrence identity supplied by your application. Schema 2 supports exact identity tuples with optional version ranges and marker-free catalogs for direct checks of non-NuGet rules. - Call
GetActionSummary()on a policy evaluation to see current choices and evidence checks, plus branch conditions for eligible routes. Shared notice actions retain each originating occurrence and its applicable choices. - Call
ComplianceAggregatorto select and group evaluations or CycloneDX occurrences by policy and outcome. UseConclusionEvaluation.ToOccurrenceto include a conclusion's effective result and full comparison evidence. The summary retains current and contingent actions, occurrence provenance, exclusions and coverage.
A verified correction confirms the assertion matches the pinned rule. Distribution depends on the applicable policy rules and evidence. A complete document report describes the evaluated occurrences and does not issue a release approval.
Version 0.2.0 declares dependencies on Spdx.Expressions 1.2.0 and NuGet.Versioning 8.0.0. The application supplies all policy data and evidence. Evaluation performs no network or filesystem access.
See the policy schema, migration guide and runnable examples. Track distribution and artifact checksums on NuGet and the tagged release.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net10.0
- NuGet.Versioning (>= 8.0.0)
- Spdx.Expressions (>= 1.2.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Reuses parsed expressions and verifies source-bound choices and CycloneDX conclusions. Adds route recommendations, scoped category analysis, schema 2 profiles and notice rules, trusted corrections, and coverage-aware aggregation.