mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-24 09:34:24 +01:00
libwally: fix hmac_sha256 name clash.
This is a workaround; eventually libwally will be a nice shared library that we won't have to bundle, and clashing with internal symbols won't be a problem. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
1
libwally-core/1README
Normal file
1
libwally-core/1README
Normal file
@@ -0,0 +1 @@
|
||||
Stolen from 3b025127cbf11912f8b95e7ff3c905d74e8433ce, with hmac_256 -> hmac_256_internal to avoid name clash
|
||||
@@ -8,7 +8,7 @@
|
||||
#define SHA_T sha256
|
||||
#define SHA_CTX_MEMBER u32
|
||||
#define SHA_PRE(name) sha256 ## name
|
||||
#define HMAC_FUNCTION hmac_sha256
|
||||
#define HMAC_FUNCTION hmac_sha256_internal
|
||||
#define WALLY_HMAC_FUNCTION wally_hmac_sha256
|
||||
#include "hmac.inl"
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@ struct sha256;
|
||||
struct sha512;
|
||||
|
||||
/**
|
||||
* hmac_sha256 - Compute an HMAC using SHA-256
|
||||
* hmac_sha256_internal - Compute an HMAC using SHA-256
|
||||
*
|
||||
* @sha: Destination for the resulting HMAC.
|
||||
* @key: The key for the hash
|
||||
@@ -13,7 +13,7 @@ struct sha512;
|
||||
* @msg: The message to hash
|
||||
* @msg_len: The length of @msg in bytes.
|
||||
*/
|
||||
void hmac_sha256(struct sha256 *sha,
|
||||
void hmac_sha256_internal(struct sha256 *sha,
|
||||
const unsigned char *key, size_t key_len,
|
||||
const unsigned char *msg, size_t msg_len);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user