Messages in this thread | | | From | Horia Geanta <> | Subject | Re: [PATCH 1/2] crypto: gcm - helper functions for assoclen/authsize check | Date | Fri, 26 Jul 2019 14:12:04 +0000 |
| |
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
| |