Added some more functionality to payload installation

This commit is contained in:
2019-12-10 19:01:02 -05:00
parent 16cf301e80
commit 1ea372da10
7 changed files with 142 additions and 27 deletions

View File

@@ -1,11 +1,29 @@
#ifndef IPWNDFU_REWRITE_C_PAYLOAD_H
#define IPWNDFU_REWRITE_C_PAYLOAD_H
#include "checkm8.h"
#define PAYLOAD_SUCCESS 0
#define PAYLOAD_FAIL_DUP -1
#define PAYLOAD_FOUND 0
#define PAYLOAD_NOT_FOUND -1
typedef enum
{
PAYLOAD_AES
PAYLOAD_AES,
PAYLOAD_SYSREG
} PAYLOAD_T;
struct payload *get_payload(PAYLOAD_T p);
typedef enum
{
SRAM,
DRAM
} LOCATION_T;
int install_payload(struct pwned_device *dev, PAYLOAD_T p, LOCATION_T loc);
int uninstall_payload(struct pwned_device *dev, PAYLOAD_T p);
int execute_payload(struct pwned_device *dev, PAYLOAD_T p, ...);
#endif //IPWNDFU_REWRITE_C_PAYLOAD_H