Source-Changes-HG archive

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

[src/trunk]: src/crypto/external/bsd/openssl.old/dist/crypto/hmac provide com...



details:   https://anonhg.NetBSD.org/src/rev/d106acdd96f3
branches:  trunk
changeset: 359219:d106acdd96f3
user:      christos <christos%NetBSD.org@localhost>
date:      Mon Feb 05 00:42:46 2018 +0000

description:
provide compatibility for libradius

diffstat:

 crypto/external/bsd/openssl.old/dist/crypto/hmac/hmac.h |  18 +++++++++++++++++
 1 files changed, 18 insertions(+), 0 deletions(-)

diffs (28 lines):

diff -r 500df916eb58 -r d106acdd96f3 crypto/external/bsd/openssl.old/dist/crypto/hmac/hmac.h
--- a/crypto/external/bsd/openssl.old/dist/crypto/hmac/hmac.h   Mon Feb 05 00:13:50 2018 +0000
+++ b/crypto/external/bsd/openssl.old/dist/crypto/hmac/hmac.h   Mon Feb 05 00:42:46 2018 +0000
@@ -102,6 +102,24 @@
 
 void HMAC_CTX_set_flags(HMAC_CTX *ctx, unsigned long flags);
 
+static inline HMAC_CTX *HMAC_CTX_new(void)
+{
+       HMAC_CTX *ctx = malloc(sizeof(*ctx));
+       if (ctx == NULL)
+               return NULL;
+       HMAC_CTX_init(ctx);
+       return ctx;
+}
+
+static inline void HMAC_CTX_free(HMAC_CTX *ctx)
+{
+       if (ctx == NULL)
+               return;
+       HMAC_CTX_cleanup(ctx);
+       free(ctx);
+}
+
+
 #ifdef  __cplusplus
 }
 #endif



Home | Main Index | Thread Index | Old Index