]> git.ipfire.org Git - thirdparty/strongswan.git/blame - src/libimcv/ita/ita_attr_command.h
Update copyright headers after acquisition by secunet
[thirdparty/strongswan.git] / src / libimcv / ita / ita_attr_command.h
CommitLineData
510f37ab 1/*
e77df5a1 2 * Copyright (C) 2011-2014 Andreas Steffen
19ef2aec
TB
3 *
4 * Copyright (C) secunet Security Networks AG
510f37ab
AS
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/**
11adf114
TB
18 * @defgroup ita_attr_command ita_attr_command
19 * @{ @ingroup ita_attr
510f37ab
AS
20 */
21
22#ifndef ITA_ATTR_COMMAND_H_
23#define ITA_ATTR_COMMAND_H_
24
25typedef struct ita_attr_command_t ita_attr_command_t;
26
27#include "pa_tnc/pa_tnc_attr.h"
28
510f37ab
AS
29/**
30 * Class implementing the ITA Command PA-TNC attribute.
31 *
32 */
33struct ita_attr_command_t {
34
35 /**
36 * Public PA-TNC attribute interface
37 */
38 pa_tnc_attr_t pa_tnc_attribute;
39
40 /**
41 * Get the ITA command string
42 *
43 * @return ITA command string
44 */
45 char* (*get_command)(ita_attr_command_t *this);
46};
47
48/**
49 * Creates an ita_attr_command_t object from a command string
50 *
51 * @param command ITA command string
52 */
53pa_tnc_attr_t* ita_attr_command_create(char *command);
54
55/**
56 * Creates an ita_attr_command_t object from received data
57 *
e77df5a1
AS
58 * @param length Total length of attribute value
59 * @param value Unparsed attribute value (might be a segment)
510f37ab 60 */
e77df5a1 61pa_tnc_attr_t* ita_attr_command_create_from_data(size_t length, chunk_t value);
510f37ab
AS
62
63#endif /** ITA_ATTR_COMMAND_H_ @}*/