OpenVAS Scanner 23.40.3
pluginlaunch.c File Reference

Manages the launching of plugins within processes. More...

#include "pluginlaunch.h"
#include "../misc/heartbeat.h"
#include "../misc/network.h"
#include "../misc/nvt_categories.h"
#include "../misc/plugutils.h"
#include "pluginload.h"
#include "pluginscheduler.h"
#include "plugs_req.h"
#include "processes.h"
#include "sighand.h"
#include "utils.h"
#include <errno.h>
#include <gvm/base/prefs.h>
#include <gvm/util/nvticache.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <strings.h>
#include <sys/time.h>
#include <sys/wait.h>
#include <unistd.h>
Include dependency graph for pluginlaunch.c:

Go to the source code of this file.

Data Structures

struct  running
 Structure to represent a process in the sense of a running NVT. More...

Macros

#define G_LOG_DOMAIN   "sd main"
 GLib log domain.
#define MAX_PROCESSES   32
 'Hard' limit of the max. number of concurrent plugins per host.

Functions

static int max_nvt_timeouts_reached (void)
 Check if max_nvt_timeouts is set and if has been reached.
static void update_running_processes (kb_t main_kb, kb_t kb)
static int common (GSList *list1, GSList *list2)
static GSList * required_ports_in_list (const char *oid, GSList *list)
static int simult_ports (const char *oid, const char *next_oid)
static int next_free_process (kb_t main_kb, kb_t kb, struct scheduler_plugin *upcoming)
void pluginlaunch_init (const char *host)
void pluginlaunch_disable_parallel_checks (void)
void pluginlaunch_enable_parallel_checks (void)
void pluginlaunch_stop (void)
static int plugin_timeout (nvti_t *nvti)
static int get_available_memory ()
static int check_memory ()
static int check_sysload ()
int plugin_launch (struct scan_globals *globals, struct scheduler_plugin *plugin, struct in6_addr *ip, GSList *vhosts, kb_t kb, kb_t main_kb, nvti_t *nvti, int *error)
 Start a plugin.
void pluginlaunch_wait (kb_t main_kb, kb_t kb)
 Waits and 'pushes' processes until num_running_processes is 0.
static int timeout_running_processes (void)
 Return shortest timeout of the running processes.
void pluginlaunch_wait_for_free_process (kb_t main_kb, kb_t kb)
 Waits and 'pushes' processes until the number of running processes has changed.

Variables

int global_min_memory
int global_max_sysload
static struct running processes [MAX_PROCESSES]
static int num_running_processes
static int max_running_processes
static int old_max_running_processes
static GSList * non_simult_ports = NULL
const char * hostname = NULL

Detailed Description

Manages the launching of plugins within processes.

Definition in file pluginlaunch.c.

Macro Definition Documentation

◆ G_LOG_DOMAIN

#define G_LOG_DOMAIN   "sd main"

GLib log domain.

Definition at line 41 of file pluginlaunch.c.

◆ MAX_PROCESSES

#define MAX_PROCESSES   32

'Hard' limit of the max. number of concurrent plugins per host.

Definition at line 46 of file pluginlaunch.c.

Referenced by next_free_process(), pluginlaunch_init(), pluginlaunch_stop(), timeout_running_processes(), and update_running_processes().

Function Documentation

◆ check_memory()

int check_memory ( )
static

Definition at line 443 of file pluginlaunch.c.

444{
445 int available_mem;
446
447 if (global_min_memory <= 0)
448 return 0;
449
450 available_mem = get_available_memory ();
451 if (available_mem == 0 || available_mem > global_min_memory)
452 return 0;
453 return 1;
454}
int global_min_memory
Definition openvas.c:87
static int get_available_memory()

References get_available_memory(), and global_min_memory.

Referenced by pluginlaunch_wait_for_free_process().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ check_sysload()

int check_sysload ( )
static

Definition at line 457 of file pluginlaunch.c.

458{
459 double sysload;
460
461 if (global_max_sysload <= 0)
462 return 0;
463 if (getloadavg (&sysload, 1) < 0 || sysload <= global_max_sysload)
464 return 0;
465 return 1;
466}
int global_max_sysload
Definition openvas.c:88

References global_max_sysload.

Referenced by pluginlaunch_wait_for_free_process().

Here is the caller graph for this function:

◆ common()

