1 //********************************************************************************** 2 //LibEncryptMsg Copyright 2018 Evgeny Pokhilko 3 //<https://evpo.net/libencryptmsg> 4 // 5 //LibEncryptMsg is released under the Simplified BSD License (see license.txt) 6 //********************************************************************************** 7 8 #pragma once 9 #include <string> 10 11 namespace EncryptMsg 12 { 13 enum class Compression 14 { 15 Unknown = -1, 16 Uncompressed = 0, 17 ZIP = 1, 18 ZLIB = 2, 19 BZip2 = 3, 20 }; 21 22 enum class CipherAlgo 23 { 24 Unknown = -1, 25 TripleDES = 2, 26 CAST5 = 3, 27 AES128 = 7, 28 AES192 = 8, 29 AES256 = 9, 30 Twofish = 10, 31 Camellia128 = 11, 32 Camellia192 = 12, 33 Camellia256 = 13, 34 }; 35 36 enum class HashAlgo 37 { 38 Unknown = -1, 39 SHA160 = 2, 40 SHA256 = 8, 41 SHA384 = 9, 42 SHA512 = 10, 43 SHA224 = 11, 44 }; 45 46 struct AlgoSpec 47 { 48 CipherAlgo cipher_algo; 49 std::string botan_name; 50 unsigned block_size; 51 unsigned key_size; 52 }; 53 54 struct HashSpec 55 { 56 HashAlgo hash_algo; 57 std::string botan_name; 58 }; 59 60 struct CompressionSpec 61 { 62 Compression compression; 63 std::string botan_name; 64 }; 65 66 const AlgoSpec &GetAlgoSpec(CipherAlgo cipher_algo); 67 const HashSpec &GetHashSpec(HashAlgo hash_algo); 68 const CompressionSpec &GetCompressionSpec(Compression compression); 69 } 70