Changeset 1069
- Timestamp:
- 07/06/11 16:37:33 (11 months ago)
- Location:
- trunk
- Files:
-
- 2 edited
-
include/polarssl/des.h (modified) (1 diff)
-
library/des.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/polarssl/des.h
r1027 r1069 78 78 * 79 79 * \param key 8-byte secret key 80 * 81 * \return 0 is parity was ok, 1 if parity was not correct. 80 82 */ 81 83 int des_key_check_key_parity( const unsigned char key[DES_KEY_SIZE] ); 82 84 83 84 85 /** 85 86 * \brief Check that key is not a weak or semi-weak DES key 86 87 * 87 88 * \param key 8-byte secret key 89 * 90 * \resurn 0 if no weak key was found, 1 if a weak key was identified. 88 91 */ 89 92 int des_key_check_weak( const unsigned char key[DES_KEY_SIZE] ); -
trunk/library/des.c
r1014 r1069 372 372 for( i = 0; i < WEAK_KEY_COUNT; i++ ) 373 373 if( memcmp( weak_key_table[i], key, DES_KEY_SIZE) == 0) 374 return( 0);375 376 return( 1);374 return( 1 ); 375 376 return( 0 ); 377 377 } 378 378
Note: See TracChangeset
for help on using the changeset viewer.


