Discuss http://www.shoup.net/papers/oaep.ps.Z
[openssl.git] / crypto / sha / sha1s.cpp
index 0163377de69451307b540ad2569c9d03d52dc132..af23d1e0f21857f1f9d1cf83cb50438d4f69cf8d 100644 (file)
@@ -32,8 +32,9 @@ void GetTSC(unsigned long& tsc)
 
 #include <stdio.h>
 #include <stdlib.h>
-#include "sha.h"
+#include <openssl/sha.h>
 
+#define sha1_block_x86 sha1_block_asm_data_order
 extern "C" {
 void sha1_block_x86(SHA_CTX *ctx, unsigned char *buffer,int num);
 }
@@ -55,8 +56,10 @@ void main(int argc,char *argv[])
        if (num == 0) num=16;
        if (num > 250) num=16;
        numm=num+2;
+#if 0
        num*=64;
        numm*=64;
+#endif
 
        for (j=0; j<6; j++)
                {
@@ -72,7 +75,7 @@ void main(int argc,char *argv[])
                        sha1_block_x86(&ctx,buffer,num);
                        }
 
-               printf("sha1 (%d bytes) %d %d (%.2f)\n",num,
+               printf("sha1 (%d bytes) %d %d (%.2f)\n",num*64,
                        e1-s1,e2-s2,(double)((e1-s1)-(e2-s2))/2);
                }
        }