implement ipsec pool -showattr function
[strongswan.git] / src / libhydra / plugins / attr_sql / pool_attributes.h
1 /*
2 * Copyright (C) 2009-2010 Andreas Steffen
3 * Hochschule fuer Technik Rapperswil
4 *
5 * This program is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License as published by the
7 * Free Software Foundation; either version 2 of the License, or (at your
8 * option) any later version. See <http://www.fsf.org/copyleft/gpl.txt>.
9 *
10 * This program is distributed in the hope that it will be useful, but
11 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
12 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
13 * for more details.
14 */
15
16 #ifndef POOL_ATTRIBUTES_H_
17 #define POOL_ATTRIBUTES_H_
18
19 #include <attributes/attributes.h>
20
21 typedef enum value_type_t value_type_t;
22
23 enum value_type_t {
24 VALUE_NONE,
25 VALUE_HEX,
26 VALUE_STRING,
27 VALUE_ADDR,
28 VALUE_SUBNET
29 };
30
31 /**
32 * enum names for value_type_t.
33 */
34 extern enum_name_t *value_type_names;
35
36 /**
37 * ipsec pool --addattr <type> - add attribute entry
38 */
39 void add_attr(char *name, char *value, value_type_t value_type);
40
41 /**
42 * ipsec pool --delattr <type> - delete attribute entry
43 */
44 void del_attr(char *name, char *value, value_type_t value_type);
45
46 /**
47 * ipsec pool --statusattr - show all attribute entries
48 */
49 void status_attr(void);
50
51 /**
52 * ipsec pool --showattr - show all supported attribute keywords
53 */
54 void show_attr(void);
55
56 #endif /* POOL_ATTRIBUTES_H_ */
57
58