aboutsummaryrefslogtreecommitdiffstats
path: root/checks
diff options
context:
space:
mode:
authorlloyd <[email protected]>2012-04-25 13:48:08 +0000
committerlloyd <[email protected]>2012-04-25 13:48:08 +0000
commitb72a44475d06263e1492f8913310b5f29515cba6 (patch)
tree680752dbd43999cea16851b9c196046d9e5fbd7f /checks
parentedca5f211722ea6b9d99b8b5fce4603a1b9b422d (diff)
parentf14a9fdee7902ba1a4c962cfbabe29d5146e7c55 (diff)
propagate from branch 'net.randombit.botan.tls-state-machine' (head a4741cd07f50a9e1b29b0dd97c6fb8697c038ade)
to branch 'net.randombit.botan.cxx11' (head 116e5ff139c07000be431e07d3472cc8f3919b91)
Diffstat (limited to 'checks')
-rw-r--r--checks/bench.cpp12
-rw-r--r--checks/pk.cpp6
-rw-r--r--checks/pk_bench.cpp6
-rw-r--r--checks/validate.cpp4
-rw-r--r--checks/validate.dat22
5 files changed, 27 insertions, 23 deletions
diff --git a/checks/bench.cpp b/checks/bench.cpp
index b6bf93377..5faba00db 100644
--- a/checks/bench.cpp
+++ b/checks/bench.cpp
@@ -153,18 +153,6 @@ void report_results(const std::string& algo,
std::cout << algo;
-#if defined(__SUNPRO_CC)
- #define REVERSE_ITERATOR_BUG 1
-#elif defined(__GNUC__) && __GNUC__ <= 3
- #define REVERSE_ITERATOR_BUG 1
-#elif defined(__GNUC__) && (__GNUC__ == 4 && __GNUC_MINOR__ == 0)
- #define REVERSE_ITERATOR_BUG 1
-#endif
-
-#ifndef REVERSE_ITERATOR_BUG
- #define REVERSE_ITERATOR_BUG 0
-#endif
-
#if (defined(__GNUC__) && __GNUC__ <= 3) || defined(__SUNPRO_CC)
// Work around GCC 3.x bug, reverse iterators don't work
for(std::map<double, std::string>::const_iterator i = results.begin(); i != results.end(); ++i)
diff --git a/checks/pk.cpp b/checks/pk.cpp
index e11578523..e06efb3ea 100644
--- a/checks/pk.cpp
+++ b/checks/pk.cpp
@@ -14,6 +14,12 @@
#include <botan/botan.h>
#include <botan/oids.h>
+#if defined(BOTAN_HAS_PUBLIC_KEY_CRYPTO)
+ #include <botan/x509_key.h>
+ #include <botan/pkcs8.h>
+ #include <botan/pubkey.h>
+#endif
+
#if defined(BOTAN_HAS_RSA)
#include <botan/rsa.h>
#endif
diff --git a/checks/pk_bench.cpp b/checks/pk_bench.cpp
index 449ff7730..ab4702dba 100644
--- a/checks/pk_bench.cpp
+++ b/checks/pk_bench.cpp
@@ -10,6 +10,12 @@
#include <botan/oids.h>
#include <map>
+#if defined(BOTAN_HAS_PUBLIC_KEY_CRYPTO)
+ #include <botan/x509_key.h>
+ #include <botan/pkcs8.h>
+ #include <botan/pubkey.h>
+#endif
+
#if defined(BOTAN_HAS_RSA)
#include <botan/rsa.h>
#endif
diff --git a/checks/validate.cpp b/checks/validate.cpp
index 65317604e..2bb099030 100644
--- a/checks/validate.cpp
+++ b/checks/validate.cpp
@@ -110,6 +110,7 @@ bool keywrap_test(const char* key_str,
bool ok = true;
+#if defined(BOTAN_HAS_RFC3394_KEYWRAP)
try
{
SymmetricKey key(key_str);
@@ -140,6 +141,7 @@ bool keywrap_test(const char* key_str,
{
std::cout << e.what() << "\n";
}
+#endif
return ok;
}
@@ -339,7 +341,7 @@ u32bit do_validation_tests(const std::string& filename,
if(should_pass)
std::cout << "Testing " << algorithm << "..." << std::endl;
else
- std::cout << "Testing (expecing failure) "
+ std::cout << "Testing (expecting failure) "
<< algorithm << "..." << std::endl;
#endif
alg_count = 0;
diff --git a/checks/validate.dat b/checks/validate.dat
index 7b8588aac..f440bb293 100644
--- a/checks/validate.dat
+++ b/checks/validate.dat
@@ -4123,26 +4123,28 @@ F0E1D2C3B4A5968778695A4B3C2D1E0F00112233445566
FEDCBA9876543210:05044B62FA52D080:\
F0E1D2C3B4A5968778695A4B3C2D1E0F0011223344556677
-[Camellia]
+[Camellia-128]
# From RFC 3713
-
0123456789ABCDEFFEDCBA9876543210:67673138549669730857065648EABE43:\
0123456789ABCDEFFEDCBA9876543210
-0123456789ABCDEFFEDCBA9876543210:B4993401B3E996F84EE5CEE7D79B09B9:\
-0123456789ABCDEFFEDCBA98765432100011223344556677
-
-0123456789ABCDEFFEDCBA9876543210:9ACC237DFF16D76C20EF7C919E3A7509:\
-0123456789ABCDEFFEDCBA987654321000112233445566778899AABBCCDDEEFF
-
-# From NESSIE
-
+# Nessie
00000000000000000000000000000000:6C227F749319A3AA7DA235A9BBA05A2C:\
80000000000000000000000000000000
FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF:25DD9EB9DD67FBC6E8431F56F4FBE651:\
FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
+[Camellia-192]
+# From RFC 3713
+0123456789ABCDEFFEDCBA9876543210:B4993401B3E996F84EE5CEE7D79B09B9:\
+0123456789ABCDEFFEDCBA98765432100011223344556677
+
+[Camellia-256]
+# From RFC 3713
+0123456789ABCDEFFEDCBA9876543210:9ACC237DFF16D76C20EF7C919E3A7509:\
+0123456789ABCDEFFEDCBA987654321000112233445566778899AABBCCDDEEFF
+
# First one is from RFC 2144. The rest were done with OpenSSL and bits taken
# from /dev/urandom
[CAST-128]