mirror of
https://github.com/Ap0dexMe0/unixtract.git
synced 2026-07-15 21:00:03 +02:00
invincible_image: add V2 key
This commit is contained in:
@@ -77,7 +77,8 @@ Options:
|
||||
|
||||
## INVINCIBLE_IMAGE
|
||||
**Used in:** LG Broadcom-based Blu-Ray players
|
||||
**Notes:** Only version 3 is supported (2011+)
|
||||
**Notes:** Key ID 1 (>2010) is not supported.
|
||||
Tip: if you have split ROM (.ROM-00 and .ROM-01), extract both into the same folder so they get combined.
|
||||
|
||||
## MSD 1.0
|
||||
**Used in:** Samsung TVs 2013-2015
|
||||
|
||||
@@ -5,6 +5,10 @@ use binrw::BinRead;
|
||||
pub static V3_KEY: [u8; 16] = [0x32, 0xe5, 0x26, 0x1e, 0x22, 0x67, 0x5e, 0x93, 0x20, 0xcf, 0x35, 0x91, 0x7c, 0x63, 0x7a, 0x36];
|
||||
pub static V3_IV: [u8; 16] = [0xe3, 0x9f, 0x36, 0x39, 0x56, 0x9a, 0x6b, 0x8d, 0x3f, 0x2e, 0xc9, 0x44, 0xd9, 0xbc, 0xec, 0x43];
|
||||
|
||||
//v2 key + iv
|
||||
pub static V2_KEY: [u8; 16] = [0x2e, 0x90, 0xe7, 0xea, 0xf6, 0x33, 0xb7, 0x26, 0xa7, 0xbf, 0x70, 0x17, 0x89, 0xc5, 0x8e, 0xad];
|
||||
pub static V2_IV: [u8; 16] = [0x23, 0x7e, 0x3b, 0x90, 0x7d, 0x24, 0x3f, 0xce, 0x43, 0xa4, 0xa3, 0x32, 0x1e, 0x92, 0x98, 0xfe];
|
||||
|
||||
#[derive(BinRead)]
|
||||
pub struct Header {
|
||||
_magic_bytes: [u8; 16], // INVINCIBLE_IMAGE
|
||||
|
||||
@@ -26,7 +26,7 @@ pub fn extract_invincible_image(app_ctx: &AppContext, _ctx: Box<dyn Any>) -> Res
|
||||
let mut file = app_ctx.file().ok_or("Extractor expected file")?;
|
||||
|
||||
let header: Header = file.read_le()?;
|
||||
println!("File info -\nFile Version: {}\nVersion(1): {}\nVersion(2): {}\nVersion(3): {}\nVersion(4): {}\nData size: {}\nChunk count: {}\nChunk size: {}\n\nPayload Count: {}",
|
||||
println!("File info -\nKey ID: {}\nVersion(1): {}\nVersion(2): {}\nVersion(3): {}\nVersion(4): {}\nData size: {}\nChunk count: {}\nChunk size: {}\n\nPayload Count: {}",
|
||||
header.file_infos[0], header.ver1(), header.ver2(), header.ver3(), header.ver4(), header.data_size, header.chunk_count, header.chunk_size, header.payload_count);
|
||||
|
||||
let mut entries: Vec<Entry> = Vec::new();
|
||||
@@ -40,7 +40,8 @@ pub fn extract_invincible_image(app_ctx: &AppContext, _ctx: Box<dyn Any>) -> Res
|
||||
|
||||
let (aes_key, aes_iv) = match header.file_infos[0] {
|
||||
3 => (V3_KEY, V3_IV),
|
||||
_ => return Err("Unsupported format version! (Unknown key)".into())
|
||||
2 => (V2_KEY, V2_IV),
|
||||
_ => return Err("Unsupported Key ID!".into())
|
||||
};
|
||||
|
||||
file.seek(SeekFrom::Start(header.data_start_offset.into()))?;
|
||||
|
||||
@@ -142,5 +142,6 @@ pub static EPK: &[(&str, &str)] = &[
|
||||
|
||||
("74514676D68B9A72A0093CEF56D3067484E1F4D5CF7D4B4ED389BED030FA1B09", "k7lp - Realtek webOS 6 (2021)"),
|
||||
("52A208FA24E7E70730A40999B1C22C148F4920484BC50B515D243E35D14689F1", "o24n - LX webOS 10 (2025)"),
|
||||
("1FB2C3B789D5EA48ED16E79A0343986C691DACEC872BB07787D0F722AF5D1E2C", "lm21ann - MStar webOS 8 (2023)"),
|
||||
|
||||
];
|
||||
Reference in New Issue
Block a user