Update of /cvsroot/wpdev/wolfpack/twofish
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6599/twofish
Modified Files:
debug.h platform.h
Added Files:
twofish2.cpp
Removed Files:
twofish2.c
Log Message:
Experimental MacOS X support
--- NEW FILE: twofish2.cpp ---
/***************************************************************************
TWOFISH2.C -- Optimized C API calls for TWOFISH AES submission
Submitters:
Bruce Schneier, Counterpane Systems
Doug Whiting, Hi/fn
John Kelsey, Counterpane Systems
Chris Hall, Counterpane Systems
David Wagner, UC Berkeley
Code Author: Doug Whiting, Hi/fn
Version 1.00 April 1998
Copyright 1998, Hi/fn and Counterpane Systems. All rights reserved.
Notes:
* Optimized version
* Tab size is set to 4 characters in this file
[...1137 lines suppressed...]
}
}
if ( mode == MODE_CBC ) /* restore iv32 to cipher */
BlockCopy( cipher->iv32, IV )
return inputLen;
}
#ifdef GetCodeSize
DWORD TwofishCodeSize( void )
{
DWORD x = Here( 0 );
#ifdef USE_ASM
if ( useAsm & 3 )
return TwofishAsmCodeSize();
#endif
return x - TwofishCodeStart();
};
#endif
Index: debug.h
===================================================================
RCS file: /cvsroot/wpdev/wolfpack/twofish/debug.h,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** debug.h 12 Aug 2004 12:13:33 -0000 1.4
--- debug.h 24 Aug 2004 00:23:25 -0000 1.5
***************
*** 1,3 ****
! #ifdef DEBUG /* keep these macros common so they are same for both versions */
CONST int debugCompile = 1;
extern int debug;
--- 1,3 ----
! #ifdef DEBUG_TWOFISH /* keep these macros common so they are same for both versions */
CONST int debugCompile = 1;
extern int debug;
--- twofish2.c DELETED ---
Index: platform.h
===================================================================
RCS file: /cvsroot/wpdev/wolfpack/twofish/platform.h,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** platform.h 30 Sep 2003 15:06:30 -0000 1.4
--- platform.h 24 Aug 2004 00:23:25 -0000 1.5
***************
*** 20,23 ****
--- 20,25 ----
***************************************************************************/
+ #include <qglobal.h>
+
/* use intrinsic rotate if possible */
#define ROL( x, y ) ( ( (x) << (y) ) | ( (x) >> ( 32 - (y) ) ) )
***************
*** 34,38 ****
--- 36,42 ----
// Change this to compile on a BigEndian machine
+ #if !defined(Q_OS_MAC)
#define LittleEndian 1
+ #endif
#define ALIGN32 1
|