47 const char *mem_region,
48 const char *os_symbols)
52 struct doca_apsh_ctx *apsh_ctx;
53 struct doca_apsh_system *sys;
54 struct doca_apsh_process *proc, **processes;
55 int num_injection_detect;
56 struct doca_apsh_injection_detect **injection_detect_list;
87 DOCA_LOG_ERR(
"Failed to read injection_detect info from host");
92 DOCA_LOG_INFO(
"Successfully performed %s. Host proc(%d) contains %d injection_detect",
95 num_injection_detect);
99 for (i = 0; i < num_injection_detect; ++i) {
100 DOCA_LOG_INFO(
"\tINJECTION_detect %d - Process pid: %u, start address: 0x%" PRIx64
101 ", end address: 0x%" PRIx64
", vad start address: 0x%" PRIx64
102 ", vad end address: 0x%" PRIx64
", vad path: %s",
doca_error_t process_get(DOCA_APSH_PROCESS_PID_TYPE pid, struct doca_apsh_system *sys, int *nb_procs, struct doca_apsh_process ***processes, struct doca_apsh_process **process)
doca_error_t cleanup_doca_apsh(struct doca_apsh_ctx *ctx, struct doca_apsh_system *system)
doca_error_t init_doca_apsh_system(struct doca_apsh_ctx *ctx, enum doca_apsh_system_os os_type, const char *os_symbols, const char *mem_region, const char *pci_vuid, struct doca_apsh_system **system)
doca_error_t init_doca_apsh(const char *dma_device_name, struct doca_apsh_ctx **ctx)
DOCA_LOG_REGISTER(INJECTION_DETECT_GET)
doca_error_t injection_detect_get(const char *dma_device_name, const char *pci_vuid, enum doca_apsh_system_os os_type, DOCA_APSH_PROCESS_PID_TYPE pid, const char *mem_region, const char *os_symbols)
uint32_t DOCA_APSH_PROCESS_PID_TYPE
process pid type
doca_apsh_system_os
system os types
@ DOCA_APSH_INJECTION_DETECT_VAD_START
@ DOCA_APSH_INJECTION_DETECT_VAD_FILE_PATH
@ DOCA_APSH_INJECTION_DETECT_VAD_END
@ DOCA_APSH_INJECTION_DETECT_SUSPECTED_AREA_END
@ DOCA_APSH_INJECTION_DETECT_PID
@ DOCA_APSH_INJECTION_DETECT_SUSPECTED_AREA_START
#define doca_apsh_injection_detect_info_get(suspected_injection, attr)
Get attribute value for a suspected_injection.
DOCA_EXPERIMENTAL void doca_apsh_injection_detect_free(struct doca_apsh_injection_detect **suspected_injections)
Destroys an injection_detect context.
DOCA_EXPERIMENTAL doca_error_t doca_apsh_injection_detect_get(struct doca_apsh_process *process, struct doca_apsh_injection_detect ***suspected_injections, int *suspected_injections_size)
Get suspected code injections of current process.
#define doca_apsh_process_info_get(process, attr)
Get attribute value for a process.
DOCA_EXPERIMENTAL void doca_apsh_processes_free(struct doca_apsh_process **processes)
Destroys a process context.
enum doca_error doca_error_t
DOCA API return codes.
DOCA_STABLE const char * doca_error_get_descr(doca_error_t error)
Returns the description string of an error code.
#define DOCA_LOG_ERR(format,...)
Generates an ERROR application log message.
#define DOCA_LOG_INFO(format,...)
Generates an INFO application log message.