^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1) /* SPDX-License-Identifier: GPL-2.0-or-later */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 2) /*
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 3) * Hash Info: Hash algorithms information
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 4) *
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 5) * Copyright (c) 2013 Dmitry Kasatkin <d.kasatkin@samsung.com>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 6) */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 7)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 8) #ifndef _CRYPTO_HASH_INFO_H
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 9) #define _CRYPTO_HASH_INFO_H
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 10)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 11) #include <crypto/sha.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 12) #include <crypto/md5.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 13) #include <crypto/streebog.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 14)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 15) #include <uapi/linux/hash_info.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 16)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 17) /* not defined in include/crypto/ */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 18) #define RMD128_DIGEST_SIZE 16
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 19) #define RMD160_DIGEST_SIZE 20
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 20) #define RMD256_DIGEST_SIZE 32
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 21) #define RMD320_DIGEST_SIZE 40
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 22)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 23) /* not defined in include/crypto/ */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 24) #define WP512_DIGEST_SIZE 64
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 25) #define WP384_DIGEST_SIZE 48
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 26) #define WP256_DIGEST_SIZE 32
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 27)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 28) /* not defined in include/crypto/ */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 29) #define TGR128_DIGEST_SIZE 16
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 30) #define TGR160_DIGEST_SIZE 20
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 31) #define TGR192_DIGEST_SIZE 24
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 32)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 33) /* not defined in include/crypto/ */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 34) #define SM3256_DIGEST_SIZE 32
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 35)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 36) extern const char *const hash_algo_name[HASH_ALGO__LAST];
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 37) extern const int hash_digest_size[HASH_ALGO__LAST];
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 38)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 39) #endif /* _CRYPTO_HASH_INFO_H */