|
OpenVAS Scanner 23.40.3
|


Go to the source code of this file.
Functions | |
| int | get_max_hosts_number (void) |
| int | get_max_checks_number (void) |
| int | process_alive (pid_t) |
| int | data_left (int) |
| void | wait_for_children1 (void) |
| int | is_scanner_only_pref (const char *) |
| int | store_file (struct scan_globals *globals, const char *file, const char *file_hash) |
| Stores a file type preference in a hash table. | |
| int | check_host_still_alive (kb_t, const char *) |
| Check if the hosts is still alive and set it as dead if not. | |
| void | write_script_stats (const char *, const char *, int) |
| Writes scripts stats into a file. | |
| void | write_host_stats (kb_t, const char *, const char *) |
| Reads the script stats from the kb and generate a string in json format to be stored in the disk. | |
| int check_host_still_alive | ( | kb_t | kb, |
| const char * | hostname ) |
Check if the hosts is still alive and set it as dead if not.
| kb | Host kb where the host is set as dead. |
Definition at line 33 of file heartbeat.c.
References hostname, and kb_item_set_int_with_main_kb_check().
Referenced by nasl_end_denial(), and update_running_processes().


| int data_left | ( | int | soc | ) |
| int get_max_checks_number | ( | void | ) |
Get the max number of plugins to launch against the remote host at the same time
Definition at line 168 of file utils.c.
References global_max_checks.
Referenced by attack_network(), and pluginlaunch_init().

| int get_max_hosts_number | ( | void | ) |
Get the max number of hosts to test at the same time.
Definition at line 137 of file utils.c.
References global_max_hosts.
Referenced by attack_network().

| int is_scanner_only_pref | ( | const char * | pref | ) |
Definition at line 238 of file utils.c.
Referenced by overwrite_openvas_prefs_with_prefs_from_client().

| int process_alive | ( | pid_t | pid | ) |
Determines if a process is alive - as reliably as we can
Definition at line 198 of file utils.c.
References pid.
Referenced by attack_host(), next_free_process(), and update_running_processes().

| int store_file | ( | struct scan_globals * | globals, |
| const char * | file, | ||
| const char * | file_hash ) |
Stores a file type preference in a hash table.
| globals | Global struct. |
| file | File content. |
| file_hash | hash to reference the file. |
Definition at line 104 of file utils.c.
References files_add_size_translation(), and files_add_translation().
Referenced by overwrite_openvas_prefs_with_prefs_from_client().


| void wait_for_children1 | ( | void | ) |
| void write_host_stats | ( | kb_t | kb, |
| const char * | scan_id, | ||
| const char * | ip ) |
Reads the script stats from the kb and generate a string in json format to be stored in the disk.
| kb | the host knowledge base to get the information from. |
| scan_id | Scan ID for the file name. |
| ip | target IP address. |
Definition at line 308 of file utils.c.
References scan_id, and write_script_stats().
Referenced by attack_host().


| void write_script_stats | ( | const char * | buf, |
| const char * | path, | ||
| int | mode ) |
Writes scripts stats into a file.
| buf | String to write. |
| path | Path to the file to write into. |
| mode | 2 to create the file, 0 to append text to the file, 1 to finish the json list removing the trailing comma before appending the last text in the buffer. |
Definition at line 271 of file utils.c.
Referenced by attack_network(), and write_host_stats().
