diff options
author | Nora Widdecke <nora@sequoia-pgp.org> | 2021-08-24 12:54:16 +0200 |
---|---|---|
committer | Nora Widdecke <nora@sequoia-pgp.org> | 2021-08-27 12:58:07 +0200 |
commit | 83e6668ed4b5692a0a52174031f99c1e76726f77 (patch) | |
tree | 14f455534e38c79df895d8abf9dac424fe3bbce0 /openpgp/src/parse | |
parent | e5746684e84377dd8828f6a5a8ab4c0eec73c3ec (diff) |
ffi, openpgp: Cleanup links after cargo intraconv.
- openpgp: Make broken relative links absolute:
- find -name "*.rs" -exec sed -i -E 's,^( *//[/!](.*): )((super::)+packet),\1crate::packet,' {} +
- find -name "*.rs" -exec sed -i -E 's,^( *//[/!](.*): )((super::)+cert),\1crate::cert,' {} +
- find -name "*.rs" -exec sed -i -E 's,^( *//[/!](.*): )((super::)+parse),\1crate::parse,' {} +
- find -name "*.rs" -exec sed -i -E 's,^( *//[/!](.*): )((super::)+policy),\1crate::policy,' {} +
- find -name "*.rs" -exec sed -i -E 's,^( *//[/!](.*): )((super::)+serialize),\1crate::serialize,' {} +
- find -name "*.rs" -exec sed -i -E 's,^( *//[/!](.*): )((super::)+armor),\1crate::armor,' {} +
- find -name "*.rs" -exec sed -i -E 's,^( *//[/!](.*): )((super::)+types),\1crate::types,' {} +
- find -name "*.rs" -exec sed -i -E 's,^( *//[/!] *(\[`PacketPile`\]):).*$,\1 crate::PacketPile,' {} +
- openpgp: Link to PacketParser and Policy structs, not the modules.
- ffi: Make links to sequoia_openpgp and sequoia_net absolute
- find -name "*.rs" -exec sed -i -E 's,^( *//[/!](.*): )((super::)+sequoia_openpgp),\1sequoia_openpgp,' {} +
- find -name "*.rs" -exec sed -i -E 's,^( *//[/!](.*): )((super::)+sequoia_net),\1sequoia_net,' {} +
Diffstat (limited to 'openpgp/src/parse')
-rw-r--r-- | openpgp/src/parse/hashed_reader.rs | 2 | ||||
-rw-r--r-- | openpgp/src/parse/packet_parser_builder.rs | 12 | ||||
-rw-r--r-- | openpgp/src/parse/packet_pile_parser.rs | 2 | ||||
-rw-r--r-- | openpgp/src/parse/stream.rs | 16 |
4 files changed, 17 insertions, 15 deletions
diff --git a/openpgp/src/parse/hashed_reader.rs b/openpgp/src/parse/hashed_reader.rs index 732a1b5a..7dc02a65 100644 --- a/openpgp/src/parse/hashed_reader.rs +++ b/openpgp/src/parse/hashed_reader.rs @@ -357,7 +357,7 @@ impl<R: BufferedReader<Cookie>> /// This can be used to verify detached signatures. For a more /// convenient method, see [`DetachedVerifier`]. /// -/// [`DetachedVerifier`]: super::parse::stream::DetachedVerifier +/// [`DetachedVerifier`]: crate::parse::stream::DetachedVerifier pub(crate) fn hash_buffered_reader<R>(reader: R, algos: &[HashingMode<HashAlgorithm>]) -> Result<Vec<HashingMode<Box<dyn crate::crypto::hash::Digest>>>> diff --git a/openpgp/src/parse/packet_parser_builder.rs b/openpgp/src/parse/packet_parser_builder.rs index 2a6df2c2..7459f0be 100644 --- a/openpgp/src/parse/packet_parser_builder.rs +++ b/openpgp/src/parse/packet_parser_builder.rs @@ -33,7 +33,7 @@ pub enum Dearmor { /// fail. The [`ReaderMode`] allow further customization of the /// ASCII armor parser. /// - /// [`ReaderMode`]: super::armor::ReaderMode + /// [`ReaderMode`]: crate::armor::ReaderMode Enabled(armor::ReaderMode), /// Unconditionally treat the input as if it were a binary OpenPGP /// message. @@ -47,7 +47,7 @@ pub enum Dearmor { /// This is the default. The [`ReaderMode`] allow further /// customization of the ASCII armor parser. /// - /// [`ReaderMode`]: super::armor::ReaderMode + /// [`ReaderMode`]: crate::armor::ReaderMode Auto(armor::ReaderMode), } assert_send_and_sync!(Dearmor); @@ -149,6 +149,7 @@ impl<'a> PacketParserBuilder<'a> { /// sense. The default is [`DEFAULT_MAX_RECURSION_DEPTH`]. /// (GnuPG defaults to a maximum recursion depth of 32.) /// + /// [`DEFAULT_MAX_RECURSION_DEPTH`]: crate::parse::DEFAULT_MAX_RECURSION_DEPTH /// /// # Examples /// @@ -190,6 +191,7 @@ impl<'a> PacketParserBuilder<'a> { /// /// The default is [`DEFAULT_MAX_PACKET_SIZE`]. /// + /// [`DEFAULT_MAX_PACKET_SIZE`]: crate::parse::DEFAULT_MAX_PACKET_SIZE /// /// # Examples /// @@ -239,9 +241,9 @@ impl<'a> PacketParserBuilder<'a> { /// The unread content can be accessed using [`Literal::body`], /// [`Unknown::body`], or [`Container::body`]. /// - /// [`Literal::body`]: super::packet::Literal::body() - /// [`Unknown::body`]: super::packet::Unknown::body() - /// [`Container::body`]: super::packet::Container::body() + /// [`Literal::body`]: crate::packet::Literal::body() + /// [`Unknown::body`]: crate::packet::Unknown::body() + /// [`Container::body`]: crate::packet::Container::body() /// /// # Examples /// diff --git a/openpgp/src/parse/packet_pile_parser.rs b/openpgp/src/parse/packet_pile_parser.rs index 4bdbe08a..22b1f82f 100644 --- a/openpgp/src/parse/packet_pile_parser.rs +++ b/openpgp/src/parse/packet_pile_parser.rs @@ -29,7 +29,7 @@ use buffered_reader::BufferedReader; /// [`PacketParser`]), it allows the caller to inspect each packet as /// it is being parsed. /// -/// [`PacketPile`]: super::PacketPile +/// [`PacketPile`]: crate::PacketPile /// /// Thus, using a `PacketPileParser`, it is possible to decide on a /// per-packet basis whether to stream, buffer or drop the packet's diff --git a/openpgp/src/parse/stream.rs b/openpgp/src/parse/stream.rs index e2d16f01..a554e8c3 100644 --- a/openpgp/src/parse/stream.rs +++ b/openpgp/src/parse/stream.rs @@ -34,8 +34,8 @@ //! use a cached session key, or one that has been explicitly provided //! to the decryption operation. //! -//! [`PKESK`]: super::super::packet::PKESK -//! [`SKESK`]: super::super::packet::SKESK +//! [`PKESK`]: crate::packet::PKESK +//! [`SKESK`]: crate::packet::SKESK //! //! The [`Verifier`] and [`Decryptor`] are filters: they consume //! OpenPGP data from a reader, file, or bytes, and implement @@ -417,7 +417,7 @@ impl<'a> VerificationErrorInternal<'a> { /// [`Signature::level`]. /// /// [Section 11.3 of RFC 4880]: https://tools.ietf.org/html/rfc4880#section-11.3 -/// [`Signature::level`]: super::super::packet::Signature::level() +/// [`Signature::level`]: crate::packet::Signature#method.level /// /// Consider the following structure. This is a set of notarizing /// signatures *N* over a set of signatures *S* over the literal data: @@ -904,7 +904,7 @@ impl<V: VerificationHelper> DecryptionHelper for NoDecryptionHelper<V> { /// seen a positive verification. See [`Verifier::message_processed`] /// for more information. /// -/// [`Verifier::message_processed`]: MessageStructure::message_processed() +/// [`Verifier::message_processed`]: Verifier::message_processed() /// /// See [`GoodChecksum`] for what it means for a signature to be /// considered valid. @@ -1634,7 +1634,7 @@ enum Mode { /// positive verification. See [`Decryptor::message_processed`] for /// more information. /// -/// [`Decryptor::message_processed`]: MessageStructure::message_processed() +/// [`Decryptor::message_processed`]: Decryptor::message_processed() /// /// See [`GoodChecksum`] for what it means for a signature to be /// considered valid. @@ -2016,13 +2016,13 @@ pub trait DecryptionHelper { /// and session key. `decrypt` returns `true` if the decryption /// was successful. /// - /// [`PKESK`]: super::super::packet::PKESK - /// [`SKESK`]: super::super::packet::SKESK + /// [`PKESK`]: crate::packet::PKESK + /// [`SKESK`]: crate::packet::SKESK /// /// If a symmetric algorithm is given, it should be passed on to /// [`PKESK::decrypt`]. /// - /// [`PKESK::decrypt`]: super::super::packet::PKESK::decrypt() + /// [`PKESK::decrypt`]: crate::packet::PKESK#method.decrypt /// /// If the message is decrypted using a [`PKESK`] packet, then the /// fingerprint of the certificate containing the encryption |