Age | Commit message (Collapse) | Author |
|
|
|
- Fixes #563
- With an MSRV >= 1.40.0, we can use #[non_exhaustive], as mentioned
in #406.
- This is also a clippy lint:
https://rust-lang.github.io/rust-clippy/master/index.html#manual_non_exhaustive
|
|
|
|
- Adjust code to test for `cfg(test)` only,
- Remove `quickcheck` and `rand` from dependencies so that they stay
only in dev-dependencies,
- Remove mention of `x-quickcheck` feature from the documentation,
- Fixes #545.
|
|
- This mirrors how we handle other unknown variants. However, since
we do not know the length of the parameters for unknown S2K
variants, we cannot parse them back. To work around that, the
parameter field is optional, and will be `None` when an unknown
S2K is parsed. The data is not lost, but stored in the packet
containing the S2K object, so that we can serialize it again.
- Carefully preserve the invariant that we can parse any packet we
can serialize by comparing the serialized form of the packet
fragments containing the S2K and any fields the parameters of
unknown variants bleed into on parsing.
- Unfortunately, this means that S2K on its own no longer
roundtrips. Remove that test accordingly.
|
|
|
|
|
|
|
|
- See #474.
|
|
- See #474.
|
|
|
|
- Creating S2K objects is tricky because not every iteration count
is representable. Add a constructor that helps with that.
|
|
- Previously, S2K::nearest_hash_count(1025) == 1025, which is not
representable. The problem did persist after removing the
1025..=2048 match, therefore there is a problem in the maths.
Replace by an less elegant, iterative implementation. Add tests.
|
|
- Reduce the range of input values to increase the chance of finding
errors.
|
|
|
|
|
|
- There is no variant called `None`, so having this predicate seems
wrong.
- See #489.
|
|
- Make quickcheck dependency optional.
- Make quickcheck a dev-dependency for tests.
- Fix doctests for
- cert::ValidCert::user_attributes,
- cert::builder::CertBuilder::add_user_attribute,
- cert::revoke::UserAttributeRevocationBuilder
- cert::revoke::UserAttributeRevocationBuilder::build.
Doctests do not use cfg(test), so we cannot use quickcheck in there.
|
|
This reverts commit 2e1eec5fe4157a391a13554ff7df3075cfe043cc.
|
|
- This avoids the partial implementation imitating
std::option::Option, replacing it with std::result::Result.
- As a benefit, std::result::Result is in the prelude, simplifying a
lot of parsing loops.
|
|
|
|
- Add two new traits: `Marshal` and `MarshalInto`.
- Implement them instead of `Serialize` and `SerializeInto`.
- Only implement `Serialize` and `SerializeInto` for data structures
that are normally exported.
- This should prevent users from accidentally serializing a bare
signature (`Signature`) when they meant to serialize a signature
packet (`Packet`), for instance.
- Fixes #368.
|
|
- Remove direct access, provide Password::map instead.
|
|
|
|
Signed-off-by: Daniel Kahn Gillmor <dkg@fifthhorseman.net>
|
|
The `...` syntax is deprecated in favour of `..=` since 1.26 and
is an idiom lint in the 2018 edition.
Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
|
|
- With the MIR-based borrow-checker being more precise than the
AST-based one, we can make more variables immutable.
|
|
- This is the result of running `cargo fix --edition`, with some
manual adjustments.
- The vast majority of changes merely qualify module paths with
'crate::'.
- Two instances of adding an anonymous pattern to a trait's
function.
- `async` is a keyword in Rust 2018, and hence it needs to be
escaped (e.g. in the case of the net::r#async module).
- The manual adjustments were needed due to various shortcomings of
the analysis employed by `cargo fix`, e.g. unexpanded macros,
procedural macros, lalrpop grammars.
|
|
- Add and use a function that fills a buffer with a thread-local
random number generator.
|
|
- See #302.
|
|
- Fix the value to the largest one OpenPGP can represent. On
moderate machines, like my Intel(R) Core(TM) i5-2400 CPU @
3.10GHz, it takes ~354ms to derive a key.
- Fixes #192.
|
|
|
|
|
|
|
|
|
|
|
|
- 'iterations' is really inappropriate, and even needed an
explanation in the code.
|
|
|
|
- Fixes #267.
|
|
- Eventually, we will provide a no_std variant of this crate.
- Fixes #185.
|
|
|
|
- Trait Parse introduces a uniform interface to parse packets,
messages, keys, and related data structures.
|
|
|
|
|
|
|