all repos — TinyCrypT @ 137f9bc2c13de246bd5aac4161e0e7c4e50f12eb

Short and sweet classical cryptographic primitives

tinycrypt/sha2.h (view raw)

 1
 2
 3
 4
 5
 6
 7
 8
 9
 10
 11
 12
#ifndef TCT_SHA2_H
#define TCT_SHA2_H

#include <stdint.h>

/// Implements the NIST SHA-256 algorithm
void tct_sha256 (const uint8_t *data, uint64_t data_len, uint8_t *hash_out);

/// Implements the NIST SHA-512 algorithm
void tct_sha512 (const uint8_t *data, uint64_t data_len, uint8_t *hash_out);

#endif