Lines Matching refs:attributes

15     psa_key_attributes_t attributes = PSA_KEY_ATTRIBUTES_INIT;
24 MBEDTLS_SVC_KEY_ID_GET_KEY_ID(psa_get_key_id(&attributes)), 0);
26 MBEDTLS_SVC_KEY_ID_GET_OWNER_ID(psa_get_key_id(&attributes)), 0);
27 TEST_EQUAL(psa_get_key_lifetime(&attributes), 0);
28 TEST_EQUAL(psa_get_key_usage_flags(&attributes), 0);
29 TEST_EQUAL(psa_get_key_algorithm(&attributes), 0);
30 TEST_EQUAL(psa_get_key_type(&attributes), 0);
31 TEST_EQUAL(psa_get_key_bits(&attributes), 0);
33 psa_set_key_id(&attributes, id);
34 psa_set_key_lifetime(&attributes, lifetime);
35 psa_set_key_usage_flags(&attributes, usage_flags);
36 psa_set_key_algorithm(&attributes, alg);
37 psa_set_key_type(&attributes, type);
38 psa_set_key_bits(&attributes, bits);
41 psa_get_key_id(&attributes), id));
42 TEST_EQUAL(psa_get_key_lifetime(&attributes), lifetime);
43 TEST_EQUAL(psa_get_key_usage_flags(&attributes), usage_flags);
44 TEST_EQUAL(psa_get_key_algorithm(&attributes), alg);
45 TEST_EQUAL(psa_get_key_type(&attributes), type);
46 TEST_EQUAL(psa_get_key_bits(&attributes), bits);
48 psa_reset_key_attributes(&attributes);
51 MBEDTLS_SVC_KEY_ID_GET_KEY_ID(psa_get_key_id(&attributes)), 0);
53 MBEDTLS_SVC_KEY_ID_GET_OWNER_ID(psa_get_key_id(&attributes)), 0);
54 TEST_EQUAL(psa_get_key_lifetime(&attributes), 0);
55 TEST_EQUAL(psa_get_key_usage_flags(&attributes), 0);
56 TEST_EQUAL(psa_get_key_algorithm(&attributes), 0);
57 TEST_EQUAL(psa_get_key_type(&attributes), 0);
58 TEST_EQUAL(psa_get_key_bits(&attributes), 0);
68 psa_key_attributes_t attributes = PSA_KEY_ATTRIBUTES_INIT;
79 psa_set_key_id(&attributes, id1);
82 psa_set_key_lifetime(&attributes, lifetime);
85 psa_set_key_id(&attributes, id2);
89 psa_get_key_id(&attributes), expected_id));
90 TEST_EQUAL(psa_get_key_lifetime(&attributes), expected_lifetime);
98 psa_key_attributes_t attributes = PSA_KEY_ATTRIBUTES_INIT;
101 TEST_EQUAL(psa_get_key_slot_number(&attributes, &slot_number),
105 psa_set_key_slot_number(&attributes, 0);
106 PSA_ASSERT(psa_get_key_slot_number(&attributes, &slot_number));
110 psa_set_key_slot_number(&attributes, 42);
111 PSA_ASSERT(psa_get_key_slot_number(&attributes, &slot_number));
115 psa_clear_key_slot_number(&attributes);
116 TEST_EQUAL(psa_get_key_slot_number(&attributes, &slot_number),
120 psa_clear_key_slot_number(&attributes);
121 TEST_EQUAL(psa_get_key_slot_number(&attributes, &slot_number),
125 psa_set_key_slot_number(&attributes, 42);
126 PSA_ASSERT(psa_get_key_slot_number(&attributes, &slot_number));
128 psa_reset_key_attributes(&attributes);
129 TEST_EQUAL(psa_get_key_slot_number(&attributes, &slot_number),