OpenVAS Libraries
4.0+rc3.SVN
Main Page
Related Pages
Data Structures
Files
File List
Globals
misc
kb.h
1
/* OpenVAS
2
* $Id$
3
* Description: Header file for module kb.
4
*
5
* Authors:
6
* Renaud Deraison <deraison@nessus.org> (Original pre-fork development)
7
*
8
* Copyright:
9
* Based on work Copyright (C) 1998 - 2007 Tenable Network Security, Inc.
10
*
11
* This library is free software; you can redistribute it and/or
12
* modify it under the terms of the GNU Library General Public
13
* License as published by the Free Software Foundation; either
14
* version 2 of the License, or (at your option) any later version.
15
*
16
* This library 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 GNU
19
* Library 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 OPENVAS_KB_H
27
#define OPENVAS_KB_H
28
29
/* this define can be removed, once openvas-plugins 1.0.5 is mandatory
30
minimum version */
31
#define NEW_KB_MGMT
32
37
#define KB_TYPE_INT ARG_INT
38
42
#define KB_TYPE_STR ARG_STRING
43
48
struct
kb_item
49
{
50
char
*
name
;
51
char
type
;
54
union
55
{
56
char
*v_str;
57
int
v_int;
58
}
v
;
59
struct
kb_item
*
next
;
60
};
61
62
struct
kb_item
**
kb_new
();
63
struct
kb_item
*
kb_item_get_single
(
struct
kb_item
**,
char
*,
int
);
64
char
*
kb_item_get_str
(
struct
kb_item
**,
char
*);
65
int
kb_item_get_int
(
struct
kb_item
**,
char
*);
66
struct
kb_item
*
kb_item_get_all
(
struct
kb_item
**,
char
*);
67
struct
kb_item
*
kb_item_get_pattern
(
struct
kb_item
**,
char
*);
68
void
kb_item_get_all_free
(
struct
kb_item
*);
69
70
int
kb_item_add_str
(
struct
kb_item
**,
char
*,
char
*);
71
int
kb_item_set_str (
struct
kb_item
**,
char
*,
char
*);
72
int
kb_item_add_int (
struct
kb_item
**,
char
*,
int
);
73
int
kb_item_set_int (
struct
kb_item
**,
char
*,
int
);
74
void
kb_item_rm_all (
struct
kb_item
**,
char
*);
75
76
struct
arglist
*
plug_get_oldstyle_kb
(
struct
arglist
*);
77
78
#endif
Generated by
1.8.1.1