Lines Matching refs:key
321 void mbedtls_des_key_set_parity( unsigned char key[MBEDTLS_DES_KEY_SIZE] ) in mbedtls_des_key_set_parity()
326 key[i] = odd_parity_table[key[i] / 2]; in mbedtls_des_key_set_parity()
332 int mbedtls_des_key_check_key_parity( const unsigned char key[MBEDTLS_DES_KEY_SIZE] ) in mbedtls_des_key_check_key_parity()
337 if( key[i] != odd_parity_table[key[i] / 2] ) in mbedtls_des_key_check_key_parity()
387 int mbedtls_des_key_check_weak( const unsigned char key[MBEDTLS_DES_KEY_SIZE] ) in mbedtls_des_key_check_weak()
392 if( memcmp( weak_key_table[i], key, MBEDTLS_DES_KEY_SIZE) == 0 ) in mbedtls_des_key_check_weak()
399 void mbedtls_des_setkey( uint32_t SK[32], const unsigned char key[MBEDTLS_DES_KEY_SIZE] ) in mbedtls_des_setkey()
404 X = MBEDTLS_GET_UINT32_BE( key, 0 ); in mbedtls_des_setkey()
405 Y = MBEDTLS_GET_UINT32_BE( key, 4 ); in mbedtls_des_setkey()
472 int mbedtls_des_setkey_enc( mbedtls_des_context *ctx, const unsigned char key[MBEDTLS_DES_KEY_SIZE]… in mbedtls_des_setkey_enc()
474 mbedtls_des_setkey( ctx->sk, key ); in mbedtls_des_setkey_enc()
482 int mbedtls_des_setkey_dec( mbedtls_des_context *ctx, const unsigned char key[MBEDTLS_DES_KEY_SIZE]… in mbedtls_des_setkey_dec()
486 mbedtls_des_setkey( ctx->sk, key ); in mbedtls_des_setkey_dec()
499 const unsigned char key[MBEDTLS_DES_KEY_SIZE*2] ) in des3_set2key()
503 mbedtls_des_setkey( esk, key ); in des3_set2key()
504 mbedtls_des_setkey( dsk + 32, key + 8 ); in des3_set2key()
526 const unsigned char key[MBEDTLS_DES_KEY_SIZE * 2] ) in mbedtls_des3_set2key_enc()
530 des3_set2key( ctx->sk, sk, key ); in mbedtls_des3_set2key_enc()
540 const unsigned char key[MBEDTLS_DES_KEY_SIZE * 2] ) in mbedtls_des3_set2key_dec()
544 des3_set2key( sk, ctx->sk, key ); in mbedtls_des3_set2key_dec()
552 const unsigned char key[24] ) in des3_set3key()
556 mbedtls_des_setkey( esk, key ); in des3_set3key()
557 mbedtls_des_setkey( dsk + 32, key + 8 ); in des3_set3key()
558 mbedtls_des_setkey( esk + 64, key + 16 ); in des3_set3key()
577 const unsigned char key[MBEDTLS_DES_KEY_SIZE * 3] ) in mbedtls_des3_set3key_enc()
581 des3_set3key( ctx->sk, sk, key ); in mbedtls_des3_set3key_enc()
591 const unsigned char key[MBEDTLS_DES_KEY_SIZE * 3] ) in mbedtls_des3_set3key_dec()
595 des3_set3key( sk, ctx->sk, key ); in mbedtls_des3_set3key_dec()