]> git.ipfire.org Git - thirdparty/strongswan.git/blame - src/libcharon/plugins/ha/ha_attribute.h
Update copyright headers after acquisition by secunet
[thirdparty/strongswan.git] / src / libcharon / plugins / ha / ha_attribute.h
CommitLineData
98d03438
MW
1/*
2 * Copyright (C) 2010 Martin Willi
19ef2aec
TB
3 *
4 * Copyright (C) secunet Security Networks AG
98d03438
MW
5 *
6 * This program is free software; you can redistribute it and/or modify it
7 * under the terms of the GNU General Public License as published by the
8 * Free Software Foundation; either version 2 of the License, or (at your
9 * option) any later version. See <http://www.fsf.org/copyleft/gpl.txt>.
10 *
11 * This program is distributed in the hope that it will be useful, but
12 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
13 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
14 * for more details.
15 */
16
17/**
18 * @defgroup ha_attribute ha_attribute
19 * @{ @ingroup ha
20 */
21
22#ifndef HA_ATTRIBUTE_H_
23#define HA_ATTRIBUTE_H_
24
25#include "ha_kernel.h"
26#include "ha_segments.h"
27
28#include <attributes/attribute_provider.h>
29
30typedef struct ha_attribute_t ha_attribute_t;
31
32/**
33 * A HA enabled in memory address pool attribute provider.
34 */
35struct ha_attribute_t {
36
37 /**
38 * Implements attribute provider interface.
39 */
40 attribute_provider_t provider;
41
42 /**
43 * Reserve an address for a passive IKE_SA.
44 *
45 * @param name pool name to reserve address in
46 * @param address address to reserve
47 */
48 void (*reserve)(ha_attribute_t *this, char *name, host_t *address);
49
50 /**
51 * Destroy a ha_attribute_t.
52 */
53 void (*destroy)(ha_attribute_t *this);
54};
55
56/**
57 * Create a ha_attribute instance.
58 */
59ha_attribute_t *ha_attribute_create(ha_kernel_t *kernel, ha_segments_t *segments);
60
61#endif /** HA_ATTRIBUTE_H_ @}*/