From 97ccc628cefa6d9ce5ae10ef94a8eb0d1fff76ae Mon Sep 17 00:00:00 2001 From: jakcron Date: Wed, 25 Apr 2018 22:58:45 +0800 Subject: [PATCH] [nx] Define sNcaHeaderBlock --- lib/libnx/include/nx/nca.h | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/lib/libnx/include/nx/nca.h b/lib/libnx/include/nx/nca.h index 04f9036..2754b74 100644 --- a/lib/libnx/include/nx/nca.h +++ b/lib/libnx/include/nx/nca.h @@ -88,7 +88,7 @@ namespace nx char signature[4]; byte_t distribution_type; byte_t content_type; - byte_t key_generation; // KeyGeneration + byte_t key_generation; byte_t key_area_encryption_key_index; le_uint64_t content_size; le_uint64_t program_id; @@ -108,6 +108,14 @@ namespace nx crypto::aes::sAes128Key enc_aes_key[nca::kAesKeyNum]; }; + struct sNcaHeaderBlock + { + byte_t signature_main[crypto::rsa::kRsa2048Size]; + byte_t signature_acid[crypto::rsa::kRsa2048Size]; + sNcaHeader header; + byte_t fs_header[nx::nca::kPartitionNum][nx::nca::kSectorSize]; + }; + struct sNcaFsHeader { le_uint16_t version; // usually 0x0002