1 /* LibTomCrypt, modular cryptographic library -- Tom St Denis
3 * LibTomCrypt is a library that provides various cryptographic
4 * algorithms in a highly modular and flexible manner.
6 * The library is free for all purposes without any express
21 /* use configuration data */
22 #include <tomcrypt_custom.h>
30 #define SCRYPT "1.18.2"
32 /* max size of either a cipher/hash block or symmetric key [largest of the two] */
33 #define MAXBLOCKSIZE 128
36 /* descriptor table size */
40 /* error codes [will be expanded in future releases] */
42 CRYPT_OK=0, /* Result OK */
43 CRYPT_ERROR, /* Generic Error */
44 CRYPT_NOP, /* Not a failure but no operation was performed */
46 CRYPT_INVALID_KEYSIZE, /* Invalid key size given */
47 CRYPT_INVALID_ROUNDS, /* Invalid number of rounds */
48 CRYPT_FAIL_TESTVECTOR, /* Algorithm failed test vectors */
50 CRYPT_BUFFER_OVERFLOW, /* Not enough space for output */
51 CRYPT_INVALID_PACKET, /* Invalid input packet given */
53 CRYPT_INVALID_PRNGSIZE, /* Invalid number of bits for a PRNG */
54 CRYPT_ERROR_READPRNG, /* Could not read enough from PRNG */
56 CRYPT_INVALID_CIPHER, /* Invalid cipher specified */
57 CRYPT_INVALID_HASH, /* Invalid hash specified */
58 CRYPT_INVALID_PRNG, /* Invalid PRNG specified */
60 CRYPT_MEM, /* Out of memory */
62 CRYPT_PK_TYPE_MISMATCH, /* Not equivalent types of PK keys */
63 CRYPT_PK_NOT_PRIVATE, /* Requires a private PK key */
65 CRYPT_INVALID_ARG, /* Generic invalid argument */
66 CRYPT_FILE_NOTFOUND, /* File Not Found */
68 CRYPT_PK_INVALID_TYPE, /* Invalid type of PK key */
70 CRYPT_OVERFLOW, /* An overflow of a value was detected/prevented */
72 CRYPT_UNUSED1, /* UNUSED1 */
74 CRYPT_INPUT_TOO_LONG, /* The input was longer than expected. */
76 CRYPT_PK_INVALID_SIZE, /* Invalid size input for PK parameters */
78 CRYPT_INVALID_PRIME_SIZE,/* Invalid size of prime requested */
79 CRYPT_PK_INVALID_PADDING, /* Invalid padding on input */
81 CRYPT_HASH_OVERFLOW /* Hash applied to too many bits */
84 #include <tomcrypt_cfg.h>
85 #include <tomcrypt_macros.h>
86 #include <tomcrypt_cipher.h>
87 #include <tomcrypt_hash.h>
88 #include <tomcrypt_mac.h>
89 #include <tomcrypt_prng.h>
90 #include <tomcrypt_pk.h>
91 #include <tomcrypt_math.h>
92 #include <tomcrypt_misc.h>
93 #include <tomcrypt_argchk.h>
94 #include <tomcrypt_pkcs.h>
100 #endif /* TOMCRYPT_H_ */
103 /* ref: $Format:%D$ */
104 /* git commit: $Format:%H$ */
105 /* commit time: $Format:%ai$ */