Sming Framework API
()
Toggle main menu visibility
Sming
Components
crypto
include
Crypto
Sha2.h
Go to the documentation of this file.
1
/****
2
* Sming Framework Project - Open Source framework for high efficiency native ESP8266 development.
3
* Created 2015 by Skurydin Alexey
4
* http://github.com/SmingHub/Sming
5
* All files of the Sming Core are provided under the LGPL v3 license.
6
*
7
* Sha2.h
8
*
9
****/
10
11
#pragma once
12
13
#include "
HashApi/sha2.h
"
14
#include "
HashEngine.h
"
15
#include "
HashContext.h
"
16
#include "
HmacContext.h
"
17
18
namespace
Crypto
19
{
20
CRYPTO_HASH_ENGINE_STD
(
Sha224
, sha224,
SHA224_SIZE
,
SHA224_STATESIZE
,
SHA224_BLOCKSIZE
);
21
CRYPTO_HASH_ENGINE_STD
(
Sha256
, sha256,
SHA256_SIZE
,
SHA256_STATESIZE
,
SHA256_BLOCKSIZE
);
22
CRYPTO_HASH_ENGINE_STD
(
Sha384
, sha384,
SHA384_SIZE
,
SHA384_STATESIZE
,
SHA384_BLOCKSIZE
);
23
CRYPTO_HASH_ENGINE_STD
(
Sha512
, sha512,
SHA512_SIZE
,
SHA512_STATESIZE
,
SHA512_BLOCKSIZE
);
24
25
/*
26
* Hash contexts
27
*/
28
29
using
Sha224
= HashContext<Sha224Engine>;
30
using
Sha256
= HashContext<Sha256Engine>;
31
using
Sha384
= HashContext<Sha384Engine>;
32
using
Sha512
= HashContext<Sha512Engine>;
33
34
/*
35
* HMAC contexts
36
*/
37
38
using
HmacSha224
=
HmacContext<Sha224>
;
39
using
HmacSha256
=
HmacContext<Sha256>
;
40
using
HmacSha384
=
HmacContext<Sha384>
;
41
using
HmacSha512
=
HmacContext<Sha512>
;
42
43
}
// namespace Crypto
SHA384_SIZE
#define SHA384_SIZE
Definition:
sha2.h:65
HmacContext.h
SHA224_BLOCKSIZE
#define SHA224_BLOCKSIZE
Definition:
sha2.h:25
SHA224_SIZE
#define SHA224_SIZE
Definition:
sha2.h:23
SHA256_SIZE
#define SHA256_SIZE
Definition:
sha2.h:43
SHA224_STATESIZE
#define SHA224_STATESIZE
Definition:
sha2.h:24
Crypto::Sha512
HashContext< Sha512Engine > Sha512
Definition:
Sha2.h:40
HashEngine.h
Crypto::Sha384
HashContext< Sha384Engine > Sha384
Definition:
Sha2.h:39
SHA384_BLOCKSIZE
#define SHA384_BLOCKSIZE
Definition:
sha2.h:67
HashContext.h
SHA512_STATESIZE
#define SHA512_STATESIZE
Definition:
sha2.h:93
SHA384_STATESIZE
#define SHA384_STATESIZE
Definition:
sha2.h:66
SHA256_BLOCKSIZE
#define SHA256_BLOCKSIZE
Definition:
sha2.h:45
Crypto::Sha224
HashContext< Sha224Engine > Sha224
Definition:
Sha2.h:37
Crypto::Sha256
HashContext< Sha256Engine > Sha256
Definition:
Sha2.h:38
Crypto
Definition:
Blake2s.h:18
sha2.h
SHA256_STATESIZE
#define SHA256_STATESIZE
Definition:
sha2.h:44
SHA512_SIZE
#define SHA512_SIZE
Definition:
sha2.h:92
Crypto::CRYPTO_HASH_ENGINE_STD
CRYPTO_HASH_ENGINE_STD(Md5, md5, MD5_SIZE, MD5_STATESIZE, MD5_BLOCKSIZE)
Crypto::HmacContext
HMAC class template.
Definition:
HmacContext.h:32
SHA512_BLOCKSIZE
#define SHA512_BLOCKSIZE
Definition:
sha2.h:94
Generated by
1.8.17