Lines Matching refs:request
76 CreateGoogleAttestedKeyRequest request; in TEST_F() local
77 request.set_key_label("label"); in TEST_F()
78 request.set_key_type(KEY_TYPE_ECC); in TEST_F()
79 request.set_key_usage(KEY_USAGE_SIGN); in TEST_F()
80 request.set_certificate_profile(ENTERPRISE_MACHINE_CERTIFICATE); in TEST_F()
81 request.set_username("username"); in TEST_F()
82 request.set_origin("origin"); in TEST_F()
85 Invoke([](const CreateGoogleAttestedKeyRequest& request, in TEST_F()
88 EXPECT_EQ("label", request.key_label()); in TEST_F()
89 EXPECT_EQ(KEY_TYPE_ECC, request.key_type()); in TEST_F()
90 EXPECT_EQ(KEY_USAGE_SIGN, request.key_usage()); in TEST_F()
92 request.certificate_profile()); in TEST_F()
93 EXPECT_EQ("username", request.username()); in TEST_F()
94 EXPECT_EQ("origin", request.origin()); in TEST_F()
104 writer.AppendProtoAsArrayOfBytes(request); in TEST_F()
126 CreateGoogleAttestedKeyRequest request; in TEST_F() local
128 writer.AppendProtoAsArrayOfBytes(request); in TEST_F()
136 GetKeyInfoRequest request; in TEST_F() local
137 request.set_key_label("label"); in TEST_F()
138 request.set_username("username"); in TEST_F()
141 Invoke([](const GetKeyInfoRequest& request, in TEST_F()
143 EXPECT_EQ("label", request.key_label()); in TEST_F()
144 EXPECT_EQ("username", request.username()); in TEST_F()
157 writer.AppendProtoAsArrayOfBytes(request); in TEST_F()
172 GetEndorsementInfoRequest request; in TEST_F() local
173 request.set_key_type(KEY_TYPE_ECC); in TEST_F()
176 [](const GetEndorsementInfoRequest& request, in TEST_F()
178 EXPECT_EQ(KEY_TYPE_ECC, request.key_type()); in TEST_F()
188 writer.AppendProtoAsArrayOfBytes(request); in TEST_F()
199 GetAttestationKeyInfoRequest request; in TEST_F() local
200 request.set_key_type(KEY_TYPE_ECC); in TEST_F()
203 const GetAttestationKeyInfoRequest& request, in TEST_F()
205 EXPECT_EQ(KEY_TYPE_ECC, request.key_type()); in TEST_F()
218 writer.AppendProtoAsArrayOfBytes(request); in TEST_F()
232 ActivateAttestationKeyRequest request; in TEST_F() local
233 request.set_key_type(KEY_TYPE_ECC); in TEST_F()
234 request.mutable_encrypted_certificate()->set_asym_ca_contents("encrypted1"); in TEST_F()
235 request.mutable_encrypted_certificate()->set_sym_ca_attestation("encrypted2"); in TEST_F()
236 request.set_save_certificate(true); in TEST_F()
239 Invoke([](const ActivateAttestationKeyRequest& request, in TEST_F()
242 EXPECT_EQ(KEY_TYPE_ECC, request.key_type()); in TEST_F()
244 request.encrypted_certificate().asym_ca_contents()); in TEST_F()
246 request.encrypted_certificate().sym_ca_attestation()); in TEST_F()
247 EXPECT_TRUE(request.save_certificate()); in TEST_F()
256 writer.AppendProtoAsArrayOfBytes(request); in TEST_F()
266 CreateCertifiableKeyRequest request; in TEST_F() local
267 request.set_key_label("label"); in TEST_F()
268 request.set_key_type(KEY_TYPE_ECC); in TEST_F()
269 request.set_key_usage(KEY_USAGE_SIGN); in TEST_F()
270 request.set_username("user"); in TEST_F()
273 const CreateCertifiableKeyRequest& request, in TEST_F()
275 EXPECT_EQ("label", request.key_label()); in TEST_F()
276 EXPECT_EQ(KEY_TYPE_ECC, request.key_type()); in TEST_F()
277 EXPECT_EQ(KEY_USAGE_SIGN, request.key_usage()); in TEST_F()
278 EXPECT_EQ("user", request.username()); in TEST_F()
289 writer.AppendProtoAsArrayOfBytes(request); in TEST_F()
301 DecryptRequest request; in TEST_F() local
302 request.set_key_label("label"); in TEST_F()
303 request.set_username("user"); in TEST_F()
304 request.set_encrypted_data("data"); in TEST_F()
307 Invoke([](const DecryptRequest& request, in TEST_F()
309 EXPECT_EQ("label", request.key_label()); in TEST_F()
310 EXPECT_EQ("user", request.username()); in TEST_F()
311 EXPECT_EQ("data", request.encrypted_data()); in TEST_F()
319 writer.AppendProtoAsArrayOfBytes(request); in TEST_F()
329 SignRequest request; in TEST_F() local
330 request.set_key_label("label"); in TEST_F()
331 request.set_username("user"); in TEST_F()
332 request.set_data_to_sign("data"); in TEST_F()
334 .WillOnce(Invoke([](const SignRequest& request, in TEST_F()
336 EXPECT_EQ("label", request.key_label()); in TEST_F()
337 EXPECT_EQ("user", request.username()); in TEST_F()
338 EXPECT_EQ("data", request.data_to_sign()); in TEST_F()
346 writer.AppendProtoAsArrayOfBytes(request); in TEST_F()
356 RegisterKeyWithChapsTokenRequest request; in TEST_F() local
357 request.set_key_label("label"); in TEST_F()
358 request.set_username("user"); in TEST_F()
361 [](const RegisterKeyWithChapsTokenRequest& request, in TEST_F()
364 EXPECT_EQ("label", request.key_label()); in TEST_F()
365 EXPECT_EQ("user", request.username()); in TEST_F()
373 writer.AppendProtoAsArrayOfBytes(request); in TEST_F()