Struct sequoia_openpgp::packet::Unknown
source · pub struct Unknown { /* private fields */ }
Expand description
Holds an unknown packet.
This is used by the parser to hold packets that it doesn’t know how to process rather than abort.
This packet effectively holds a binary blob.
§A note on equality
Two Unknown
packets are considered equal if their tags and their
bodies are equal.
Implementations§
source§impl Unknown
impl Unknown
sourcepub fn hash_algo_security(&self) -> HashAlgoSecurity
pub fn hash_algo_security(&self) -> HashAlgoSecurity
The security requirements of the hash algorithm for self-signatures.
A cryptographic hash algorithm usually has three security properties: pre-image resistance, second pre-image resistance, and collision resistance. If an attacker can influence the signed data, then the hash algorithm needs to have both second pre-image resistance, and collision resistance. If not, second pre-image resistance is sufficient.
In general, an attacker may be able to influence third-party signatures. But direct key signatures, and binding signatures are only over data fully determined by signer. And, an attacker’s control over self signatures over User IDs is limited due to their structure.
These observations can be used to extend the life of a hash algorithm after its collision resistance has been partially compromised, but not completely broken. For more details, please refer to the documentation for HashAlgoSecurity.
Trait Implementations§
source§impl Any<Unknown> for Packet
impl Any<Unknown> for Packet
source§impl IntoIterator for Unknown
impl IntoIterator for Unknown
Implement IntoIterator
so that
cert::insert_packets(sig)
just works.