Age | Commit message (Collapse) | Author |
|
- Add a buffered-reader-based function to trait Parse. This allows
us to manipulate the buffered reader stack before and after
parsing, e.g. to parse several armored objects in one stream. The
CertParser also does this, but uses internal interfaces for that.
|
|
- Fixes #1060.
|
|
|
|
|
|
- In order to deal with version 2 SEIP packets, we first need to be
explicit about the packet version in the message parser.
- Rename the token and grammar rules, pass in a version to
MessageParser::push.
|
|
- Do this using a deprecation so that anyone using it will get a
compiler warning.
- Revert this change once message::Token is private.
- See #836.
|
|
- The vec![] macro is more performant and often easier to read than
multiple push calls.
- Allow push to a Vec straight after creation in tests. Performance
is not that great of an issue in tests, and the fix would impact
legibility.
- Found by clippy::vec_init_then_push.
|
|
The extra & in a pattern (match arm or if let) is unnecessary and only
makes the code harder to read. In most places it's enough to just
remove the & from the pattern, but in a few places a dereference (*)
needs to be added where the value captured in the pattern is used, as
removing the & changes the type of the captured value to be a
reference.
Overall, the changes are almost mechanical. Although the diff is huge,
it should be easy to read.
The clippy lint match_ref_pats warns about this. See:
https://rust-lang.github.io/rust-clippy/master/index.html#match_ref_pats
|
|
- Apply cargo intraconv.
|
|
- https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
|
|
- https://rust-lang.github.io/rust-clippy/master/index.html#len_zero
- https://rust-lang.github.io/rust-clippy/master/index.html#comparison_to_empty
|
|
- https://rust-lang.github.io/rust-clippy/master/index.html#match_like_matches_macro
|
|
- https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion
|
|
|
|
- Avoid the additional `fn f()`.
|
|
- This way the entire `BufferedReader<C>` will be `Send` and `Sync`.
- Modify all other crates accordingly.
- See #615.
|
|
- All types that are `Send` and `Sync` are checked now.
- Fixes #627.
|
|
|
|
- See #627.
|
|
- 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
|
|
- See #480.
|
|
|
|
- Previously, the symmetric algorithm argument conflated the
algorithm to protect the payload and the one to protect the
session key. Fix that by adding an argument to make the choice
explicit.
|
|
|
|
- Fix session key size in test.
|
|
|
|
- Align our examples with how the code in the examples of the Rust
standard library is formatted. We are writing examples in the
hope that downstream users will copy fragments of them, therefore
using idiomatic formatting in these snippets is important.
|
|
|
|
|
|
- Don't export CertValidity, KeyringValidator, KeyringValidity, or
MessageValidity.
- Fixes #490.
|
|
- Make MessageValidator `pub(crate)` instead of `pub`.
- Move doctests into unit tests as doctests cannot access `pub(crate)`
APIs.
- Fixes #490.
|
|
- Add Examples to all public functions.
- Add example armored message to the header.
- Fix wording.
- Fixes #468.
|
|
- Rename all calls to `Builder` with `SignatureBuilder`.
- Fixes #481.
|
|
To be consistent; we don't use plural forms for modules anywhere else
and Rust always uses singular forms.
|
|
|
|
|
|
- See #462.
|
|
- Avoid repeating the type name.
- Avoid self referential, trivial descriptions.
- Avoid the terms OpenPGP and Sequoia.
- Fix mistakes from the Message -> PacketPile rework.
|
|
|
|
|
|
- Packet bodies can now be either unprocessed (e.g. compressed,
encrypted), processed (e.g. uncompressed, decrypted), or
structured (e.g. parsed into packets).
- Make the container types deref to Container, and container deref
to packet bodies.
- This cleanly avoids the confusion when serializing containers: We
can serialize compressed data packets with either body, but we can
only serialize encryption containers with unprocessed bodies.
- Fixes #187.
|
|
- Likewise for the test.
|
|
- Use the anyhow crate instead of failure to implement the dynamic
side of our error handling. anyhow::Error derefs to dyn
std::error::Error, allowing better interoperability with other
stdlib-based error handling libraries.
- Fixes #444.
|
|
- See #405.
|
|
- See #405.
|
|
- The module contains only one exported item.
|
|
|
|
- This allows us to implement PartialEq and related traits more
selectively. See #93.
|
|
|
|
See https://github.com/rust-lang/rust/pull/65819. Warned against by
default since Rust 1.41.
Right now `into_iter` returns references to objects inside an array
rather than moving the values (as one would expect) so it makes sense to
use `iter()` or for-in-borrowed (which calls the same thing) to retain
the behaviour but make it less confusing.
|