]>
Commit | Line | Data |
---|---|---|
45f76a7d MW |
1 | /** |
2 | * @file acquire_job.h | |
3 | * | |
4 | * @brief Interface of acquire_job_t. | |
5 | * | |
6 | */ | |
7 | ||
8 | /* | |
9 | * Copyright (C) 2006 Martin Willi | |
10 | * Hochschule fuer Technik Rapperswil | |
11 | * | |
12 | * This program is free software; you can redistribute it and/or modify it | |
13 | * under the terms of the GNU General Public License as published by the | |
14 | * Free Software Foundation; either version 2 of the License, or (at your | |
15 | * option) any later version. See <http://www.fsf.org/copyleft/gpl.txt>. | |
16 | * | |
17 | * This program is distributed in the hope that it will be useful, but | |
18 | * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY | |
19 | * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License | |
20 | * for more details. | |
21 | */ | |
22 | ||
23 | #ifndef ACQUIRE_JOB_H_ | |
24 | #define ACQUIRE_JOB_H_ | |
25 | ||
382b4817 MW |
26 | typedef struct acquire_job_t acquire_job_t; |
27 | ||
db7ef624 | 28 | #include <library.h> |
e0fe7651 | 29 | #include <processing/jobs/job.h> |
45f76a7d | 30 | |
45f76a7d MW |
31 | /** |
32 | * @brief Class representing an ACQUIRE Job. | |
33 | * | |
34 | * This job initiates a CHILD SA on kernel request. | |
35 | * | |
36 | * @b Constructors: | |
37 | * - acquire_job_create() | |
38 | * | |
39 | * @ingroup jobs | |
40 | */ | |
41 | struct acquire_job_t { | |
42 | /** | |
43 | * The job_t interface. | |
44 | */ | |
45 | job_t job_interface; | |
46 | }; | |
47 | ||
48 | /** | |
49 | * @brief Creates a job of type ACQUIRE. | |
50 | * | |
51 | * We use the reqid to find the routed CHILD_SA. | |
52 | * | |
53 | * @param reqid reqid of the CHILD_SA to acquire | |
54 | * @return acquire_job_t object | |
55 | * | |
56 | * @ingroup jobs | |
57 | */ | |
58 | acquire_job_t *acquire_job_create(u_int32_t reqid); | |
59 | ||
60 | #endif /* REKEY_CHILD_SA_JOB_H_ */ |