int common ( GSList * list1,
GSList * list2 )
static

Definition at line 227 of file pluginlaunch.c.

228{
229 if (!list1 || !list2)
230 return 0;
231
232 while (list1)
233 {
234 GSList *tmp = list2;
235 while (tmp)
236 {
237 if (!strcmp (list1->data, tmp->data))
238 return 1;
239 tmp = tmp->next;
240 }
241 list1 = list1->next;
242 }
243 return 0;
244}

Referenced by simult_ports().

Here is the caller graph for this function:

◆ get_available_memory()

int get_available_memory ( )
static

Definition at line 410 of file pluginlaunch.c.

411{
412 char buf[8192];
413 char *hit = NULL;
414 FILE *fd = NULL;
415 size_t len;
416 memset (buf, 0, sizeof (buf));
417
418 fd = fopen ("/proc/meminfo", "r");
419 if (fd == NULL)
420 {
421 g_warning ("Couldn't open /proc/meminfo");
422 return 0;
423 }
424 len = fread (buf, 1, sizeof (buf) - 1, fd);
425 fclose (fd);
426 // if len is less then 0, then there was an error reading the file
427 // and we should check errno. Currently it is ignored because
428 // the caller just wants to know if memory is available and we asumme
429 // that there is none on error.
430 if (len <= 0)
431 {
432 g_warning ("Couldn't read /proc/meminfo");
433 return 0;
434 }
435 hit = strstr (buf, "MemAvailable:");
436 if (!hit)
437 return 0;
438
439 return atoi (hit + 14) / 1000;
440}
uint8_t len

References len.

Referenced by check_memory().

Here is the caller graph for this function:

◆ max_nvt_timeouts_reached()

int max_nvt_timeouts_reached ( void )
static

Check if max_nvt_timeouts is set and if has been reached.

Returns
1 if reached, 0 if not reached or no set.

Definition at line 76 of file pluginlaunch.c.

77{
78 static int vts_timeouts_counter = 0;
79 int max_vts_timeouts = 0;
80 const gchar *max_vts_timeouts_str = NULL;
81
82 /* Check if set */
83 if ((max_vts_timeouts_str = prefs_get ("max_vts_timeouts")) == NULL)
84 {
85 g_debug ("%s: max_vts_timeouts not set.", __func__);
86 return 0;
87 }
88
89 /* Check if enabled and valid value */
90 max_vts_timeouts = atoi (max_vts_timeouts_str);
91 if (max_vts_timeouts <= 0)
92 {
93 g_debug ("%s: max_vts_timeouts disabled", __func__);
94 return 0;
95 }
96
97 vts_timeouts_counter++;
98 /* Check if reached */
99 if (vts_timeouts_counter >= max_vts_timeouts)
100 return 1;
101
102 return 0;
103}

Referenced by update_running_processes().

Here is the caller graph for this function:

◆ next_free_process()

int next_free_process ( kb_t main_kb,
kb_t kb,
struct scheduler_plugin * upcoming )
static

If another NVT with same port requirements is running, wait.

Returns
ERR_NO_FREE_SLOT if MAX_PROCESSES are running, the index of the first free "slot" in the processes array otherwise.

Definition at line 301 of file pluginlaunch.c.

302{
303 int r;
304
305 for (r = 0; r < MAX_PROCESSES; r++)
306 {
307 if (processes[r].pid > 0
308 && simult_ports (processes[r].plugin->oid, upcoming->oid))
309 {
310 while (process_alive (processes[r].pid))
311 {
313 usleep (250000);
314 }
315 }
316 }
317 for (r = 0; r < MAX_PROCESSES; r++)
318 if (processes[r].pid <= 0)
319 return r;
320 return ERR_NO_FREE_SLOT;
321}
kb_t main_kb
Definition kb_cache.c:15
static pid_t pid
static struct running processes[MAX_PROCESSES]
static int simult_ports(const char *oid, const char *next_oid)
#define MAX_PROCESSES
'Hard' limit of the max. number of concurrent plugins per host.
static void update_running_processes(kb_t main_kb, kb_t kb)
#define ERR_NO_FREE_SLOT
Error for when the process table is full.
int process_alive(pid_t pid)
Definition utils.c:198

References ERR_NO_FREE_SLOT, main_kb, MAX_PROCESSES, scheduler_plugin::oid, pid, process_alive(), processes, simult_ports(), and update_running_processes().

