Tony Arcieri f5cc8b709e ed25519: avoid serializing a length prefix with serde
Previously the serde serializer used `Serialize::serialize_bytes` which
accepts a slice and when serialized with e.g. bincode also includes a
length prefix on the signature. As it were, this made it incompatible
with the extant deserializer (and as such, this PR also adds much needed
serialization tests).

This commit changes the serializer to use the same internal
implementation as serde's own `array_impls`, i.e. signatures are
serialized as a tuple with 64 members.

Using this implementation, it means an Ed25519 signature serialized with
bincode is identical to `to_bytes()`, i.e. there is no redundant length
prefix.
2020-03-17 09:35:00 -07:00
2020-03-16 10:58:02 -07:00
2020-03-16 10:42:18 -07:00
2020-03-16 10:58:02 -07:00

RustCrypto: signatures Dependency Status Rust Version

Support for digital signatures, which provide authentication of data using public-key cryptography.

All algorithms reside in the separate crates and implemented using traits from the signature crate.

Crates are designed so they do not require the standard library (i.e. no_std) and can be easily used for bare-metal or lightweight WebAssembly programming.

Crates

Name Algorithm Crates.io Documentation Build
ecdsa ECDSA crates.io Documentation ecdsa build
ed25519 Ed25519 crates.io Documentation ed25519 build

Minimum Supported Rust Version

All crates in this repository support Rust 1.40 or higher. In future minimum supported Rust version can be changed, but it will be done with the minor version bump.

Usage

Crates functionality is expressed in terms of traits defined in the signature crate.

License

All crates licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

S
Description
Automated archival mirror of github.com/RustCrypto/signatures
Readme 11 MiB
Languages
Rust 100%