Repository navigation
docs: add UPGRADING.md for moving from dryoc 1.x to 2.0 - #225
Merged
Merged
Conversation
Collects every breaking change between v1.0.0 and 2.0.0 in one page, with 1.x to 2.0 mappings: Cargo features, removed gen/*_with_defaults/zero-key constructors, fixed-size input types, module paths, boxes, signing, MACs, secret streams, key exchange, HKDF/hashing/password hashing, generic parameter order, sealed traits and the Classic detached-open argument order, plus the changes that still compile. The README links it once below the Quick Start snippet.
✅ Deploy Preview for dryoc-docs ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #225 +/- ##
==========================================
+ Coverage 68.32% 72.88% +4.56%
==========================================
Files 115 115
Lines 10032 10032
==========================================
+ Hits 6854 7312 +458
+ Misses 3178 2720 -458 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds
UPGRADING.md, a single page for the 2.0.0 release notes to link to. It lists every breaking change betweenv1.0.0andmain, with a 1.x → 2.0 mapping for each.README.mdgets one line linking to it, below the Quick StartCargo.tomlsnippet.src/lib.rsis unchanged.What the page covers
serdeis now a default feature;wincode→wincode_0_6(wincode 0.5 → 0.6);u64_backendremoved; thestd/allocsplit, which changes whatdefault-features = falsemeans;nightlyno longer enablesprotected, and it needs nightly-2026-09-24 or later.gen*,*_with_defaults, zero-keyKeyPair::new/DefaultandStackByteArray::new, with the replacement for each.ByteArrayis no longer implemented for slices orVec, so convert withtry_from.types::*;keypair::protected,precalc::protectedandprotected::ptypesare private; alias renames (dryocbox::KeyPair,kx::KeyPair,sha3::Sha3*Digest,IncrementalSigner,sodium_increment).Tagenum), key exchange, HKDF, hashing and password hashing changes; generic parameter order for callers that use a turbofish; sealed traits.generichashlength ranges, protected-memory deserialization now returning errors, and new#[must_use]warnings.It leaves out renames of APIs added after 1.0.0 (
kem,dryocsealedbox, XOF), since no 1.x user can have code using them.Sources
BREAKING CHANGEfooters and migration tables of refactor!: shared helpers, deduplicated impls, and removal of deprecated gen aliases (2.0.0) #153, chore!: remove unused u64_backend feature #172, fix!: remove all-zero keypair constructors and Default impls #174, feat!: rename wincode feature to wincode_0_6 #175, fix!: restrict ByteArray to fixed-size storage #176, feat!: no_std support with std and alloc features #178, feat!: enable serde by default #189, refactor(api)!: rename box open verbs and drop redundant box constructors #201, refactor(api)!: match libsodium argument order in classic detached open #203 and refactor(api)!: 2.0 API cleanup (signatures, stream Tag/Ed25519ph, aliases, must_use, generic order, re-exports and sealing) #204.cargo semver-checks --baseline-rev v1.0.0 --release-type minor(17 failing lints; I checked every removed or renamed item it reported against the page).pub fnsignatures betweenv1.0.0andmain.Verification
dryoc =1.0.0(featuresserde,wincode) and this branch (wincode_0_6).to_vec,serde_jsonandbincode(1.3): secretbox, box, key pair, signing key pair and signed message.DryocBox(from bytes and from serde), an XChaCha20-Poly1305VecEnvelope(from bytes, serde and wincode), a secret stream withMESSAGEandFINALtags, and a password hash (encoded string and serde).try_fromsnippets,StackKeyPair/StackSigningKeyPair/StackKdf/HkdfSha256/HkdfSha512::generate,VecBox::from_parts/into_parts/open/open_to_vec,seal_to_vecbox,sign_to_vecbox,Ed25519phSigner, the borrowed-key MACs, the turbofish orders, streamTaghandling,StackSession, HKDF with a length-last argument,DefaultGenericHash,VecPwHash,increment_bytes, and the new Classic detached-open order.all 2.0 snippets ok.DryocBox::from_parts(None, ..)cannot infer its ephemeral key type, so those rows useVecBox::from_parts.UPGRADING.mdare not doctests, and CI runs no Markdown checks.