Started working on payloads... still need to integrate
This commit is contained in:
16
checkm8_payloads/include/brfunc_aes.h
Normal file
16
checkm8_payloads/include/brfunc_aes.h
Normal file
@@ -0,0 +1,16 @@
|
||||
#ifndef IPWNDFU_REWRITE_C_BRFUNC_AES_H
|
||||
#define IPWNDFU_REWRITE_C_BRFUNC_AES_H
|
||||
|
||||
#include "brfunc_common.h"
|
||||
|
||||
#define CREATE_KEY_COMMAND ((BOOTROM_FUNC) ADDR_CREATE_KEY_COMMAND)
|
||||
#define PUSH_COMMAND_KEY ((BOOTROM_FUNC) ADDR_PUSH_COMMAND_KEY)
|
||||
#define PUSH_COMMAND_IV ((BOOTROM_FUNC) ADDR_PUSH_COMMAND_IV)
|
||||
#define PUSH_COMMAND_DATA ((BOOTROM_FUNC) ADDR_PUSH_COMMAND_DATA)
|
||||
#define PUSH_COMMAND_FLAG ((BOOTROM_FUNC) ADDR_PUSH_COMMAND_FLAG)
|
||||
#define WAIT_FOR_COMMAND_FLAG ((BOOTROM_FUNC) ADDR_WAIT_FOR_COMMAND_FLAG)
|
||||
|
||||
#define rAES_INT_STATUS (long *) ADDR_rAES_INT_STATUS
|
||||
#define rAES_CONTROL (long *) ADDR_rAES_CONTROL
|
||||
|
||||
#endif //IPWNDFU_REWRITE_C_BRFUNC_AES_H
|
||||
34
checkm8_payloads/include/brfunc_common.h
Normal file
34
checkm8_payloads/include/brfunc_common.h
Normal file
@@ -0,0 +1,34 @@
|
||||
#ifndef IPWNDFU_REWRITE_C_BRFUNC_COMMON_H
|
||||
#define IPWNDFU_REWRITE_C_BRFUNC_COMMON_H
|
||||
|
||||
#include "include/checkm8_config.h"
|
||||
|
||||
typedef int (*BOOTROM_FUNC)();
|
||||
|
||||
#if CHECKM8_PLATFORM == 8010
|
||||
|
||||
/* AES */
|
||||
#define ADDR_CREATE_KEY_COMMAND 0x100000e90
|
||||
#define ADDR_PUSH_COMMAND_KEY 0x100000c64
|
||||
#define ADDR_PUSH_COMMAND_IV 0x100000d18
|
||||
#define ADDR_PUSH_COMMAND_DATA 0x100000d98
|
||||
#define ADDR_PUSH_COMMAND_FLAG 0x100000e20
|
||||
#define ADDR_WAIT_FOR_COMMAND_FLAG 0x100000ec4
|
||||
|
||||
#define ADDR_rAES_CONTROL 0x20A108008
|
||||
#define ADDR_rAES_INT_STATUS 0x20A108018
|
||||
|
||||
/* SEP */
|
||||
#define ADDR_DPA_SEEDED 0x100001140
|
||||
#define ADDR_SEP_CREATE_SEND_DPA_MESSAGE 0x100002338
|
||||
|
||||
/* Timing */
|
||||
#define ADDR_CLOCK_GATE 0x100009d4c
|
||||
#define ADDR_SYSTEM_TIME 0x10000B0E0
|
||||
#define ADDR_TIME_HAS_ELAPSED 0x10000B04F
|
||||
|
||||
#else
|
||||
#error "Unsupported checkm8 platform"
|
||||
#endif
|
||||
|
||||
#endif //IPWNDFU_REWRITE_C_BRFUNC_COMMON_H
|
||||
7
checkm8_payloads/include/brfunc_sep.h
Normal file
7
checkm8_payloads/include/brfunc_sep.h
Normal file
@@ -0,0 +1,7 @@
|
||||
#ifndef IPWNDFU_REWRITE_C_BRFUNC_SEP_H
|
||||
#define IPWNDFU_REWRITE_C_BRFUNC_SEP_H
|
||||
|
||||
#define DPA_SEEDED ((BOOTROM_FUNC) ADDR_DPA_SEEDED)
|
||||
#define SEP_CREATE_SEND_DPA_MESSAGE ((BOOTROM_FUNC) ADDR_SEP_CREATE_SEND_DPA_MESSAGE)
|
||||
|
||||
#endif //IPWNDFU_REWRITE_C_BRFUNC_SEP_H
|
||||
8
checkm8_payloads/include/brfunc_timing.h
Normal file
8
checkm8_payloads/include/brfunc_timing.h
Normal file
@@ -0,0 +1,8 @@
|
||||
#ifndef IPWNDFU_REWRITE_C_BRFUNC_TIMING_H
|
||||
#define IPWNDFU_REWRITE_C_BRFUNC_TIMING_H
|
||||
|
||||
#define CLOCK_GATE ((BOOTROM_FUNC) ADDR_CLOCK_GATE)
|
||||
#define SYSTEM_TIME ((BOOTROM_FUNC) ADDR_SYSTEM_TIME)
|
||||
#define TIME_HAS_ELAPSED ((BOOTROM_FUNC) ADDR_TIME_HAS_ELAPSED)
|
||||
|
||||
#endif //IPWNDFU_REWRITE_C_BRFUNC_TIMING_H
|
||||
Reference in New Issue
Block a user