Re: [PATCH 1/2] crypto: gcm - helper functions for assoclen/authsize check

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

 



On 7/25/2019 4:47 PM, Iuliana Prodan wrote:
> Added inline helper functions to check authsize and assoclen for
> gcm and rfc4106.
Also rfc4543.

> diff --git a/include/crypto/gcm.h b/include/crypto/gcm.h
> index c50e057..9834b97 100644
> --- a/include/crypto/gcm.h
> +++ b/include/crypto/gcm.h
> @@ -5,4 +5,57 @@
>  #define GCM_RFC4106_IV_SIZE 8
>  #define GCM_RFC4543_IV_SIZE 8
>  
> +/*
> + * validate authentication tag for GCM
> + */
> +static inline int check_gcm_authsize(unsigned int authsize)
I'd prefix the helper names with crypto_

Horia




[Index of Archives]     [Kernel]     [Gnu Classpath]     [Gnu Crypto]     [DM Crypt]     [Netfilter]     [Bugtraq]

  Powered by Linux