Commit fa9dad7
Derive KEY_SIZE from EC_CURVE when not explicitly provided
For EC keys, callers often provide only EC_CURVE (e.g. P-256) without
an explicit KEY_SIZE tag. The parser defaulted keySize to 0, causing
the attestation teeEnforced list and KeyMetadata authorizations to
report keySize=0 instead of the correct value (e.g. 256 for P-256).
Add deriveKeySizeFromCurve() that maps EcCurve constants to their
corresponding key sizes as a fallback when KEY_SIZE is absent.1 parent 0958d17 commit fa9dad7
1 file changed
Lines changed: 15 additions & 1 deletion
Lines changed: 15 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
50 | 50 | | |
51 | 51 | | |
52 | 52 | | |
53 | | - | |
| 53 | + | |
| 54 | + | |
54 | 55 | | |
55 | 56 | | |
56 | 57 | | |
| |||
167 | 168 | | |
168 | 169 | | |
169 | 170 | | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
170 | 184 | | |
171 | 185 | | |
172 | 186 | | |
| |||
0 commit comments