Expand description
Core building blocks for uselesskey.
Most users should depend on the uselesskey facade crate instead.
This crate provides:
- deterministic, order-independent artifact derivation
- a concurrency-friendly cache
- tempfile sinks
- generic “negative fixture” helpers (corrupt PEM, truncate DER)
§Architecture
The core concept is the Factory, which manages artifact generation and caching.
It operates in two modes:
- Random mode: Artifacts are generated with OS randomness, cached per-process.
- Deterministic mode: Artifacts are derived from a master seed using BLAKE3,
ensuring the same
(domain, label, spec, variant)always produces the same artifact.
§Extension Pattern
Key types (RSA, ECDSA, etc.) are added via extension traits that add methods to Factory.
See uselesskey-rsa for an example implementation.
use uselesskey_core::Factory;
let fx = Factory::random();
// Extension crates add methods like: fx.rsa("label", spec)Modules§
Structs§
- Artifact
Id - Identifier used for deterministic artifact cache entries.
- Derivation
Version - Version tag for the derivation scheme.
- Factory
- How a
Factorygenerates artifacts. - Seed
- Seed bytes derived from user input for deterministic fixtures.
Enums§
Type Aliases§
- Artifact
Domain - Domain strings are used to separate unrelated fixture types.