pub struct Profile<'a> { /* private fields */ }Expand description
A recognized MGF1 profile, not provider capability or signature validity.
The two digests are independent. Salt remains an original arbitrary-width INTEGER (or the schema default), not a platform-sized backend parameter. Only trailer 1 is recognized; its original written/default form is retained.
Implementations§
Source§impl<'a> Profile<'a>
impl<'a> Profile<'a>
Sourcepub fn element(self) -> Element<'a>
pub fn element(self) -> Element<'a>
Original parameter SEQUENCE; no canonical representation is fabricated.
Sourcepub fn salt(self) -> Number<'a>
pub fn salt(self) -> Number<'a>
Original salt octet count; no modulus or provider maximum is imposed.
Sourcepub fn allows<W: Work>(&self, signature: &Self, execution: &W) -> Result<bool>
pub fn allows<W: Work>(&self, signature: &Self, execution: &W) -> Result<bool>
Whether signature satisfies this present key profile.
RFC4055 §3.3 requires identical message/MGF digests and trailer, but signature salt >= key minimum, not equality. Both original source ceilings and current work apply, even for a cheap digest mismatch. Arbitrary-width nonnegative integers compare without truncation. This checks restrictions only, not key validity, provider support, modulus feasibility, policy, or signature mathematics. https://www.rfc-editor.org/rfc/rfc4055#section-3.3
§Errors
A located terminal resource refusal before comparison.