Referenced by plugin_launch().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ plugin_launch()

int plugin_launch ( struct scan_globals * globals,
struct scheduler_plugin * plugin,
struct in6_addr * ip,
GSList * vhosts,
kb_t kb,
kb_t main_kb,
nvti_t * nvti,
int * error )

Start a plugin.

Check for free slots available in the process table. Set error with ERR_NO_FREE_SLOT if the process table is full. Set error with ERR_CANT_FORK if was not possible to fork() a new child.

Returns
PID of process that is connected to the plugin as returned by plugin classes pl_launch function. Less than 0 means there was a problem, but error param should be checked.

Definition at line 480 of file pluginlaunch.c.

483{
484 int p;
485
486 /* Wait for a free slot */
488 p = next_free_process (main_kb, kb, plugin);
489 if (p < 0)
490 {
491 g_warning ("%s. There is currently no free slot available for starting a "
492 "new plugin.",
493 __func__);
494 *error = ERR_NO_FREE_SLOT;
495 return -1;
496 }
497
498 processes[p].plugin = plugin;
499 processes[p].timeout = plugin_timeout (nvti);
500 gettimeofday (&(processes[p].start), NULL);
501 processes[p].pid = nasl_plugin_launch (globals, ip, vhosts, kb, plugin->oid);
502
503 if (processes[p].pid > 0)
505 else
506 {
507 processes[p].plugin->running_state = PLUGIN_STATUS_UNRUN;
508 *error = ERR_CANT_FORK;
509 }
510 return processes[p].pid;
511}
int nasl_plugin_launch(struct scan_globals *globals, struct in6_addr *ip, GSList *vhosts, kb_t kb, const char *oid)
Launch a NASL plugin.
void pluginlaunch_wait_for_free_process(kb_t main_kb, kb_t kb)
Waits and 'pushes' processes until the number of running processes has changed.
static int num_running_processes
static int next_free_process(kb_t main_kb, kb_t kb, struct scheduler_plugin *upcoming)
static int plugin_timeout(nvti_t *nvti)
#define ERR_CANT_FORK
Error for when it is not possible to fork a new plugin process.
@ PLUGIN_STATUS_UNRUN

References ERR_CANT_FORK, ERR_NO_FREE_SLOT, main_kb, nasl_plugin_launch(), next_free_process(), num_running_processes, scheduler_plugin::oid, pid, PLUGIN_STATUS_UNRUN, plugin_timeout(), pluginlaunch_wait_for_free_process(), and processes.

Referenced by launch_plugin().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ plugin_timeout()

int plugin_timeout ( nvti_t * nvti)
static

Definition at line 383 of file pluginlaunch.c.

384{
385 int timeout, tmp;
386 gchar *timeout_str;
387
388 timeout = 0;
389 if ((timeout_str = get_plugin_preference (nvti_oid (nvti), "timeout", 0))
390 != NULL)
391 timeout = atoi (timeout_str);
392
393 if (timeout == 0)
394 {
395 if (nvti_category (nvti) == ACT_SCANNER)
396 {
397 tmp = atoi (prefs_get ("scanner_plugins_timeout"));
398 timeout = tmp ? tmp : SCANNER_NVT_TIMEOUT;
399 }
400 else
401 {
402 tmp = atoi (prefs_get ("plugins_timeout"));
403 timeout = tmp ? tmp : NVT_TIMEOUT;
404 }
405 }
406 return timeout;
407}
@ ACT_SCANNER
char * get_plugin_preference(const char *oid, const char *name, int pref_id)
Get the a plugins preference.
Definition plugutils.c:837

References ACT_SCANNER, and get_plugin_preference().

Referenced by plugin_launch().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ pluginlaunch_disable_parallel_checks()

void pluginlaunch_disable_parallel_checks ( void )

Definition at line 351 of file pluginlaunch.c.

352{
354}
static int max_running_processes

References max_running_processes.

Referenced by get_next_in_range().

Here is the caller graph for this function:

◆ pluginlaunch_enable_parallel_checks()

void pluginlaunch_enable_parallel_checks ( void )

Definition at line 357 of file pluginlaunch.c.

358{
360}
static int old_max_running_processes

References max_running_processes, and old_max_running_processes.

Referenced by get_next_in_range().

