Greenbone Vulnerability Management Libraries  22.8.0
gmp.h
Go to the documentation of this file.
1 /* SPDX-FileCopyrightText: 2009-2023 Greenbone AG
2  *
3  * SPDX-License-Identifier: GPL-2.0-or-later
4  */
5 
11 #ifndef _GVM_GMP_H
12 #define _GVM_GMP_H
13 
14 #include "../base/array.h" /* for array_t */
15 #include "../util/serverutils.h" /* for gvm_connection_t */
16 #include "../util/xmlutils.h" /* for entity_t */
17 
18 #include <glib.h> /* for gchar */
19 #include <glib/gtypes.h> /* for gsize */
20 #include <gnutls/gnutls.h> /* for gnutls_session_t */
21 #include <stddef.h> /* for NULL */
22 
26 typedef struct
27 {
28  int timeout;
29  const char *username;
30  const char *password;
31  char **role;
32  char **timezone;
33  char **pw_warning;
35 
40  {0, NULL, NULL, NULL, NULL, NULL};
41 
45 typedef struct
46 {
47  const char *sort_field;
48  const char *sort_order;
49  const char *format_id;
50  const char *levels;
51  const char *report_id;
54  int timeout;
57  int autofp;
58  char *type;
60  char *filter;
61  char *filt_id;
62  char *host;
63  char *pos;
64  char *timezone;
65  char *alert_id;
67  char *delta_states;
68  char *host_levels;
69  char *search_phrase;
71  char *min_cvss_base;
72  char *min_qod;
73  /* Boolean flags: */
74  int notes;
76  int overrides;
82 
87  "ROWID",
88  "ascending",
89  "a994b278-1f62-11e1-96ac-406186ea4fc5",
90  "hmlgd",
91  NULL,
92  1,
93  -1,
94  0,
95  0,
96  0,
97  0,
98  NULL,
99  NULL,
100  NULL,
101  NULL,
102  NULL,
103  NULL,
104  NULL,
105  NULL,
106  NULL,
107  NULL,
108  NULL,
109  NULL,
110  NULL,
111  NULL,
112  0,
113  0,
114  0,
115  0,
116  0,
117  0,
118  0};
119 
123 typedef struct
124 {
125  const char *filter;
126  int timeout;
127  const char *actions;
128  /* Boolean flags: */
129  int details;
130  int rcfile;
132 
136 static const gmp_get_tasks_opts_t gmp_get_tasks_opts_defaults = {"", 0, NULL, 0,
137  0};
138 
142 typedef struct
143 {
144  const char *actions;
145  const char *task_id;
146  /* Boolean flags: */
147  int details;
148  int rcfile;
150 
154 static const gmp_get_task_opts_t gmp_get_task_opts_defaults = {NULL, NULL, 0,
155  0};
156 
160 typedef struct
161 {
163  const char *config_id;
164  const char *scanner_id;
165  const char *schedule_id;
166  const char *slave_id;
167  const char *target_id;
168  const char *name;
169  const char *comment;
170  const char *hosts_ordering;
171  const char *observers;
174  /* Preferences */
175  const char *in_assets;
176  const char *max_hosts;
177  const char *max_checks;
178  const char *source_iface;
179  /* Boolean flags: */
180  int alterable;
182 
187  NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL,
188  NULL, NULL, 0, NULL, NULL, NULL, NULL, 0};
189 
193 typedef struct
194 {
196  const char *ssh_credential_id;
197  const char *smb_credential_id;
198  const char *esxi_credential_id;
199  const char *snmp_credential_id;
200  const char *port_range;
201  const char *name;
202  const char *comment;
203  const char *hosts;
204  const char *exclude_hosts;
205  const char *alive_tests;
206  /* Boolean flags: */
210 
215  0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, 0};
216 
220 typedef struct
221 {
222  const char *name;
223  const char *duration;
224  const char *start_time;
225  const char *end_time;
226  const char *slave_id;
227  int brief;
229 
234  gmp_get_system_reports_opts_defaults = {NULL, NULL, NULL, NULL, NULL, 0};
235 
239 typedef struct
240 {
241  const char *name;
242  const char *community;
243  const char *login;
244  const char *passphrase;
245  const char *private_key;
246  const char *auth_algorithm;
247  const char *privacy_password;
248  const char *privacy_algorithm;
249  const char *comment;
251 
256  gmp_create_lsc_credential_opts_defaults = {NULL, NULL, NULL, NULL, NULL,
257  NULL, NULL, NULL, NULL};
258 
262 typedef struct
263 {
264  int ultimate;
266 
271 
276 
277 int
278 gmp_read_create_response (gnutls_session_t *, gchar **);
279 
280 const char *
281 gmp_task_status (entity_t status_response);
282 
283 int
284 gmp_ping (gnutls_session_t *, int);
285 
286 int
287 gmp_ping_c (gvm_connection_t *, int, gchar **);
288 
289 int
290 gmp_authenticate (gnutls_session_t *session, const char *username,
291  const char *password);
292 
293 int
295 
296 int
298 
299 int
300 gmp_create_task (gnutls_session_t *, const char *, const char *, const char *,
301  const char *, gchar **);
302 
303 int
304 gmp_create_task_ext (gnutls_session_t *, gmp_create_task_opts_t, gchar **);
305 
306 int
307 gmp_start_task_report (gnutls_session_t *, const char *, char **);
308 
309 int
310 gmp_start_task_report_c (gvm_connection_t *, const char *, char **);
311 
315 typedef struct
316 {
317  const char *task_id;
319 
321 
322 int
324 
325 int
326 gmp_stop_task (gnutls_session_t *, const char *);
327 
328 int
329 gmp_stop_task_c (gvm_connection_t *, const char *);
330 
331 int
332 gmp_resume_task_report (gnutls_session_t *, const char *, char **);
333 
334 int
335 gmp_resume_task_report_c (gvm_connection_t *, const char *, char **);
336 
337 int
338 gmp_get_tasks (gnutls_session_t *, const char *, int, int, entity_t *);
339 
340 int
341 gmp_get_tasks_ext (gnutls_session_t *, gmp_get_tasks_opts_t, entity_t *);
342 
343 int
344 gmp_get_task_ext (gnutls_session_t *, gmp_get_task_opts_t, entity_t *);
345 
346 int
347 gmp_get_targets (gnutls_session_t *, const char *, int, int, entity_t *);
348 
349 int
350 gmp_get_report_ext (gnutls_session_t *, gmp_get_report_opts_t, entity_t *);
351 
352 int
353 gmp_delete_port_list_ext (gnutls_session_t *, const char *, gmp_delete_opts_t);
354 
355 int
356 gmp_delete_task (gnutls_session_t *, const char *);
357 
358 int
359 gmp_delete_task_ext (gnutls_session_t *, const char *, gmp_delete_opts_t);
360 
361 int
362 gmp_modify_task_file (gnutls_session_t *, const char *, const char *,
363  const void *, gsize);
364 
365 int
366 gmp_delete_report (gnutls_session_t *, const char *);
367 
368 int
369 gmp_create_target_ext (gnutls_session_t *, gmp_create_target_opts_t, gchar **);
370 
371 int
372 gmp_delete_target_ext (gnutls_session_t *, const char *, gmp_delete_opts_t);
373 
374 int
375 gmp_delete_config_ext (gnutls_session_t *, const char *, gmp_delete_opts_t);
376 
377 int
378 gmp_create_lsc_credential_ext (gnutls_session_t *,
380 
381 int
382 gmp_create_lsc_credential (gnutls_session_t *, const char *, const char *,
383  const char *, const char *, gchar **);
384 
385 int
386 gmp_create_lsc_credential_key (gnutls_session_t *, const char *, const char *,
387  const char *, const char *, const char *,
388  gchar **);
389 
390 int
391 gmp_delete_lsc_credential_ext (gnutls_session_t *, const char *,
393 
394 int
395 gmp_get_system_reports (gnutls_session_t *, const char *, int, entity_t *);
396 
397 int
399  entity_t *);
400 
401 #endif /* not _GVM_GMP_H */
gmp_create_target_opts_t::ssh_credential_id
const char * ssh_credential_id
ID of SSH credential.
Definition: gmp.h:196
gmp_get_task_ext
int gmp_get_task_ext(gnutls_session_t *, gmp_get_task_opts_t, entity_t *)
Get a task (generic version).
Definition: gmp.c:1155
gmp_modify_task_file
int gmp_modify_task_file(gnutls_session_t *, const char *, const char *, const void *, gsize)
Modify a file on a task.
Definition: gmp.c:1259
gmp_get_report_opts_t::host_first_result
int host_first_result
Skip over results before this result number.
Definition: gmp.h:55
gmp_create_task_opts_t::slave_id
const char * slave_id
ID of task schedule.
Definition: gmp.h:166
gmp_start_task_opts_defaults
static const gmp_start_task_opts_t gmp_start_task_opts_defaults
Definition: gmp.h:320
gmp_delete_opts_defaults
static const gmp_delete_opts_t gmp_delete_opts_defaults
Sensible default values for gmp_get_report_opts_t.
Definition: gmp.h:270
gmp_get_task_opts_t::details
int details
Whether to include overrides in the tasks.
Definition: gmp.h:147
gmp_get_report_opts_t::override_details
int override_details
If overrides, whether to include details.
Definition: gmp.h:77
gmp_create_lsc_credential_opts_t::privacy_algorithm
const char * privacy_algorithm
SNMP privacy algorithm.
Definition: gmp.h:248
gmp_create_lsc_credential_opts_t::private_key
const char * private_key
Private key.
Definition: gmp.h:245
gmp_get_task_opts_t::task_id
const char * task_id
ID of single task to get.
Definition: gmp.h:145
gmp_get_task_opts_t::rcfile
int rcfile
Ignored. Removed since GMP 6.0.
Definition: gmp.h:148
gmp_create_task_ext
int gmp_create_task_ext(gnutls_session_t *, gmp_create_task_opts_t, gchar **)
Create a task.
Definition: gmp.c:533
gmp_delete_task
int gmp_delete_task(gnutls_session_t *, const char *)
Delete a task and read the manager response.
Definition: gmp.c:1316
gmp_get_report_opts_t::format_id
const char * format_id
ID of required report format.
Definition: gmp.h:49
gmp_create_target_opts_t::hosts
const char * hosts
Name of target.
Definition: gmp.h:203
gmp_create_lsc_credential_opts_t::auth_algorithm
const char * auth_algorithm
SNMP authentication algorithm.
Definition: gmp.h:246
gmp_get_report_opts_t::sort_order
const char * sort_order
Definition: gmp.h:48
gmp_start_task_opts_t::task_id
const char * task_id
ID of task.
Definition: gmp.h:317
gmp_create_target_opts_defaults
static const gmp_create_target_opts_t gmp_create_target_opts_defaults
Sensible default values for gmp_get_report_opts_t.
Definition: gmp.h:214
gmp_authenticate_info_opts_t::username
const char * username
Password.
Definition: gmp.h:29
gmp_authenticate_info_opts_defaults
static const gmp_authenticate_info_opts_t gmp_authenticate_info_opts_defaults
Sensible default values for gmp_authenticate_info_opts_t.
Definition: gmp.h:39
gmp_get_task_opts_t::actions
const char * actions
Actions argument.
Definition: gmp.h:144
gmp_resume_task_report
int gmp_resume_task_report(gnutls_session_t *, const char *, char **)
Resume a task and read the manager response.
Definition: gmp.c:985
gmp_delete_opts_ultimate_defaults
static const gmp_delete_opts_t gmp_delete_opts_ultimate_defaults
Default values for gmp_get_report_opts_t for ultimate deletion.
Definition: gmp.h:275
gmp_create_target_opts_t::exclude_hosts
const char * exclude_hosts
Hosts to exclude.
Definition: gmp.h:204
gmp_read_create_response
int gmp_read_create_response(gnutls_session_t *, gchar **)
Read response status and resource UUID.
Definition: gmp.c:884
gmp_get_report_opts_t::result_hosts_only
int result_hosts_only
Whether to include only hosts that have results.
Definition: gmp.h:79
gmp_create_lsc_credential_opts_t::login
const char * login
Login.
Definition: gmp.h:243
gmp_create_task_opts_t::target_id
const char * target_id
ID of target.
Definition: gmp.h:167
gmp_delete_config_ext
int gmp_delete_config_ext(gnutls_session_t *, const char *, gmp_delete_opts_t)
Delete a config.
Definition: gmp.c:1688
array_t
GPtrArray array_t
Definition: array.h:16
gmp_authenticate
int gmp_authenticate(gnutls_session_t *session, const char *username, const char *password)
Authenticate with the manager.
Definition: gmp.c:317
gmp_create_task_opts_t::max_checks
const char * max_checks
Max checks preference.
Definition: gmp.h:177
gmp_get_report_opts_defaults
static const gmp_get_report_opts_t gmp_get_report_opts_defaults
Sensible default values for gmp_get_report_opts_t.
Definition: gmp.h:86
gmp_create_lsc_credential_ext
int gmp_create_lsc_credential_ext(gnutls_session_t *, gmp_create_lsc_credential_opts_t, gchar **)
Create an LSC credential.
Definition: gmp.c:1841
gmp_get_tasks_opts_t::details
int details
Whether to include overrides in the tasks.
Definition: gmp.h:129
gmp_get_tasks_opts_defaults
static const gmp_get_tasks_opts_t gmp_get_tasks_opts_defaults
Sensible default values for gmp_get_tasks_opts_t.
Definition: gmp.h:136
gmp_get_report_opts_t::apply_overrides
int apply_overrides
Whether overrides are applied.
Definition: gmp.h:78
gmp_get_tasks_opts_t::rcfile
int rcfile
Ignored. Removed since GMP 6.0.
Definition: gmp.h:130
gmp_create_target_opts_t::snmp_credential_id
const char * snmp_credential_id
ID of SNMP credential.
Definition: gmp.h:199
gmp_get_task_opts_defaults
static const gmp_get_task_opts_t gmp_get_task_opts_defaults
Sensible default values for gmp_get_tasks_opts_t.
Definition: gmp.h:154
gmp_delete_port_list_ext
int gmp_delete_port_list_ext(gnutls_session_t *, const char *, gmp_delete_opts_t)
Delete a port list.
Definition: gmp.c:1480
gmp_get_report_opts_t::filter
char * filter
Term to filter results.
Definition: gmp.h:60
gmp_get_report_opts_t::report_id
const char * report_id
ID of single report to get.
Definition: gmp.h:51
gmp_stop_task_c
int gmp_stop_task_c(gvm_connection_t *, const char *)
Stop a task and read the manager response.
Definition: gmp.c:966
gmp_create_task_opts_t::hosts_ordering
const char * hosts_ordering
Order for scanning target hosts.
Definition: gmp.h:170
gmp_get_report_opts_t
Struct holding options for gmp get_report command.
Definition: gmp.h:46
gmp_create_target_opts_t::name
const char * name
Name of target.
Definition: gmp.h:201
gmp_get_report_opts_t::search_phrase
char * search_phrase
Search phrase result filter.
Definition: gmp.h:69
gmp_get_system_reports_ext
int gmp_get_system_reports_ext(gnutls_session_t *, gmp_get_system_reports_opts_t, entity_t *)
Get system reports.
Definition: gmp.c:1996
gmp_authenticate_info_ext
int gmp_authenticate_info_ext(gnutls_session_t *, gmp_authenticate_info_opts_t)
Authenticate with the manager.
Definition: gmp.c:360
gmp_get_task_opts_t
Struct holding options for gmp get_tasks command.
Definition: gmp.h:143
gmp_create_task_opts_t::in_assets
const char * in_assets
In assets preference.
Definition: gmp.h:175
gmp_get_system_reports_opts_t::duration
const char * duration
Duration.
Definition: gmp.h:223
gmp_start_task_ext_c
int gmp_start_task_ext_c(gvm_connection_t *, gmp_start_task_opts_t)
Start a task and read the manager response.
Definition: gmp.c:853
gmp_create_task_opts_t
Struct holding options for gmp create_task command.
Definition: gmp.h:161
gmp_get_report_opts_t::timeout
int timeout
Timeout for GMP response.
Definition: gmp.h:54
gmp_create_target_opts_t::reverse_lookup_only
int reverse_lookup_only
Scanner pref reverse_lookup_only.
Definition: gmp.h:207
gmp_get_system_reports_opts_t::slave_id
const char * slave_id
ID of the slave to get report from.
Definition: gmp.h:226
gmp_get_system_reports_opts_t::start_time
const char * start_time
Time of first data point.
Definition: gmp.h:224
gmp_delete_report
int gmp_delete_report(gnutls_session_t *, const char *)
Remove a report.
Definition: gmp.c:1508
gmp_create_lsc_credential_opts_t::name
const char * name
Name of LSC credential.
Definition: gmp.h:241
gmp_create_lsc_credential_opts_t
Struct holding options for gmp create_lsc_credential command.
Definition: gmp.h:240
gmp_create_lsc_credential_opts_t::passphrase
const char * passphrase
Passphrase.
Definition: gmp.h:244
gmp_get_system_reports_opts_t::brief
int brief
Brief flag.
Definition: gmp.h:227
gmp_authenticate_info_ext_c
int gmp_authenticate_info_ext_c(gvm_connection_t *, gmp_authenticate_info_opts_t)
Authenticate with the manager.
Definition: gmp.c:441
gmp_authenticate_info_opts_t::timeout
int timeout
Timeout for authentication.
Definition: gmp.h:28
gmp_ping
int gmp_ping(gnutls_session_t *, int)
"Ping" the manager.
Definition: gmp.c:186
gmp_create_target_opts_t::esxi_credential_id
const char * esxi_credential_id
ID of ESXi credential.
Definition: gmp.h:198
gmp_delete_opts_t
Struct holding options for various gmp delete_[...] commands.
Definition: gmp.h:263
gmp_authenticate_info_opts_t::password
const char * password
Username.
Definition: gmp.h:30
gmp_get_report_opts_t::filt_id
char * filt_id
ID of filter, to filter results.
Definition: gmp.h:61
gmp_ping_c
int gmp_ping_c(gvm_connection_t *, int, gchar **)
"Ping" the manager.
Definition: gmp.c:245
gmp_authenticate_info_opts_t::timezone
char ** timezone
[out] Timezone if any, else NULL.
Definition: gmp.h:32
gmp_get_report_opts_t::delta_states
char * delta_states
Delta states (Changed Gone New Same) to include.
Definition: gmp.h:67
gmp_create_lsc_credential_opts_t::community
const char * community
SNMP community.
Definition: gmp.h:242
gmp_create_task_opts_t::comment
const char * comment
Comment on task.
Definition: gmp.h:169
gmp_create_task_opts_t::alterable
int alterable
Whether the task is alterable.
Definition: gmp.h:180
gmp_create_task_opts_t::alert_ids
array_t * alert_ids
Array of alert IDs.
Definition: gmp.h:162
gmp_get_tasks_opts_t::actions
const char * actions
Actions argument.
Definition: gmp.h:127
gmp_get_report_opts_t::sort_field
const char * sort_field
Definition: gmp.h:47
gmp_create_lsc_credential_opts_defaults
static const gmp_create_lsc_credential_opts_t gmp_create_lsc_credential_opts_defaults
Sensible default values for gmp_create_lsc_credential_opts_t.
Definition: gmp.h:256
gmp_get_report_opts_t::notes_details
int notes_details
Whether to include details of above.
Definition: gmp.h:75
gmp_get_report_opts_t::pos
char * pos
Position of report from end.
Definition: gmp.h:63
gmp_get_report_opts_t::levels
const char * levels
Result levels to include.
Definition: gmp.h:50
gmp_start_task_report
int gmp_start_task_report(gnutls_session_t *, const char *, char **)
Start a task and read the manager response.
Definition: gmp.c:748
gmp_get_system_reports_opts_t
Struct holding options for gmp get_system_reports command.
Definition: gmp.h:221
gmp_get_report_opts_t::timezone
char * timezone
Timezone.
Definition: gmp.h:64
gmp_get_report_opts_t::autofp
int autofp
Definition: gmp.h:57
gmp_create_lsc_credential_opts_t::comment
const char * comment
Comment on LSC credential.
Definition: gmp.h:249
gmp_create_task_opts_t::schedule_id
const char * schedule_id
ID of task schedule.
Definition: gmp.h:165
gmp_create_task_opts_t::max_hosts
const char * max_hosts
Max hosts preference.
Definition: gmp.h:176
gmp_get_tasks_opts_t::filter
const char * filter
Filter argument.
Definition: gmp.h:125
gmp_delete_lsc_credential_ext
int gmp_delete_lsc_credential_ext(gnutls_session_t *, const char *, gmp_delete_opts_t)
Delete a LSC credential.
Definition: gmp.c:1933
gmp_create_task_opts_t::observer_groups
array_t * observer_groups
IDs of observer groups.
Definition: gmp.h:172
gmp_task_status
const char * gmp_task_status(entity_t status_response)
Get the task status from a GMP GET_TASKS response.
Definition: gmp.c:48
gmp_create_target_opts_t::comment
const char * comment
Comment on target.
Definition: gmp.h:202
gmp_create_task_opts_t::schedule_periods
int schedule_periods
Number of periods the schedule must run for.
Definition: gmp.h:173
gmp_get_system_reports_opts_defaults
static const gmp_get_system_reports_opts_t gmp_get_system_reports_opts_defaults
Sensible default values for gmp_get_report_opts_t.
Definition: gmp.h:234
gmp_get_targets
int gmp_get_targets(gnutls_session_t *, const char *, int, int, entity_t *)
Get a target.
Definition: gmp.c:1344
gmp_get_report_opts_t::host_max_results
int host_max_results
Maximum number of results to return.
Definition: gmp.h:56
gmp_get_system_reports_opts_t::name
const char * name
Name of report.
Definition: gmp.h:222
gmp_authenticate_info_opts_t::role
char ** role
[out] Role.
Definition: gmp.h:31
gmp_get_report_opts_t::host_search_phrase
char * host_search_phrase
Search phrase result filter.
Definition: gmp.h:70
gmp_get_report_opts_t::host_levels
char * host_levels
Letter encoded threat level filter, for hosts.
Definition: gmp.h:68
gmp_delete_target_ext
int gmp_delete_target_ext(gnutls_session_t *, const char *, gmp_delete_opts_t)
Delete a target.
Definition: gmp.c:1659
gmp_get_report_opts_t::notes
int notes
Whether to include associated notes.
Definition: gmp.h:74
entity_s
XML element.
Definition: xmlutils.h:52
gmp_get_report_opts_t::alert_id
char * alert_id
ID of alert.
Definition: gmp.h:65
gmp_create_task_opts_t::name
const char * name
Name of task.
Definition: gmp.h:168
gmp_create_task_opts_t::observers
const char * observers
Comma-separated string of observer users.
Definition: gmp.h:171
gmp_resume_task_report_c
int gmp_resume_task_report_c(gvm_connection_t *, const char *, char **)
Resume a task and read the manager response.
Definition: gmp.c:1030
gmp_create_task_opts_t::scanner_id
const char * scanner_id
ID of task scanner.
Definition: gmp.h:164
gmp_start_task_opts_t
Struct holding options for gmp start_task command.
Definition: gmp.h:316
gmp_get_report_ext
int gmp_get_report_ext(gnutls_session_t *, gmp_get_report_opts_t, entity_t *)
Get a report (generic version).
Definition: gmp.c:1382
gmp_create_task_opts_t::config_id
const char * config_id
ID of config.
Definition: gmp.h:163
gmp_get_tasks_opts_t
Struct holding options for gmp get_tasks command.
Definition: gmp.h:124
gmp_get_tasks_opts_t::timeout
int timeout
Timeout for GMP response.
Definition: gmp.h:126
gmp_authenticate_info_opts_t::pw_warning
char ** pw_warning
[out] Password warning, NULL if password is okay.
Definition: gmp.h:33
gmp_stop_task
int gmp_stop_task(gnutls_session_t *, const char *)
Stop a task and read the manager response.
Definition: gmp.c:942
gmp_get_report_opts_t::min_qod
char * min_qod
Minimum QoD filter.
Definition: gmp.h:72
gmp_create_task
int gmp_create_task(gnutls_session_t *, const char *, const char *, const char *, const char *, gchar **)
Create a task given a config and target.
Definition: gmp.c:713
gmp_create_task_opts_t::source_iface
const char * source_iface
Source iface preference.
Definition: gmp.h:178
gmp_create_target_opts_t::alive_tests
const char * alive_tests
Alive tests.
Definition: gmp.h:205
gmp_delete_task_ext
int gmp_delete_task_ext(gnutls_session_t *, const char *, gmp_delete_opts_t)
Delete a task and read the manager response.
Definition: gmp.c:1088
gmp_get_system_reports_opts_t::end_time
const char * end_time
Time of last data point.
Definition: gmp.h:225
gmp_get_tasks_ext
int gmp_get_tasks_ext(gnutls_session_t *, gmp_get_tasks_opts_t, entity_t *)
Get all tasks (generic version).
Definition: gmp.c:1192
gmp_create_target_opts_t::reverse_lookup_unify
int reverse_lookup_unify
Scanner pref reverse_lookup_unify.
Definition: gmp.h:208
gmp_get_report_opts_t::host
char * host
Host for asset report.
Definition: gmp.h:62
gmp_get_report_opts_t::min_cvss_base
char * min_cvss_base
Minimum CVSS base filter.
Definition: gmp.h:71
gmp_start_task_report_c
int gmp_start_task_report_c(gvm_connection_t *, const char *, char **)
Start a task and read the manager response.
Definition: gmp.c:793
gmp_get_report_opts_t::first_result
int first_result
First result to get.
Definition: gmp.h:52
gmp_create_target_opts_t::port_range
const char * port_range
Port range.
Definition: gmp.h:200
gmp_create_target_opts_t::ssh_credential_port
int ssh_credential_port
Port for SSH access.
Definition: gmp.h:195
gmp_authenticate_info_opts_t
Struct holding options for authentication.
Definition: gmp.h:27
gmp_create_lsc_credential_key
int gmp_create_lsc_credential_key(gnutls_session_t *, const char *, const char *, const char *, const char *, const char *, gchar **)
Create an LSC Credential with a key.
Definition: gmp.c:1788
gmp_create_target_ext
int gmp_create_target_ext(gnutls_session_t *, gmp_create_target_opts_t, gchar **)
Create a target.
Definition: gmp.c:1538
gmp_get_report_opts_t::ignore_pagination
int ignore_pagination
Whether to ignore pagination filters.
Definition: gmp.h:80
gmp_get_report_opts_t::overrides
int overrides
Whether to include overrides in the report.
Definition: gmp.h:76
gmp_create_task_opts_defaults
static const gmp_create_task_opts_t gmp_create_task_opts_defaults
Sensible default values for gmp_get_report_opts_t.
Definition: gmp.h:186
gmp_get_report_opts_t::delta_report_id
char * delta_report_id
ID of report to compare single report to.
Definition: gmp.h:66
gmp_delete_opts_t::ultimate
int ultimate
Definition: gmp.h:264
gmp_get_tasks
int gmp_get_tasks(gnutls_session_t *, const char *, int, int, entity_t *)
Get the status of a task.
Definition: gmp.c:1120
gvm_connection_t
Connection.
Definition: serverutils.h:30
gmp_create_lsc_credential_opts_t::privacy_password
const char * privacy_password
SNMP privacy password.
Definition: gmp.h:247
gmp_create_target_opts_t::smb_credential_id
const char * smb_credential_id
ID of SMB credential.
Definition: gmp.h:197
gmp_create_lsc_credential
int gmp_create_lsc_credential(gnutls_session_t *, const char *, const char *, const char *, const char *, gchar **)
Create an LSC Credential.
Definition: gmp.c:1720
gmp_create_target_opts_t
Struct holding options for gmp create_target command.
Definition: gmp.h:194
gmp_get_system_reports
int gmp_get_system_reports(gnutls_session_t *, const char *, int, entity_t *)
Get system reports.
Definition: gmp.c:1965
gmp_get_report_opts_t::max_results
int max_results
Maximum number of results to return.
Definition: gmp.h:53