Skip to main content

Module pkcs1v15

Module pkcs1v15 

Source
Expand description

PKCS#1 v1.5 support as described in RFC8017 ยง 8.2.

ยงUsage

See code example in the toplevel rustdoc.

Modulesยง

implicit_rejection ๐Ÿ”’
Deterministic fallback derivation from draft-irtf-cfrg-rsa-guidance-10 ยง7.1โ€“7.2.
selection ๐Ÿ”’
Side-channel-free decoding and selection for draft-irtf-cfrg-rsa-guidance-10 ยง7.2.

Functionsยง

non_zero_random_bytes ๐Ÿ”’
Fills the provided slice with random values, which are guaranteed to not be zero.
pkcs1v15_encrypt_pad ๐Ÿ”’
Applied the padding scheme from PKCS#1 v1.5 for encryption. The message must be no longer than the length of the public modulus minus 11 bytes.
pkcs1v15_generate_prefix ๐Ÿ”’
prefix = 0x30 <oid_len + 8 + digest_len> 0x30 <oid_len + 4> 0x06 <oid_len> oid 0x05 0x00 0x04 <digest_len>
pkcs1v15_sign_pad ๐Ÿ”’
pkcs1v15_sign_unpad ๐Ÿ”’