chipsalliance / caliptra-sw

Caliptra software (ROM, FMC, runtime firmware), and libraries/tools needed to build and test
Apache License 2.0
53 stars 39 forks source link

[experiment] Hack the smoke_test to only include the first HMAC block in the expected rt-alias-key derivation #1538

Closed korran closed 3 weeks ago

korran commented 4 months ago

Hack the smoke_test to only include the first HMAC block in the expected rt-alias-key derivation

If the smoke_test() passes on the FPGA with this change, that confirms that the first block is being fully mixed in by today's FMC.

This is the (already padded) data intended to be hmac'd:

# block 0 (this block included in rt-alias)
00000000  00 00 00 01 72 74 5f 61  6c 69 61 73 5f 63 64 69  |....rt_alias_cdi|
00000010  00 03 91 03 63 1e f7 9d  36 a1 5c 5a 38 07 ca 6a  |....c...6.\Z8..j|
00000020  71 42 de c4 7e 3c 90 8c  aa 9c 41 2b be 83 71 92  |qB..~<....A+..q.|
00000030  0a fe a7 2b ed 4d 52 a4  f0 7b c3 bb 7d b6 50 3f  |...+.MR..{..}.P?|
00000040  7e cb 5a c2 23 45 70 96  84 6a 6c da 09 3a 03 f2  |~.Z.#Ep..jl..:..|
00000050  78 c5 52 19 5f bb e4 76  26 2b 4d 05 90 60 b5 18  |x.R._..v&+M..`..|
00000060  28 54 df 20 81 0f a8 fe  59 2a 3c 3c e9 a5 27 bc  |(T. ....Y*<<..'.|
00000070  27 80 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |'...............|
# block 1 (this block was skipped)
00000080  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
00000090  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
000000a0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
000000b0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
000000c0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
000000d0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
000000e0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
000000f0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 07 88  |................|