Greenbone Vulnerability Manager
22.4.0~dev1
|
GVM GMP layer: License information. More...
Data Structures | |
struct | get_license_t |
The get_license command. More... | |
struct | modify_license_t |
The modify_license command. More... | |
Macros | |
#define | G_LOG_DOMAIN "md gmp" |
GLib log domain. | |
Functions | |
static void | get_license_reset () |
Reset command data. | |
void | get_license_start (gmp_parser_t *gmp_parser, const gchar **attribute_names, const gchar **attribute_values) |
Start a command. More... | |
void | get_license_element_start (gmp_parser_t *gmp_parser, const gchar *name, const gchar **attribute_names, const gchar **attribute_values) |
Start element. More... | |
static void | buffer_license_content_xml (GString *response, theia_license_t *license_data) |
Writes license data to a GString as XML. More... | |
static void | get_license_run (gmp_parser_t *gmp_parser, GError **error) |
Execute command. More... | |
int | get_license_element_end (gmp_parser_t *gmp_parser, GError **error, const gchar *name) |
End element. More... | |
void | get_license_element_text (const gchar *text, gsize text_len) |
Add text to element. More... | |
static void | modify_license_reset () |
Reset command data. | |
void | modify_license_start (gmp_parser_t *gmp_parser, const gchar **attribute_names, const gchar **attribute_values) |
Start a command. More... | |
void | modify_license_element_start (gmp_parser_t *gmp_parser, const gchar *name, const gchar **attribute_names, const gchar **attribute_values) |
Start element. More... | |
static int | modify_license (gchar *file_content, gboolean allow_empty, char **error_msg) |
Handles modifying the license. More... | |
static void | modify_license_run (gmp_parser_t *gmp_parser, GError **error) |
Execute command. More... | |
int | modify_license_element_end (gmp_parser_t *gmp_parser, GError **error, const gchar *name) |
End element. More... | |
void | modify_license_element_text (const gchar *text, gsize text_len) |
Add text to element. More... | |
Variables | |
static get_license_t | get_license_data |
Parser callback data. More... | |
static modify_license_t | modify_license_data |
Parser callback data. More... | |
GVM GMP layer: License information.
This includes function and variable definitions for GMP handling of license information.
|
static |
Writes license data to a GString as XML.
[in] | response | The GString buffer to write the license content to. |
[in] | license_data | The license data struct to get the data from. |
int get_license_element_end | ( | gmp_parser_t * | gmp_parser, |
GError ** | error, | ||
const gchar * | name | ||
) |
End element.
[in] | gmp_parser | GMP parser. |
[in] | error | Error parameter. |
[in] | name | Element name. |
void get_license_element_start | ( | gmp_parser_t * | gmp_parser, |
const gchar * | name, | ||
const gchar ** | attribute_names, | ||
const gchar ** | attribute_values | ||
) |
Start element.
[in] | gmp_parser | GMP parser. |
[in] | name | Element name. |
[in] | attribute_names | All attribute names. |
[in] | attribute_values | All attribute values. |
void get_license_element_text | ( | const gchar * | text, |
gsize | text_len | ||
) |
Add text to element.
[in] | text | Text. |
[in] | text_len | Text length. |
|
static |
Execute command.
[in] | gmp_parser | GMP parser. |
[in] | error | Error parameter. |
void get_license_start | ( | gmp_parser_t * | gmp_parser, |
const gchar ** | attribute_names, | ||
const gchar ** | attribute_values | ||
) |
Start a command.
[in] | gmp_parser | GMP parser. |
[in] | attribute_names | All attribute names. |
[in] | attribute_values | All attribute values. |
|
static |
Handles modifying the license.
[in] | file_content | The content of the new license file. |
[in] | allow_empty | Whether to allow an empty file. |
[out] | error_msg | The error message of the license update if any |
int modify_license_element_end | ( | gmp_parser_t * | gmp_parser, |
GError ** | error, | ||
const gchar * | name | ||
) |
End element.
[in] | gmp_parser | GMP parser. |
[in] | error | Error parameter. |
[in] | name | Element name. |
void modify_license_element_start | ( | gmp_parser_t * | gmp_parser, |
const gchar * | name, | ||
const gchar ** | attribute_names, | ||
const gchar ** | attribute_values | ||
) |
Start element.
[in] | gmp_parser | GMP parser. |
[in] | name | Element name. |
[in] | attribute_names | All attribute names. |
[in] | attribute_values | All attribute values. |
void modify_license_element_text | ( | const gchar * | text, |
gsize | text_len | ||
) |
Add text to element.
[in] | text | Text. |
[in] | text_len | Text length. |
|
static |
Execute command.
[in] | gmp_parser | GMP parser. |
[in] | error | Error parameter. |
void modify_license_start | ( | gmp_parser_t * | gmp_parser, |
const gchar ** | attribute_names, | ||
const gchar ** | attribute_values | ||
) |
Start a command.
[in] | gmp_parser | GMP parser. |
[in] | attribute_names | All attribute names. |
[in] | attribute_values | All attribute values. |
|
static |
Parser callback data.
This is initially 0 because it's a global variable.
|
static |
Parser callback data.
This is initially 0 because it's a global variable.