commit | c31822d8b1c748df10f07d9afb4ae3d9f712ef78 | [log] [tgz] |
---|---|---|
author | Seth Moore <[email protected]> | Thu Jun 15 17:54:52 2023 -0700 |
committer | Cherrypicker Worker <[email protected]> | Fri Jun 16 15:55:29 2023 +0000 |
tree | 80087f9d35fe0f3852d5648ebfef68566b30ef20 | |
parent | 19783639395d4170930bf0eed06a6088db8a1767 [diff] |
Fix padding on EC coordinates that are not expected sizes When encoding public EC keys, we should ensure that we don't have extra leading 00s that make the key larger than expected. Additionally, we should insert leading 00s if the key would otherwise be too short. Include new test data to verify these edge cases. Bug: 286384153 Test: atest libhwtrust_tests (cherry picked from https://android-review.googlesource.com/q/commit:6f75372e2b16584e893ac25426dc8692867ac724) Merged-In: I28418e6d8b788576a410b974e38c5a6d7fc96578 Change-Id: I28418e6d8b788576a410b974e38c5a6d7fc96578