aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorvanhauser-thc <vh@thc.org>2023-04-16 12:42:32 +0200
committervanhauser-thc <vh@thc.org>2023-04-16 12:42:32 +0200
commit56f7e3aa088e715b054f10c01b6b5a7e5acf8931 (patch)
treeb2e3c154f14bfc9d7d284a92afdd508d119f1eea /include
parent87b9dc4ba0d14d7a144578faf37f899724b826a3 (diff)
downloadafl++-56f7e3aa088e715b054f10c01b6b5a7e5acf8931.tar.gz
hidden -Y option for nyx, code format
Diffstat (limited to 'include')
-rw-r--r--include/common.h4
-rw-r--r--include/forkserver.h13
2 files changed, 11 insertions, 6 deletions
diff --git a/include/common.h b/include/common.h
index e03566de..8d85d201 100644
--- a/include/common.h
+++ b/include/common.h
@@ -149,8 +149,8 @@ void *afl_memmem(const void *haystack, size_t haystacklen, const void *needle,
#ifdef __linux__
/* Nyx helper functions to create and remove tmp workdirs */
-char* create_nyx_tmp_workdir(void);
-void remove_nyx_tmp_workdir(afl_forkserver_t *fsrv, char* nyx_out_dir_path);
+char *create_nyx_tmp_workdir(void);
+void remove_nyx_tmp_workdir(afl_forkserver_t *fsrv, char *nyx_out_dir_path);
#endif
#endif
diff --git a/include/forkserver.h b/include/forkserver.h
index ba280d38..f5069ce2 100644
--- a/include/forkserver.h
+++ b/include/forkserver.h
@@ -52,20 +52,25 @@ typedef enum NyxReturnValue {
} NyxReturnValue;
typedef enum NyxProcessRole {
+
StandAlone,
Parent,
Child,
+
} NyxProcessRole;
typedef struct {
void *(*nyx_config_load)(const char *sharedir);
void (*nyx_config_set_workdir_path)(void *config, const char *workdir);
- void (*nyx_config_set_input_buffer_size)(void *config, uint32_t input_buffer_size);
- void (*nyx_config_set_input_buffer_write_protection)(void *config, bool input_buffer_write_protection);
+ void (*nyx_config_set_input_buffer_size)(void *config,
+ uint32_t input_buffer_size);
+ void (*nyx_config_set_input_buffer_write_protection)(
+ void *config, bool input_buffer_write_protection);
void (*nyx_config_set_hprintf_fd)(void *config, int32_t hprintf_fd);
void (*nyx_config_set_process_role)(void *config, enum NyxProcessRole role);
- void (*nyx_config_set_reuse_snapshot_path)(void *config, const char *reuse_snapshot_path);
+ void (*nyx_config_set_reuse_snapshot_path)(void *config,
+ const char *reuse_snapshot_path);
void *(*nyx_new)(void *config, uint32_t worker_id);
void (*nyx_shutdown)(void *qemu_process);
@@ -191,7 +196,7 @@ typedef struct afl_forkserver {
u32 nyx_bind_cpu_id; /* nyx runner cpu id */
char *nyx_aux_string;
bool nyx_use_tmp_workdir;
- char *nyx_tmp_workdir_path;
+ char *nyx_tmp_workdir_path;
#endif
} afl_forkserver_t;