]> git.ipfire.org Git - thirdparty/strongswan.git/blob - src/libimcv/swid_gen/swid_gen_info.h
Update copyright headers after acquisition by secunet
[thirdparty/strongswan.git] / src / libimcv / swid_gen / swid_gen_info.h
1 /*
2 * Copyright (C) 2017 Andreas Steffen
3 *
4 * Copyright (C) secunet Security Networks AG
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 sw_collector sw-collector
19 *
20 * @defgroup swid_gen_info_t swid_gen_info
21 * @{ @ingroup sw_collector
22 */
23
24 #ifndef SWID_GEN_INFO_H_
25 #define SWID_GEN_INFO_H_
26
27 typedef struct swid_gen_info_t swid_gen_info_t;
28
29 #include "imc/imc_os_info.h"
30
31 struct swid_gen_info_t {
32
33 /**
34 * Get OS type
35 *
36 * @return OS type
37 */
38 os_type_t (*get_os_type)(swid_gen_info_t *this);
39
40 /**
41 * Get OS and product strings
42 *
43 * @param product Product string 'Name Version Arch'
44 * @return OS string 'Name_Version-Arch'
45 */
46 char* (*get_os)(swid_gen_info_t *this, char **product);
47
48 /**
49 * Create software identifier including tagCreator and OS
50 *
51 * @param package Package string
52 * @param version Version string
53 * @return Software Identifier string
54 */
55 char* (*create_sw_id)(swid_gen_info_t *this, char *package,
56 char *version);
57
58 /**
59 * Destroy swid_gen_info_t object
60 */
61 void (*destroy)(swid_gen_info_t *this);
62
63 };
64
65 /**
66 * Create an swid_gen_info_t instance
67 */
68 swid_gen_info_t* swid_gen_info_create(void);
69
70 #endif /** SWID_GEN_INFO_H_ @}*/