Lines Matching refs:ver
34 Message* round_trip(int32_t ver, const Message& message, size_t expected_size) { in round_trip() argument
42 Message* deserialized = new Message(ver); in round_trip()
50 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
51 EmptyKeymasterResponse msg(ver); in TEST()
54 UniquePtr<EmptyKeymasterResponse> deserialized(round_trip(ver, msg, 4)); in TEST()
59 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
60 EmptyKeymasterResponse msg(ver); in TEST()
63 UniquePtr<EmptyKeymasterResponse> deserialized(round_trip(ver, msg, 4)); in TEST()
79 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
80 GenerateKeyRequest req(ver); in TEST()
87 UniquePtr<GenerateKeyRequest> deserialized(round_trip(ver, req, ver < 4 ? 78 : 170)); in TEST()
89 if (ver < 4) { in TEST()
104 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
105 GenerateKeyResponse rsp(ver); in TEST()
117 if (ver < 4) { in TEST()
118 deserialized.reset(round_trip(ver, rsp, 109)); in TEST()
120 deserialized.reset(round_trip(ver, rsp, 134)); in TEST()
128 if (ver < 4) { in TEST()
144 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
145 GenerateKeyResponse rsp(ver); in TEST()
151 UniquePtr<GenerateKeyResponse> deserialized(round_trip(ver, rsp, 4)); in TEST()
160 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
161 GenerateRkpKeyRequest req(ver); in TEST()
164 UniquePtr<GenerateRkpKeyRequest> deserialized(round_trip(ver, req, 1)); in TEST()
170 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
171 GenerateRkpKeyResponse rsp(ver); in TEST()
179 deserialized.reset(round_trip(ver, rsp, 34)); in TEST()
192 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
193 GenerateCsrRequest req(ver); in TEST()
202 UniquePtr<GenerateCsrRequest> deserialized(round_trip(ver, req, 65)); in TEST()
224 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
225 GenerateCsrResponse rsp(ver); in TEST()
235 deserialized.reset(round_trip(ver, rsp, 49)); in TEST()
253 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
254 GetKeyCharacteristicsRequest req(ver); in TEST()
258 UniquePtr<GetKeyCharacteristicsRequest> deserialized(round_trip(ver, req, 85)); in TEST()
266 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
267 GetKeyCharacteristicsResponse msg(ver); in TEST()
272 UniquePtr<GetKeyCharacteristicsResponse> deserialized(round_trip(ver, msg, 160)); in TEST()
279 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
280 BeginOperationRequest msg(ver); in TEST()
285 UniquePtr<BeginOperationRequest> deserialized(round_trip(ver, msg, 89)); in TEST()
294 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
295 BeginOperationResponse msg(ver); in TEST()
301 switch (ver) { in TEST()
303 deserialized.reset(round_trip(ver, msg, 12)); in TEST()
309 deserialized.reset(round_trip(ver, msg, 39)); in TEST()
318 switch (ver) { in TEST()
335 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
336 BeginOperationResponse msg(ver); in TEST()
340 UniquePtr<BeginOperationResponse> deserialized(round_trip(ver, msg, 4)); in TEST()
346 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
347 UpdateOperationRequest msg(ver); in TEST()
352 switch (ver) { in TEST()
354 deserialized.reset(round_trip(ver, msg, 15)); in TEST()
360 deserialized.reset(round_trip(ver, msg, 27)); in TEST()
371 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
372 UpdateOperationResponse msg(ver); in TEST()
379 switch (ver) { in TEST()
381 deserialized.reset(round_trip(ver, msg, 11)); in TEST()
384 deserialized.reset(round_trip(ver, msg, 15)); in TEST()
389 deserialized.reset(round_trip(ver, msg, 42)); in TEST()
398 switch (ver) { in TEST()
418 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
419 FinishOperationRequest msg(ver); in TEST()
425 switch (ver) { in TEST()
427 deserialized.reset(round_trip(ver, msg, 15)); in TEST()
431 deserialized.reset(round_trip(ver, msg, 27)); in TEST()
435 deserialized.reset(round_trip(ver, msg, 34)); in TEST()
447 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
448 FinishOperationResponse msg(ver); in TEST()
453 switch (ver) { in TEST()
456 deserialized.reset(round_trip(ver, msg, 11)); in TEST()
461 deserialized.reset(round_trip(ver, msg, 23)); in TEST()
474 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
475 ImportKeyRequest msg(ver); in TEST()
484 UniquePtr<ImportKeyRequest> deserialized(round_trip(ver, msg, ver < 4 ? 89 : 181)); in TEST()
490 if (ver < 4) { in TEST()
505 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
506 ImportKeyResponse msg(ver); in TEST()
518 if (ver < 4) { in TEST()
519 deserialized.reset(round_trip(ver, msg, 167)); in TEST()
521 deserialized.reset(round_trip(ver, msg, 192)); in TEST()
532 if (ver < 4) { in TEST()
548 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
549 ExportKeyRequest msg(ver); in TEST()
554 UniquePtr<ExportKeyRequest> deserialized(round_trip(ver, msg, 89)); in TEST()
563 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
564 ExportKeyResponse msg(ver); in TEST()
568 UniquePtr<ExportKeyResponse> deserialized(round_trip(ver, msg, 11)); in TEST()
575 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
576 DeleteKeyRequest msg(ver); in TEST()
579 UniquePtr<DeleteKeyRequest> deserialized(round_trip(ver, msg, 7)); in TEST()
586 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
587 DeleteAllKeysRequest msg(ver); in TEST()
588 UniquePtr<DeleteAllKeysRequest> deserialized(round_trip(ver, msg, 0)); in TEST()
667 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
668 ConfigureRequest req(ver); in TEST()
672 UniquePtr<ConfigureRequest> deserialized(round_trip(ver, req, 8)); in TEST()
679 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
680 ConfigureResponse rsp(ver); in TEST()
681 UniquePtr<ConfigureResponse> deserialized(round_trip(ver, rsp, 4)); in TEST()
686 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
687 ConfigureVendorPatchlevelRequest req(ver); in TEST()
690 UniquePtr<ConfigureVendorPatchlevelRequest> deserialized(round_trip(ver, req, 4)); in TEST()
696 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
697 ConfigureVendorPatchlevelResponse rsp(ver); in TEST()
698 UniquePtr<ConfigureVendorPatchlevelResponse> deserialized(round_trip(ver, rsp, 4)); in TEST()
703 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
704 ConfigureBootPatchlevelRequest req(ver); in TEST()
707 UniquePtr<ConfigureBootPatchlevelRequest> deserialized(round_trip(ver, req, 4)); in TEST()
713 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
714 ConfigureBootPatchlevelResponse rsp(ver); in TEST()
715 UniquePtr<ConfigureBootPatchlevelResponse> deserialized(round_trip(ver, rsp, 4)); in TEST()
720 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
721 AddEntropyRequest msg(ver); in TEST()
724 UniquePtr<AddEntropyRequest> deserialized(round_trip(ver, msg, 7)); in TEST()
731 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
732 AbortOperationRequest msg(ver); in TEST()
733 UniquePtr<AbortOperationRequest> deserialized(round_trip(ver, msg, 8)); in TEST()
738 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
739 AttestKeyRequest msg(ver); in TEST()
743 UniquePtr<AttestKeyRequest> deserialized(round_trip(ver, msg, 85)); in TEST()
751 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
752 AttestKeyResponse msg(ver); in TEST()
760 UniquePtr<AttestKeyResponse> deserialized(round_trip(ver, msg, 29)); in TEST()
775 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
776 UpgradeKeyRequest msg(ver); in TEST()
780 UniquePtr<UpgradeKeyRequest> deserialized(round_trip(ver, msg, 85)); in TEST()
788 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
789 UpgradeKeyResponse req(ver); in TEST()
794 UniquePtr<UpgradeKeyResponse> deserialized(round_trip(ver, req, 19)); in TEST()
803 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
804 GenerateTimestampTokenRequest msg(ver); in TEST()
806 UniquePtr<GenerateTimestampTokenRequest> deserialized(round_trip(ver, msg, 8)); in TEST()
812 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
813 GenerateTimestampTokenResponse msg(ver); in TEST()
820 UniquePtr<GenerateTimestampTokenResponse> deserialized(round_trip(ver, msg, 39)); in TEST()
841 for (int ver = 0; ver <= kMaxMessageVersion; ++ver) { in TEST() local
842 SetAttestationIdsRequest msg(ver); in TEST()
852 UniquePtr<SetAttestationIdsRequest> deserialized(round_trip(ver, msg, 81)); in TEST()
897 for (int32_t ver = 0; ver <= kMaxMessageVersion; ++ver) { in parse_garbage() local
898 Message msg(ver); in parse_garbage()
917 for (uint32_t ver = 0; ver < kMaxMessageVersion; ++ver) { in parse_garbage() local
918 Message msg(ver); in parse_garbage()