|
| 1 | +# cargo-deny configuration for QECTOR Decoder v3. |
| 2 | +# |
| 3 | +# Consumed by .github/workflows/dependency-audit.yml. That workflow pins |
| 4 | +# `cargo-deny@0.18` via taiki-e/install-action, because the deny.toml schema |
| 5 | +# changed meaningfully at 0.16 (the old `[licenses] copyleft` / |
| 6 | +# `allow-osi-fsf-free` / `default` keys were removed in favour of an explicit |
| 7 | +# `allow` list). This file is written for the 0.18 schema; do not unpin the tool |
| 8 | +# without re-reading it. |
| 9 | +# |
| 10 | +# The graph is evaluated with `--all-features`, so `opencl`, `grpc` and |
| 11 | +# `prometheus` are covered here even though the published wheel is built with |
| 12 | +# `--no-default-features --features abi3,cuda`. |
| 13 | +# |
| 14 | +# STATUS 2026-07-31: this file has never been executed. cargo-deny is not |
| 15 | +# installed on the maintainer machine (`cargo deny --version` -> "no such |
| 16 | +# command"), and no CI run has yet consumed it. The licence data below was |
| 17 | +# derived offline from `cargo metadata --all-features`, not from cargo-deny |
| 18 | +# itself. Treat the first CI run as the real validation. |
| 19 | + |
| 20 | +# --------------------------------------------------------------------------- |
| 21 | +# Licences |
| 22 | +# --------------------------------------------------------------------------- |
| 23 | +# |
| 24 | +# QECTOR ships under the PolyForm Noncommercial License 1.0.0 (see LICENSE; |
| 25 | +# PyPI surfaces it as `LicenseRef-QECTOR-Source-Available`) with a proprietary, |
| 26 | +# unpublished Rust core. Everything statically linked into the wheel is |
| 27 | +# redistributed, so the allow-list below is deliberately restricted to |
| 28 | +# permissive and weak-file-level-copyleft terms. |
| 29 | +# |
| 30 | +# Every entry corresponds to a licence actually present in the resolved graph |
| 31 | +# on 2026-07-31 (281 crates under `--all-features`, 199 in the published wheel |
| 32 | +# feature set). It is not an aspirational list. |
| 33 | +[licenses] |
| 34 | +# Raised from the 0.8 default. The root crate declares `license-file = "LICENSE"` |
| 35 | +# rather than a `license` expression, and LICENSE carries ~20 lines of QECTOR |
| 36 | +# preamble before the verbatim PolyForm text, which depresses the askalono |
| 37 | +# confidence score. 0.8 keeps that detection working; if the root crate is ever |
| 38 | +# reported as "unlicensed", that is the knob (or add an explicit `license =` |
| 39 | +# field to Cargo.toml, which is the better fix and is routed as a request). |
| 40 | +confidence-threshold = 0.8 |
| 41 | + |
| 42 | +# `PolyForm-Noncommercial-1.0.0` below is QECTOR's own licence and will not |
| 43 | +# match any third-party crate. Without this, cargo-deny reports it as an unused |
| 44 | +# allowance on every run. |
| 45 | +unused-allowed-license = "allow" |
| 46 | + |
| 47 | +allow = [ |
| 48 | + # --- permissive, no source-disclosure obligation ----------------------- |
| 49 | + "0BSD", # adler2 |
| 50 | + "Apache-2.0", # prost*, safetensors, sync_wrapper, ... |
| 51 | + "Apache-2.0 WITH LLVM-exception", # target-lexicon, rustix, linux-raw-sys, wasi |
| 52 | + "BSD-1-Clause", # fiat-crypto (as an OR alternative) |
| 53 | + "BSD-2-Clause", # numpy (rust-numpy), Pygments-style terms |
| 54 | + "BSD-3-Clause", # curve25519-dalek, ed25519-dalek, subtle |
| 55 | + "CC0-1.0", # dunce (as an OR alternative) |
| 56 | + "CDLA-Permissive-2.0", # webpki-roots (Mozilla CA bundle data) |
| 57 | + "ISC", # libloading, untrusted, rustls-webpki |
| 58 | + "MIT", # the plurality of the tree |
| 59 | + "MIT-0", # dunce / aws-lc-sys OR alternatives |
| 60 | + "Unicode-3.0", # the ICU4X crates pulled in via idna/url |
| 61 | + "Unlicense", # aho-corasick, memchr (OR MIT) |
| 62 | + "Zlib", # foldhash, miniz_oxide (OR alternative) |
| 63 | + |
| 64 | + # --- weak, file-level copyleft: DELIBERATE, see NOTICE.md -------------- |
| 65 | + # MPL-2.0 is allowed solely so that `priority-queue` (LGPL-3.0 OR MPL-2.0), |
| 66 | + # reached via fusion-blossom -> priority-queue, resolves against MPL-2.0 |
| 67 | + # instead of LGPL-3.0. MPL-2.0 obligations are per-file and are discharged |
| 68 | + # by shipping the crate unmodified and pointing at upstream sources; LGPL-3.0 |
| 69 | + # would not be dischargeable for a statically linked proprietary core. |
| 70 | + # If a future crate arrives under MPL-2.0 *only*, that is a legal decision, |
| 71 | + # not a config bump — record it in NOTICE.md first. |
| 72 | + "MPL-2.0", |
| 73 | + |
| 74 | + # --- QECTOR's own terms, for the root crate --------------------------- |
| 75 | + "PolyForm-Noncommercial-1.0.0", |
| 76 | +] |
| 77 | + |
| 78 | +# Workspace members that are never published do not need to satisfy the |
| 79 | +# allow-list. (The root crate has `publish = true`, so this does not exempt it — |
| 80 | +# it is covered by the PolyForm entry above.) |
| 81 | +private = { ignore = true } |
| 82 | + |
| 83 | +# --------------------------------------------------------------------------- |
| 84 | +# Bans |
| 85 | +# --------------------------------------------------------------------------- |
| 86 | +[bans] |
| 87 | +# The tree carries several legitimately duplicated majors (hashbrown x3, |
| 88 | +# syn x3, indexmap x2, petgraph x2, rand x2, thiserror x2, getrandom x2 as of |
| 89 | +# 2026-07-31). Deduplicating those is upstream's job, not a release gate. |
| 90 | +multiple-versions = "warn" |
| 91 | +# A `*` version requirement makes Cargo.lock the only thing standing between a |
| 92 | +# release and an arbitrary future upstream version. None exist today. |
| 93 | +wildcards = "deny" |
| 94 | + |
| 95 | +[[bans.deny]] |
| 96 | +# QECTOR's only TLS consumer is `ureq`, configured for pure-Rust rustls |
| 97 | +# (Cargo.toml:57). openssl-sys appearing in the graph means something switched |
| 98 | +# to native-tls, which changes the wheel from "no system TLS dependency" to |
| 99 | +# "links against whatever libssl the host has" — a build-reproducibility and |
| 100 | +# supply-chain regression that is silent otherwise. |
| 101 | +crate = "openssl-sys" |
| 102 | +reason = "QECTOR links rustls only; a native-tls path must be a deliberate, reviewed change" |
| 103 | + |
| 104 | +# --------------------------------------------------------------------------- |
| 105 | +# Sources |
| 106 | +# --------------------------------------------------------------------------- |
| 107 | +[sources] |
| 108 | +# Every dependency must come from crates.io. A git or path dependency slipping |
| 109 | +# into a release build means the published wheel cannot be rebuilt from |
| 110 | +# Cargo.lock alone. |
| 111 | +unknown-registry = "deny" |
| 112 | +unknown-git = "deny" |
| 113 | +allow-registry = ["https://github.com/rust-lang/crates.io-index"] |
| 114 | + |
| 115 | +# --------------------------------------------------------------------------- |
| 116 | +# Advisories |
| 117 | +# --------------------------------------------------------------------------- |
| 118 | +# |
| 119 | +# `cargo deny check advisories` is run in a NEVER-BLOCKING step in |
| 120 | +# dependency-audit.yml; the blocking vulnerability gate is `cargo audit`. The |
| 121 | +# split is deliberate: an unmaintained transitive crate is a planning problem, |
| 122 | +# not a reason to refuse to ship a security fix. |
| 123 | +[advisories] |
| 124 | +yanked = "deny" |
| 125 | +# Do not add entries here to make a release green. The remediation for a RustSec |
| 126 | +# advisory is `cargo update -p <crate>` (or a dependency change), per |
| 127 | +# docs/DEPENDENCY_POLICY.md. An `ignore` entry requires a dated, named exception |
| 128 | +# recorded in that file's exception register first. |
| 129 | +ignore = [] |
0 commit comments