]> git.ipfire.org Git - thirdparty/strongswan.git/blob - src/libcharon/plugins/eap_sim_file/eap_sim_file_triplets.h
Update copyright headers after acquisition by secunet
[thirdparty/strongswan.git] / src / libcharon / plugins / eap_sim_file / eap_sim_file_triplets.h
1 /*
2 * Copyright (C) 2008 Martin Willi
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 eap_sim_file_triplets eap_sim_file_triplets
19 * @{ @ingroup eap_sim_file
20 */
21
22 #ifndef EAP_SIM_FILE_TRIPLETS_H_
23 #define EAP_SIM_FILE_TRIPLETS_H_
24
25 #include <collections/enumerator.h>
26
27 typedef struct eap_sim_file_triplets_t eap_sim_file_triplets_t;
28
29 /**
30 * Reads triplets from a triplets.dat file.
31 *
32 * The file is in freeradius triplet file syntax:
33 * http://www.freeradius.org/radiusd/doc/rlm_sim_triplets
34 */
35 struct eap_sim_file_triplets_t {
36
37 /**
38 * Create an enumerator over the file's triplets.
39 *
40 * @return enumerator over (identity, rand, sres, kc)
41 */
42 enumerator_t* (*create_enumerator)(eap_sim_file_triplets_t *this);
43
44 /**
45 * Destroy a eap_sim_file_triplets_t.
46 */
47 void (*destroy)(eap_sim_file_triplets_t *this);
48 };
49
50 /**
51 * Create a eap_sim_file_triplets instance.
52 *
53 * @param file triplet file to read from
54 */
55 eap_sim_file_triplets_t *eap_sim_file_triplets_create(char *file);
56
57 #endif /** EAP_SIM_FILE_TRIPLETS_H_ @}*/