summaryrefslogtreecommitdiff
path: root/libtomcrypt/src/headers
diff options
context:
space:
mode:
Diffstat (limited to 'libtomcrypt/src/headers')
-rw-r--r--libtomcrypt/src/headers/tomcrypt.h7
-rw-r--r--libtomcrypt/src/headers/tomcrypt_argchk.h2
-rw-r--r--libtomcrypt/src/headers/tomcrypt_custom.h11
-rw-r--r--libtomcrypt/src/headers/tomcrypt_dropbear.h16
-rw-r--r--libtomcrypt/src/headers/tomcrypt_pk.h16
5 files changed, 34 insertions, 18 deletions
diff --git a/libtomcrypt/src/headers/tomcrypt.h b/libtomcrypt/src/headers/tomcrypt.h
index 1a56611..f4442d2 100644
--- a/libtomcrypt/src/headers/tomcrypt.h
+++ b/libtomcrypt/src/headers/tomcrypt.h
@@ -27,14 +27,15 @@ extern "C" {
/* version */
#define CRYPT 0x0118
-#define SCRYPT "1.18.1"
+#define SCRYPT "1.18.2"
/* max size of either a cipher/hash block or symmetric key [largest of the two] */
#define MAXBLOCKSIZE 128
+#ifndef TAB_SIZE
/* descriptor table size */
-/* Dropbear change - this should be smaller, saves some size */
-#define TAB_SIZE 5
+#define TAB_SIZE 32
+#endif
/* error codes [will be expanded in future releases] */
enum {
diff --git a/libtomcrypt/src/headers/tomcrypt_argchk.h b/libtomcrypt/src/headers/tomcrypt_argchk.h
index 3994aa2..8bd3653 100644
--- a/libtomcrypt/src/headers/tomcrypt_argchk.h
+++ b/libtomcrypt/src/headers/tomcrypt_argchk.h
@@ -45,7 +45,7 @@ void crypt_argchk(const char *v, const char *s, int d) NORETURN;
#elif ARGTYPE == 3
-#define LTC_ARGCHK(x)
+#define LTC_ARGCHK(x)
#define LTC_ARGCHKVD(x) LTC_ARGCHK(x)
#elif ARGTYPE == 4
diff --git a/libtomcrypt/src/headers/tomcrypt_custom.h b/libtomcrypt/src/headers/tomcrypt_custom.h
index f2351da..8fb9df8 100644
--- a/libtomcrypt/src/headers/tomcrypt_custom.h
+++ b/libtomcrypt/src/headers/tomcrypt_custom.h
@@ -74,8 +74,8 @@
#define LTC_NO_MODES
#define LTC_NO_HASHES
#define LTC_NO_MACS
- #define LTC_NO_PRNGS
- #define LTC_NO_PK
+ #define LTC_NO_PRNGS
+ #define LTC_NO_PK
#define LTC_NO_PKCS
#define LTC_NO_MISC
#endif /* LTC_NOTHING */
@@ -480,6 +480,13 @@
#endif
#endif
+#if defined(LTC_DER)
+ #ifndef LTC_DER_MAX_RECURSION
+ /* Maximum recursion limit when processing nested ASN.1 types. */
+ #define LTC_DER_MAX_RECURSION 30
+ #endif
+#endif
+
#if defined(LTC_MECC) || defined(LTC_MRSA) || defined(LTC_MDSA) || defined(LTC_MKAT)
/* Include the MPI functionality? (required by the PK algorithms) */
#define LTC_MPI
diff --git a/libtomcrypt/src/headers/tomcrypt_dropbear.h b/libtomcrypt/src/headers/tomcrypt_dropbear.h
index b0ce45b..3e24ea2 100644
--- a/libtomcrypt/src/headers/tomcrypt_dropbear.h
+++ b/libtomcrypt/src/headers/tomcrypt_dropbear.h
@@ -10,9 +10,9 @@
#define LTC_SMALL_CODE
#endif
-#if DROPBEAR_BLOWFISH
-#define LTC_BLOWFISH
-#endif
+/* Fewer entries needed */
+#define TAB_SIZE 5
+
#if DROPBEAR_AES
#define LTC_RIJNDAEL
#endif
@@ -27,7 +27,7 @@
#define LTC_DES
#endif
-#if DROPBEAR_ENABLE_CTR_MODE
+#if DROPBEAR_ENABLE_CBC_MODE
#define LTC_CBC_MODE
#endif
@@ -35,6 +35,14 @@
#define LTC_CTR_MODE
#endif
+#if DROPBEAR_ENABLE_GCM_MODE
+#define LTC_GCM_MODE
+#endif
+
+#if DROPBEAR_CHACHA20POLY1305
+#define LTC_CHACHA
+#define LTC_POLY1305
+#endif
#if DROPBEAR_SHA512
#define LTC_SHA512
diff --git a/libtomcrypt/src/headers/tomcrypt_pk.h b/libtomcrypt/src/headers/tomcrypt_pk.h
index 4ea6f88..fb9b07c 100644
--- a/libtomcrypt/src/headers/tomcrypt_pk.h
+++ b/libtomcrypt/src/headers/tomcrypt_pk.h
@@ -667,16 +667,16 @@ int der_printable_value_decode(int v);
/* UTF-8 */
#if (defined(SIZE_MAX) || __STDC_VERSION__ >= 199901L || defined(WCHAR_MAX) || defined(__WCHAR_MAX__) || defined(_WCHAR_T) || defined(_WCHAR_T_DEFINED) || defined (__WCHAR_TYPE__)) && !defined(LTC_NO_WCHAR)
-#include <wchar.h>
-#if defined(__WCHAR_MAX__)
-#define LTC_WCHAR_MAX __WCHAR_MAX__
-#elif defined(WCHAR_MAX)
-#define LTC_WCHAR_MAX WCHAR_MAX
-#endif
+ #if defined(__WCHAR_MAX__)
+ #define LTC_WCHAR_MAX __WCHAR_MAX__
+ #else
+ #include <wchar.h>
+ #define LTC_WCHAR_MAX WCHAR_MAX
+ #endif
/* please note that it might happen that LTC_WCHAR_MAX is undefined */
#else
-typedef ulong32 wchar_t;
-#define LTC_WCHAR_MAX 0xFFFFFFFF
+ typedef ulong32 wchar_t;
+ #define LTC_WCHAR_MAX 0xFFFFFFFF
#endif
int der_encode_utf8_string(const wchar_t *in, unsigned long inlen,