]> git.ipfire.org Git - thirdparty/gnutls.git/commitdiff
added (dead) code to test the _hmac_fast.
authorNikos Mavrogiannopoulos <nmav@gnutls.org>
Tue, 21 Feb 2012 08:12:42 +0000 (09:12 +0100)
committerNikos Mavrogiannopoulos <nmav@gnutls.org>
Tue, 21 Feb 2012 08:12:42 +0000 (09:12 +0100)
tests/slow/cipher-test.c

index c39d2d83bc9b875e1d9cf7a8070c71f01f52a344..c51a3a4288a6aaa3766a151cc7d685b7b52c98da 100644 (file)
@@ -493,7 +493,18 @@ test_hash (void)
           /* import key */
           if (hash_vectors[i].key != NULL)
             {
+#if 0
+                ret = gnutls_hmac_fast(hash_vectors[i].algorithm, hash_vectors[i].key, hash_vectors[i].key_size,
+                      hash_vectors[i].plaintext, hash_vectors[i].plaintext_size, data);
+                if (ret < 0)
+                  {
+                      fprintf (stderr, "Error: %s:%d\n", __func__,
+                               __LINE__);
+                      return 1;
+                  }
+#else
                 gnutls_hmac_hd_t hd;
+
                 ret = gnutls_hmac_init( &hd, hash_vectors[i].algorithm, hash_vectors[i].key, hash_vectors[i].key_size);
                 if (ret < 0)
                   {
@@ -520,6 +531,7 @@ test_hash (void)
 
                 gnutls_hmac_output(hd, data);
                 gnutls_hmac_deinit(hd, NULL);
+#endif
 
                 data_size =
                     gnutls_hmac_get_len (hash_vectors[i].algorithm);