OpenVAS Libraries
6.0+beta5
Main Page
Related Pages
Data Structures
Files
File List
Globals
base
severity_filter.h
Go to the documentation of this file.
1
/* OpenVAS-Client
2
*
3
* Description: Structures and protos for Severity Filters
4
*
5
* Authors:
6
* Jan-Oliver Wagner <jan-oliver.wagner@greenbone.net>
7
*
8
* Copyright:
9
* Copyright (C) 2009 Greenbone Networks GmbH
10
*
11
* This program is free software; you can redistribute it and/or modify
12
* it under the terms of the GNU General Public License version 2,
13
* or, at your option, any later version as published by the Free
14
* Software Foundation
15
*
16
* This program is distributed in the hope that it will be useful,
17
* but WITHOUT ANY WARRANTY; without even the implied warranty of
18
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19
* GNU General Public License for more details.
20
*
21
* You should have received a copy of the GNU General Public License
22
* along with this program; if not, write to the Free Software
23
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
24
*/
25
26
#ifndef _UTIL_SEVERITYFILTER_H
27
#define _UTIL_SEVERITYFILTER_H
28
29
#include <glib.h>
30
34
typedef
struct
severity_filter
35
{
36
gchar *
name
;
37
gchar *
filename
;
38
GSList *
overrides
;
39
}
severity_filter_t
;
40
41
/* temporary, should be part of the global context */
42
extern
severity_filter_t
*
global_filter
;
43
58
typedef
struct
severity_override
59
{
60
gchar *
name
;
61
gchar *
host
;
62
gchar *
port
;
64
gchar *
OID
;
65
gchar *
reason
;
66
gchar *
severity_from
;
67
gchar *
severity_to
;
68
gboolean
active
;
69
}
severity_override_t
;
70
71
72
severity_filter_t
*
severity_filter_new
(
const
gchar *,
const
gchar *);
73
void
severity_filter_free
(
severity_filter_t
*);
74
gboolean
severity_filter_contains_conflicting_override
(
const
severity_filter_t
75
* filter,
76
const
77
severity_override_t
*
78
override
);
79
gboolean
severity_filter_contains_conflicting
(
const
severity_filter_t
* filter,
80
const
gchar * host,
81
const
gchar * port,
82
const
gchar * oid,
83
const
gchar * from);
84
gboolean
severity_filter_add
(
severity_filter_t
*,
const
severity_override_t
*);
85
const
gchar *
severity_filter_apply
(
const
gchar *,
const
gchar *,
const
gchar *,
86
const
gchar *);
87
gboolean
severity_filter_remove
(
severity_filter_t
* filter,
88
severity_override_t
*
override
);
89
90
const
severity_override_t
*
severity_override_new
(
const
gchar *,
const
gchar *,
91
const
gchar *,
const
gchar *,
92
const
gchar *,
const
gchar *,
93
const
gchar *, gboolean);
94
const
severity_override_t
*
severity_override_duplicate
(
const
95
severity_override_t
*);
96
void
severity_override_free
(
severity_override_t
*);
97
98
severity_filter_t
*
severity_filter_from_xml
(
const
gchar *);
99
100
#endif
/* _UTIL_SEVERITYFILTER_H */
Generated by
1.8.4