Lines Matching refs:key

346 void mbedtls_des_key_set_parity( unsigned char key[MBEDTLS_DES_KEY_SIZE] )  in mbedtls_des_key_set_parity()
351 key[i] = odd_parity_table[key[i] / 2]; in mbedtls_des_key_set_parity()
357 int mbedtls_des_key_check_key_parity( const unsigned char key[MBEDTLS_DES_KEY_SIZE] ) in mbedtls_des_key_check_key_parity()
362 if( key[i] != odd_parity_table[key[i] / 2] ) in mbedtls_des_key_check_key_parity()
412 int mbedtls_des_key_check_weak( const unsigned char key[MBEDTLS_DES_KEY_SIZE] ) in mbedtls_des_key_check_weak()
417 if( memcmp( weak_key_table[i], key, MBEDTLS_DES_KEY_SIZE) == 0 ) in mbedtls_des_key_check_weak()
424 void mbedtls_des_setkey( uint32_t SK[32], const unsigned char key[MBEDTLS_DES_KEY_SIZE] ) in mbedtls_des_setkey()
429 GET_UINT32_BE( X, key, 0 ); in mbedtls_des_setkey()
430 GET_UINT32_BE( Y, key, 4 ); in mbedtls_des_setkey()
497 int mbedtls_des_setkey_enc( mbedtls_des_context *ctx, const unsigned char key[MBEDTLS_DES_KEY_SIZE]… in mbedtls_des_setkey_enc()
499 mbedtls_des_setkey( ctx->sk, key ); in mbedtls_des_setkey_enc()
507 int mbedtls_des_setkey_dec( mbedtls_des_context *ctx, const unsigned char key[MBEDTLS_DES_KEY_SIZE]… in mbedtls_des_setkey_dec()
511 mbedtls_des_setkey( ctx->sk, key ); in mbedtls_des_setkey_dec()
524 const unsigned char key[MBEDTLS_DES_KEY_SIZE*2] ) in des3_set2key()
528 mbedtls_des_setkey( esk, key ); in des3_set2key()
529 mbedtls_des_setkey( dsk + 32, key + 8 ); in des3_set2key()
551 const unsigned char key[MBEDTLS_DES_KEY_SIZE * 2] ) in mbedtls_des3_set2key_enc()
555 des3_set2key( ctx->sk, sk, key ); in mbedtls_des3_set2key_enc()
565 const unsigned char key[MBEDTLS_DES_KEY_SIZE * 2] ) in mbedtls_des3_set2key_dec()
569 des3_set2key( sk, ctx->sk, key ); in mbedtls_des3_set2key_dec()
577 const unsigned char key[24] ) in des3_set3key()
581 mbedtls_des_setkey( esk, key ); in des3_set3key()
582 mbedtls_des_setkey( dsk + 32, key + 8 ); in des3_set3key()
583 mbedtls_des_setkey( esk + 64, key + 16 ); in des3_set3key()
602 const unsigned char key[MBEDTLS_DES_KEY_SIZE * 3] ) in mbedtls_des3_set3key_enc()
606 des3_set3key( ctx->sk, sk, key ); in mbedtls_des3_set3key_enc()
616 const unsigned char key[MBEDTLS_DES_KEY_SIZE * 3] ) in mbedtls_des3_set3key_dec()
620 des3_set3key( sk, ctx->sk, key ); in mbedtls_des3_set3key_dec()