atjboottool: document more header fields and crypto code

The encryption definitely uses some standard elliptic curve encryption over
binary fields (163 and 233 bits, standard polynomials). It is still unclear
how this is used in the actual encryption, the key authentification and
derivation do not look standard.

Change-Id: I6b9180ff7e6115e1dceca8489e986a02a9ea6fc9
This commit is contained in:
Amaury Pouly 2017-10-26 18:16:00 +01:00
parent 3ad9caeb2a
commit 7807934a27
3 changed files with 261 additions and 178 deletions

View file

@ -109,11 +109,6 @@ uint8_t g_decode_B_table[20] =
0xf8, 0xb4, 0x36, 0x41, 0xc5, 0x51, 0xaf
};
uint32_t g_xor_key[9] =
{
1, 0, 0, 0, 0, 0, 0, 0, 0
};
uint32_t g_crypto_table[8] =
{
0xefad6126, 0x0a4c9d6e, 0x19c26bf5, 0x149563a4, 0x29f22ff4, 0x7e731af1,
@ -142,7 +137,7 @@ uint32_t g_crypto_key4[6] =
0x797324f1, 0xb11c5c0c, 0xa2cdd545, 0x71a0094f, 0xd51fbc6c, 0x00000000
};
uint32_t g_crypto_data3[6] =
uint32_t g_atj_ec163_a[6] =
{
0x00000001, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000
};
@ -152,7 +147,7 @@ uint32_t g_crypto_key5[6] =
0x4a3205fd, 0x512f7874, 0x1481eb10, 0xb8c953ca, 0x0a601907, 0x00000002
};
uint32_t g_crypto_data[8] =
uint32_t g_atj_ec233_a[8] =
{
0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000,
};