Wave 1 task core-hashing-keys: the crate's declared one-way door,
implemented byte-exact to ADR-002.
- src/hashing.rs: Algorithm (exactly GitBlobSha256 canonical /
GitBlobSha1 tolerated; BLAKE3 absent), Digest (known-length
derivation H("blob <len>\0" + content) as primary constructor;
from_git_oid_hex interop constructor, lowercase-only acceptance),
and the hashing::registry constants (0x01/0x02, 0x00 reserved; new
algorithm = new ADR)
- src/keys.rs: typed Key wrapper; as_bytes/from_bytes are the only
backend-boundary conversions; 1 algorithm byte + digest bytes
(33/21 total); rejects-never-guesses validation -> Error::KeyInvalid
- tests/git_interop.rs: the load-bearing test — byte-exact derivation
against the `git hash-object` CLI, both algorithms, small and
75-KiB content; external-oid round-trip into pool keys; both oid
formats coexisting in one flat pool
- named design point (oid hex policy): lowercase-only acceptance,
recorded in the task Notes and on from_git_oid_hex
Verified: cargo test (15 passed), cargo clippy --all-targets -- -D
warnings, cargo fmt --check, cargo test --all-features — all green.
39 lines
1.2 KiB
TOML
39 lines
1.2 KiB
TOML
[package]
|
|
name = "alkblobs"
|
|
version = "0.1.0"
|
|
edition = "2021"
|
|
rust-version = "1.88"
|
|
license = "MIT OR Apache-2.0"
|
|
description = "Content-addressed blob storage: multi-hash put/get/verify store with pluggable backends, transport- and protocol-agnostic"
|
|
repository = "https://git.alk.dev/alkdev/alkblobs"
|
|
keywords = ["blobs", "content-addressed", "storage", "gix", "bao"]
|
|
categories = ["asynchronous", "filesystem", "database"]
|
|
exclude = [".opencode/", "AGENTS.md", "docs/reviews/", "docs/research/", "docs/plans/", "tasks/", "docs/sdd_process.md"]
|
|
|
|
[workspace]
|
|
members = ["."]
|
|
exclude = []
|
|
|
|
[lib]
|
|
name = "alkblobs"
|
|
|
|
[features]
|
|
default = ["sqlite"]
|
|
sqlite = ["dep:rusqlite"]
|
|
postgres = ["dep:tokio-postgres", "dep:deadpool-postgres"]
|
|
mem = []
|
|
pg-lo = ["dep:tokio-postgres", "dep:deadpool-postgres"]
|
|
ops = ["dep:alkcall"]
|
|
|
|
[dependencies]
|
|
tokio = { version = "1", default-features = false, features = ["rt", "sync", "io-util", "macros"] }
|
|
thiserror = "2"
|
|
parking_lot = "0.12"
|
|
|
|
alkcall = { version = "0.8.1", optional = true }
|
|
deadpool-postgres = { version = "0.14", optional = true }
|
|
hex = "0.4"
|
|
rusqlite = { version = "0.40", features = ["bundled"], optional = true }
|
|
sha1 = "0.10"
|
|
sha2 = "0.10"
|
|
tokio-postgres = { version = "0.7", optional = true } |