Home
last modified time | relevance | path

Searched refs:begin_params (Results 1 – 20 of 20) sorted by relevance

/system/keymaster/
Dandroid_keymaster_test.cpp541 AuthorizationSet begin_params(client_params()); in TEST_P() local
542 begin_params.push_back(TAG_DIGEST, KM_DIGEST_NONE); in TEST_P()
543 begin_params.push_back(TAG_PADDING, KM_PAD_RSA_PKCS1_1_5_SIGN); in TEST_P()
544 EXPECT_EQ(KM_ERROR_INCOMPATIBLE_PADDING_MODE, BeginOperation(KM_PURPOSE_SIGN, begin_params)); in TEST_P()
583 AuthorizationSet begin_params(client_params()); in TEST_P() local
584 begin_params.push_back(TAG_DIGEST, KM_DIGEST_NONE); in TEST_P()
585 begin_params.push_back(TAG_PADDING, KM_PAD_RSA_PKCS1_1_5_SIGN); in TEST_P()
586 EXPECT_EQ(KM_ERROR_OK, BeginOperation(KM_PURPOSE_SIGN, begin_params)); in TEST_P()
605 AuthorizationSet begin_params(client_params()); in TEST_P() local
606 begin_params.push_back(TAG_DIGEST, KM_DIGEST_SHA_2_256); in TEST_P()
[all …]
Drsa_keymaster1_operation.cpp49 AuthorizationSet begin_params(input_params); in Begin() local
50 int pos = begin_params.find(TAG_DIGEST); in Begin()
53 begin_params[pos].enumerated = KM_DIGEST_NONE; in Begin()
55 pos = begin_params.find(TAG_PADDING); in Begin()
58 switch (begin_params[pos].enumerated) { in Begin()
63 begin_params[pos].enumerated = KM_PAD_NONE; in Begin()
73 &begin_params, nullptr /* out_params */, &operation_handle_); in Begin()
116 const AuthorizationSet& begin_params, in CreateOperation() argument
119 if (!GetAndValidateDigest(begin_params, key, &digest, error)) in CreateOperation()
123 if (!GetAndValidatePadding(begin_params, key, &padding, error)) in CreateOperation()
Dandroid_keymaster_test_utils.cpp370 const AuthorizationSet& begin_params, in ProcessMessage() argument
373 EXPECT_EQ(KM_ERROR_OK, BeginOperation(purpose, begin_params, begin_out_params)); in ProcessMessage()
381 const string& signature, const AuthorizationSet& begin_params, in ProcessMessage() argument
384 EXPECT_EQ(KM_ERROR_OK, BeginOperation(purpose, begin_params, output_params)); in ProcessMessage()
467 AuthorizationSet begin_params(client_params()), output_params; in EncryptMessage() local
468 begin_params.push_back(TAG_PADDING, padding); in EncryptMessage()
471 ProcessMessage(KM_PURPOSE_ENCRYPT, message, begin_params, update_params, &output_params); in EncryptMessage()
498 AuthorizationSet begin_params(client_params()), output_params; in EncryptMessage() local
499 begin_params.push_back(TAG_PADDING, padding); in EncryptMessage()
500 begin_params.push_back(TAG_DIGEST, digest); in EncryptMessage()
[all …]
Decdsa_keymaster1_operation.cpp50 AuthorizationSet begin_params(input_params); in Begin() local
51 int pos = begin_params.find(TAG_DIGEST); in Begin()
54 begin_params[pos].enumerated = KM_DIGEST_NONE; in Begin()
57 &begin_params, nullptr /* out_params */, &operation_handle_); in Begin()
100 const AuthorizationSet& begin_params, in CreateOperation() argument
103 if (!GetAndValidateDigest(begin_params, key, &digest, error)) in CreateOperation()
Doperation.cpp89 bool OperationFactory::GetAndValidatePadding(const AuthorizationSet& begin_params, const Key& key, in GetAndValidatePadding() argument
93 if (!begin_params.GetTagValue(TAG_PADDING, padding)) { in GetAndValidatePadding()
94 LOG_E("%d padding modes specified in begin params", begin_params.GetTagCount(TAG_PADDING)); in GetAndValidatePadding()
114 bool OperationFactory::GetAndValidateDigest(const AuthorizationSet& begin_params, const Key& key, in GetAndValidateDigest() argument
118 if (!begin_params.GetTagValue(TAG_DIGEST, digest)) { in GetAndValidateDigest()
119 LOG_E("%d digests specified in begin params", begin_params.GetTagCount(TAG_DIGEST)); in GetAndValidateDigest()
Doperation.h55 virtual Operation* CreateOperation(const Key& key, const AuthorizationSet& begin_params,
80 bool GetAndValidatePadding(const AuthorizationSet& begin_params, const Key& key,
82 bool GetAndValidateDigest(const AuthorizationSet& begin_params, const Key& key,
Dhmac_operation.cpp37 const AuthorizationSet& begin_params, in CreateOperation() argument
47 if (begin_params.GetTagValue(TAG_MAC_LENGTH, &mac_length_bits)) { in CreateOperation()
63 begin_params.GetTagCount(TAG_DIGEST)); in CreateOperation()
Dkeymaster1_engine.h60 : op_handle(0), begin_params(params), key_material(blob), error(KM_ERROR_OK), in KeyData()
64 AuthorizationSet begin_params; member
Drsa_operation.h179 Operation* CreateOperation(const Key& key, const AuthorizationSet& begin_params, in CreateOperation() argument
181 return CreateRsaOperation(key, begin_params, error); in CreateOperation()
187 virtual RsaOperation* CreateRsaOperation(const Key& key, const AuthorizationSet& begin_params,
209 RsaOperation* CreateRsaOperation(const Key& key, const AuthorizationSet& begin_params,
Daes_operation.cpp51 static keymaster_error_t GetAndValidateGcmTagLength(const AuthorizationSet& begin_params, in GetAndValidateGcmTagLength() argument
55 if (!begin_params.GetTagValue(TAG_MAC_LENGTH, &tag_length_bits)) { in GetAndValidateGcmTagLength()
79 const AuthorizationSet& begin_params, in CreateOperation() argument
95 if (!begin_params.GetTagValue(TAG_BLOCK_MODE, &block_mode)) { in CreateOperation()
96 LOG_E("%d block modes specified in begin params", begin_params.GetTagCount(TAG_BLOCK_MODE)); in CreateOperation()
111 *error = GetAndValidateGcmTagLength(begin_params, key.authorizations(), &tag_length); in CreateOperation()
118 if (!GetAndValidatePadding(begin_params, key, &padding, error)) { in CreateOperation()
Drsa_operation.cpp66 const AuthorizationSet& begin_params, in CreateRsaOperation() argument
69 if (!GetAndValidatePadding(begin_params, key, &padding, error)) in CreateRsaOperation()
76 if (require_digest && !GetAndValidateDigest(begin_params, key, &digest, error)) in CreateRsaOperation()
98 const AuthorizationSet& begin_params, in CreateRsaOperation() argument
100 UniquePtr<RsaOperation> op(RsaOperationFactory::CreateRsaOperation(key, begin_params, error)); in CreateRsaOperation()
Decdsa_operation.cpp32 const AuthorizationSet& begin_params, in CreateOperation() argument
47 if (!GetAndValidateDigest(begin_params, key, &digest, error)) in CreateOperation()
Dhmac_operation.h59 virtual Operation* CreateOperation(const Key& key, const AuthorizationSet& begin_params,
Drsa_keymaster1_operation.h115 Operation* CreateOperation(const Key& key, const AuthorizationSet& begin_params,
Decdsa_keymaster1_operation.h115 Operation* CreateOperation(const Key& key, const AuthorizationSet& begin_params,
Decdsa_operation.h81 Operation* CreateOperation(const Key& key, const AuthorizationSet& begin_params,
Dkeymaster_enforcement_test.cpp482 AuthorizationSet begin_params(AuthorizationSetBuilder().Authorization(TAG_NONCE, "foo", 3)); in TEST_F() local
485 kmen.AuthorizeOperation(KM_PURPOSE_ENCRYPT, key_id, caller_nonce, begin_params, in TEST_F()
488 kmen.AuthorizeOperation(KM_PURPOSE_DECRYPT, key_id, caller_nonce, begin_params, in TEST_F()
491 kmen.AuthorizeOperation(KM_PURPOSE_ENCRYPT, key_id, no_caller_nonce, begin_params, in TEST_F()
494 kmen.AuthorizeOperation(KM_PURPOSE_DECRYPT, key_id, no_caller_nonce, begin_params, in TEST_F()
Dandroid_keymaster_test_utils.h230 const AuthorizationSet& begin_params,
234 const std::string& signature, const AuthorizationSet& begin_params,
264 const AuthorizationSet& begin_params,
Daes_operation.h35 Operation* CreateOperation(const Key& key, const AuthorizationSet& begin_params,
Dkeymaster1_engine.cpp155 GetKeymaster1PublicKey(key_data->key_material, key_data->begin_params, error)); in BuildRsaKey()