Re: [PATCH v3 05/14] PGPLIB: Signature parser

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed Sep 11, 2024 at 3:29 PM EEST, Roberto Sassu wrote:
> From: David Howells <dhowells@xxxxxxxxxx>
>
> Provide some PGP signature parsing helpers:
>
>  (1) A function to parse V4 signature subpackets and pass the desired ones
>      to a processor function:
>
> 	int pgp_parse_sig_subpkts(const u8 *data, size_t datalen,
> 				  struct pgp_parse_sig_context *ctx);
>
>  (2) A function to parse out basic signature parameters from any PGP
>      signature such that the algorithms and public key can be selected:
>
> 	int pgp_parse_sig_params(const u8 **_data, size_t *_datalen,
> 				 struct pgp_sig_parameters *p);
>
> Signed-off-by: David Howells <dhowells@xxxxxxxxxx>
> Co-developed-by: Roberto Sassu <roberto.sassu@xxxxxxxxxx>
> Signed-off-by: Roberto Sassu <roberto.sassu@xxxxxxxxxx>
> ---
>  crypto/asymmetric_keys/pgp_library.c | 284 +++++++++++++++++++++++++++
>  crypto/asymmetric_keys/pgplib.h      |  25 +++
>  2 files changed, 309 insertions(+)
>
> diff --git a/crypto/asymmetric_keys/pgp_library.c b/crypto/asymmetric_keys/pgp_library.c
> index 1b87f8af411b..a9708ccbcb81 100644
> --- a/crypto/asymmetric_keys/pgp_library.c
> +++ b/crypto/asymmetric_keys/pgp_library.c
> @@ -260,3 +260,287 @@ int pgp_parse_public_key(const u8 **_data, size_t *_datalen,
>  	return 0;
>  }
>  EXPORT_SYMBOL_GPL(pgp_parse_public_key);
> +
> +/**
> + * pgp_parse_sig_subpkt_header - Parse a PGP V4 signature subpacket header
                                 ()

BR, Jarkko





[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux Kernel]     [Linux Kernel Hardening]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux SCSI]

  Powered by Linux