Generate HMAC SHA256 hash using key in C++

RDoonds

I am looking for some function or a way that would return HMAC SHA256 hash in C++ using secret key. I have seen documentation of Crypto++ and OpenSSL but it does not accept an extra parameter of secret key for computation. Can someone help me by providing some info, code snippets or links.

user2797321

OpenSSL docs for HMAC, clearly state the requirement of a 'key' as part of context initialization.

int HMAC_Init_ex(HMAC_CTX *ctx, const void *key, int key_len,
               const EVP_MD *md, ENGINE *impl);

HMAC() computes the message authentication code of the n bytes at d using the hash function evp_md and the key key which is key_len bytes long.

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

Need to generate HMAC SHA256 hash in Objective C as in Java

HMAC SHA256 hash computation in C#

Generate HMAC-SHA256 hash with BouncyCastle

How to replicate hash_hmac('sha256', $key, $secret_key) function in Swift 4?

CryptoJS and Crypto (nodejs) won't generate the same HMAC SHA256 hash

Creating a HMAC SHA256 hash in PowerShell

Generate HMAC SHA256 signature Python

Generate HMAC SHA256 signature Powershell

Generate HMAC SHA Algorithm using URI and Key

Generate a hashed message with SHA256 hmac in php (key & msg are fake)

creating a HMAC SHA256 key in python

The value of hash_hmac sha256 has different value using different post procedures

using cryptojs to generate RFC 2104-compliant HMAC with SHA256 algorithm

Using HMAC SHA256 in Ruby

HMAC SHA256, inner hash works but outer hash fails

sha256 hash from public key

Port JS crypto code for hash HMAC SHA256 to PHP

Android Java and PHP HASH HMAC SHA256 different result

How to generate random number between 0 and 1 using a sha256 hash

How to HMAC SHA256 sign a string with a double array key or an hex string key using google apps script?

Hmac with SHa256 Or SHa256 with key appended in the input string? Which is more secure?

typescript crypto-js how to hash data using sha256 algorithm and key

How to encrypt using AES with sha256 hash as key crypto++

Sha256 hash in Objective C and Java

SHA256 Hash calculation in C++

Java mac sha256 hashing does not match with php hmac sha256 using pack?

SHA256 HMAC using OpenSSL 1.1 not compiling

HMAC and SHA256 - how to validate using nonce

How to generate SHA1, SHA256, MD5 for default debug key using keytool in Mac, Windows and Linux?

TOP Ranking

HotTag

Archive