Here is the caller graph for this function:

◆ pluginlaunch_init()

void pluginlaunch_init ( const char * host)

Definition at line 324 of file pluginlaunch.c.

325{
326 int i;
327
328 char **split = g_strsplit (prefs_get ("non_simult_ports"), ", ", 0);
329 for (i = 0; split[i]; i++)
330 non_simult_ports = g_slist_prepend (non_simult_ports, g_strdup (split[i]));
331 g_strfreev (split);
334 hostname = host;
335
337 {
338 g_debug ("max_checks (%d) > MAX_PROCESSES (%d) - modify "
339 "openvas/openvas/pluginlaunch.c",
342 }
343
345 bzero (&(processes), sizeof (processes));
346
347 init_kb_usage ();
348}
static GSList * non_simult_ports
const char * hostname
void init_kb_usage(void)
Definition plugutils.c:47
Host information, implemented as doubly linked list.
Definition hosts.c:37
int get_max_checks_number(void)
Definition utils.c:168

References get_max_checks_number(), hostname, init_kb_usage(), MAX_PROCESSES, max_running_processes, non_simult_ports, num_running_processes, old_max_running_processes, and processes.

Referenced by attack_host().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ pluginlaunch_stop()

void pluginlaunch_stop ( void )

Definition at line 363 of file pluginlaunch.c.

364{
365 int i;
366
367 for (i = 0; i < MAX_PROCESSES; i++)
368 {
369 if (processes[i].pid > 0)
370 {
371 /* Since the plugin process is a group leader process
372 * we can send the signal to -PID process to kill
373 * also the plugin's child processes. */
376 processes[i].plugin->running_state = PLUGIN_STATUS_DONE;
377 bzero (&(processes[i]), sizeof (struct running));
378 }
379 }
380}
@ PLUGIN_STATUS_DONE
int terminate_process(pid_t pid)
Terminates a given process. If termination does not work, the process will get killed....
Definition processes.c:96
Structure to represent a process in the sense of a running NVT.

References MAX_PROCESSES, num_running_processes, pid, PLUGIN_STATUS_DONE, processes, and terminate_process().

Referenced by attack_host(), launch_plugin(), pluginlaunch_wait_for_free_process(), and scan_stop_cleanup().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ pluginlaunch_wait()

void pluginlaunch_wait ( kb_t main_kb,
kb_t kb )

Waits and 'pushes' processes until num_running_processes is 0.

Definition at line 517 of file pluginlaunch.c.

518{
520 {
523 waitpid (-1, NULL, 0);
524 }
525}

References main_kb, num_running_processes, and update_running_processes().

Referenced by attack_host().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ pluginlaunch_wait_for_free_process()

void pluginlaunch_wait_for_free_process ( kb_t main_kb,
kb_t kb )

Waits and 'pushes' processes until the number of running processes has changed.

Definition at line 550 of file pluginlaunch.c.

551{
553 return;
555 /* Max number of processes are still running, wait for a child to exit or
556 * to timeout. */
557
559 g_debug ("%s. Number of running processes >= maximum running processes (%d "
560 ">= %d). "
561 "Waiting for free slot for processes.",
563
564 /* Be careful with changing the max_running_process value.
565 * The plugin scheduler can change this value for running one plugin at
566 * time. */
567 while (
569 || (num_running_processes > 0 && (check_memory () || check_sysload ())))
570 {
571 sigset_t mask;
572 struct timespec ts = {0, 0};
573
574 ts.tv_sec = timeout_running_processes ();
575 assert (ts.tv_sec);
576 sigemptyset (&mask);
577 sigaddset (&mask, SIGCHLD);
578 sigaddset (&mask, SIGUSR1);
579 /* Wait here for the shortest plugins timeout or for a child which ended.
580 * Also, it handles signal SIGUSR1 to stop a scan. Otherwise the signa is
581 * ignored, the plugin is never stopped and the scanner keeps waiting. */
582 int sig = sigtimedwait (&mask, NULL, &ts);
583 if (sig < 0 && errno != EAGAIN)
584 g_warning ("%s: %s (%d)", __func__, strerror (errno), errno);
585 else if (sig == SIGUSR1)
586 {
587 /* SIGUSR1 signal is sent during scan stop to all host processes.
588 Therefore pluginlaunch_stop() is called here, for the
589 special case in which we are waiting for the last plugin, of the
590 last host, to finish.
591 */
593 }
594 // cleanup ipcc cache
597 }
598}
static int check_memory()
static int check_sysload()
void pluginlaunch_stop(void)
static int timeout_running_processes(void)
Return shortest timeout of the running processes.
int procs_cleanup_children(void)
iterates through ipcc and verify if a child is stopped or killed to free the file handler.
Definition processes.c:47

References check_memory(), check_sysload(), main_kb, max_running_processes, num_running_processes, pluginlaunch_stop(), procs_cleanup_children(), timeout_running_processes(), and update_running_processes().

Referenced by attack_host(), and plugin_launch().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ required_ports_in_list()

GSList * required_ports_in_list ( const char * oid,
GSList * list )
static

Definition at line 247 of file pluginlaunch.c.

248{
249 GSList *common_ports = NULL;
250 char **array, *ports;
251 int i;
252
253 if (!oid || !list)
254 return 0;
255 ports = nvticache_get_required_ports (oid);
256 if (!ports)
257 return 0;
258 array = g_strsplit (ports, ", ", 0);
259 g_free (ports);
260 if (!array)
261 return 0;
262
263 for (i = 0; array[i]; i++)
264 {
265 GSList *tmp = list;
266 while (tmp)
267 {
268 if (!strcmp (tmp->data, array[i]))
269 common_ports = g_slist_prepend (common_ports, g_strdup (tmp->data));
270 tmp = tmp->next;
271 }
272 }
273
274 g_strfreev (array);
275 return common_ports;
276}
const char * oid

References oid.

Referenced by simult_ports().

Here is the caller graph for this function:

◆ simult_ports()

int simult_ports ( const char * oid,
const char * next_oid )
static

Definition at line 279 of file pluginlaunch.c.

280{
281 int ret = 0;
282 GSList *common_ports1 = NULL, *common_ports2 = NULL;
283
285 if (common_ports1)
286 common_ports2 = required_ports_in_list (next_oid, non_simult_ports);
287 if (common_ports1 && common_ports2 && common (common_ports1, common_ports2))
288 ret = 1;
289 g_slist_free_full (common_ports1, g_free);
290 g_slist_free_full (common_ports2, g_free);
291 return ret;
292}
static int common(GSList *list1, GSList *list2)
static GSList * required_ports_in_list(const char *oid, GSList *list)

References common(), non_simult_ports, oid, and required_ports_in_list().

Referenced by next_free_process().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ timeout_running_processes()

int timeout_running_processes ( void )
static

Return shortest timeout of the running processes.

Definition at line 531 of file pluginlaunch.c.

532{
533 int i, timeout = 0;
534
535 for (i = 0; i < MAX_PROCESSES; i++)
536 {
537 if (processes[i].pid <= 0)
538 continue;
539 if (!timeout || processes[i].timeout < timeout)
540 timeout = processes[i].timeout;
541 }
542 return timeout;
543}

References MAX_PROCESSES, pid, and processes.

Referenced by pluginlaunch_wait_for_free_process().

Here is the caller graph for this function:

◆ update_running_processes()

void update_running_processes ( kb_t main_kb,
kb_t kb )
static

Definition at line 109 of file pluginlaunch.c.

110{
111 int i;
112 struct timeval now;
113 int log_whole = prefs_get_bool ("log_whole_attack");
114
115 if (num_running_processes == 0)
116 return;
117
118 gettimeofday (&now, NULL);
119 for (i = 0; i < MAX_PROCESSES; i++)
120 {
121 if (processes[i].pid > 0)
122 {
123 int is_alive = process_alive (processes[i].pid);
124 int ret_terminate = 0;
125
126 // If process dead or timed out
127 if (!is_alive
128 || (processes[i].timeout > 0
129 && ((now.tv_sec - processes[i].start.tv_sec)
130 > processes[i].timeout)))
131 {
132 char *oid = processes[i].plugin->oid;
133
134 if (is_alive) // Alive and timed out
135 {
136 char msg[2048];
137 if (log_whole)
138 g_message ("%s (pid %d) is slow to finish - killing it",
139 oid, processes[i].pid);
140
141 g_snprintf (msg, sizeof (msg),
142 "ERRMSG|||%s||| |||general/tcp|||%s|||"
143 "NVT timed out after %d seconds.",
144 hostname, oid ? oid : " ", processes[i].timeout);
146 "internal/results", msg);
147
148 /* Check for max VTs timeouts */
150 {
151 /* Check if host is still alive and send a message
152 if it is dead. */
153 if (check_host_still_alive (kb, hostname) == 0)
154 {
155 g_snprintf (msg, sizeof (msg),
156 "ERRMSG|||%s||| |||general/tcp||| |||"
157 "Host has been marked as dead. Too many "
158 "NVT_TIMEOUTs.",
159 hostname);
161 main_kb, "internal/results", msg);
162 }
163 }
164
165 ret_terminate = terminate_process (processes[i].pid);
166 if (ret_terminate == 0)
167 {
168 /* Since the plugin process is a group leader process
169 * we can send the signal to -PID process to kill
170 * also the plugin's child processes. */
173 processes[i].plugin->running_state = PLUGIN_STATUS_DONE;
174 bzero (&(processes[i]), sizeof (processes[i]));
175 }
176 }
177 else
178 {
179 struct timeval old_now = now;
180 int e;
181 if (now.tv_usec < processes[i].start.tv_usec)
182 {
183 processes[i].start.tv_sec++;
184 now.tv_usec += 1000000;
185 }
186
187 if (log_whole)
188 {
189 char *name = nvticache_get_filename (oid);
190 g_message (
191 "%s (%s) [%d] finished its job in %ld.%.3ld seconds",
192 name, oid, processes[i].pid,
193 (long) (now.tv_sec - processes[i].start.tv_sec),
194 (long) ((now.tv_usec - processes[i].start.tv_usec)
195 / 1000));
196 g_free (name);
197
198 char msg[2048];
199 g_snprintf (msg, sizeof (msg), "%s/%ld/%ld", oid,
200 (long) ((now.tv_sec * 1000)
201 + (long) (now.tv_usec / 1000)),
202 (long) (processes[i].start.tv_sec * 1000
203 + processes[i].start.tv_usec / 1000));
204 kb_item_push_str (kb, "general/script_stats", msg);
205 }
206 now = old_now;
207 do
208 {
209 e = waitpid (processes[i].pid, NULL, 0);
210 }
211 while (e < 0 && errno == EINTR);
212
213 /* Since the plugin process is a group leader process
214 * we can send the signal to -PID process to kill
215 * also the plugin's child processes. */
218 processes[i].plugin->running_state = PLUGIN_STATUS_DONE;
219 bzero (&(processes[i]), sizeof (processes[i]));
220 }
221 }
222 }
223 }
224}
static struct timeval timeval(unsigned long val)
const char * name
Definition nasl_init.c:440
static int max_nvt_timeouts_reached(void)
Check if max_nvt_timeouts is set and if has been reached.
int kb_item_push_str_with_main_kb_check(kb_t kb, const char *name, const char *value)
Check if the current kb corresponds to the original scanid, if it matches it kb_item_push_str....
Definition plugutils.c:533
int check_host_still_alive(kb_t, const char *)
Check if the hosts is still alive and set it as dead if not.
Definition heartbeat.c:33

References check_host_still_alive(), hostname, kb_item_push_str_with_main_kb_check(), main_kb, max_nvt_timeouts_reached(), MAX_PROCESSES, name, num_running_processes, oid, pid, PLUGIN_STATUS_DONE, process_alive(), processes, terminate_process(), and timeval().

Referenced by next_free_process(), pluginlaunch_wait(), and pluginlaunch_wait_for_free_process().

Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ global_max_sysload

int global_max_sysload
extern

Definition at line 88 of file openvas.c.

Referenced by check_sysload(), and set_globals_from_preferences().

◆ global_min_memory

int global_min_memory
extern

Definition at line 87 of file openvas.c.

Referenced by check_memory(), and set_globals_from_preferences().

◆ hostname

◆ max_running_processes

◆ non_simult_ports

GSList* non_simult_ports = NULL
static

Definition at line 67 of file pluginlaunch.c.

Referenced by pluginlaunch_init(), and simult_ports().

◆ num_running_processes

◆ old_max_running_processes

int old_max_running_processes
static

Definition at line 66 of file pluginlaunch.c.

Referenced by pluginlaunch_enable_parallel_checks(), and pluginlaunch_init().

◆ processes