mirror of
https://github.com/rvtr/TwlIPL.git
synced 2025-10-31 06:01:12 -04:00
Phase2Ex用テスト追加
git-svn-id: file:///Users/lillianskinner/Downloads/platinum/twl/TwlIPL/trunk@1415 b08762b0-b915-fc4b-9d8c-17b2551a87ff
This commit is contained in:
parent
1662c92ce4
commit
63049ed8d4
@ -71,6 +71,15 @@ static BOOL ReadImage(void* dest, s32 offset, s32 length, void* arg)
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
static BOOL ReadImageEx(SVCHMACSHA1Context* ctx, s32 offset, s32 length, void* arg)
|
||||
{
|
||||
if ( !ReadImage(p2work.buffer, offset, length, arg) )
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
DHT_CheckHashPhase2ExUpdate(ctx, p2work.buffer, length);
|
||||
return TRUE;
|
||||
}
|
||||
#else
|
||||
#ifdef SDK_ARM9
|
||||
#define PAGE_SIZE 512
|
||||
@ -187,6 +196,12 @@ static BOOL CheckValidation(FSFile* fp)
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
// ハッシュ計算 (2ex) - 隠蔽は難しいか
|
||||
if ( !DHT_CheckHashPhase2Ex(db->hash[1], &rom_header, (DHTPhase2ExWork*)&p2work, ReadImage, ReadImageEx, fp) )
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user