Annotation of embedaddon/strongswan/src/libcharon/processing/jobs/inactivity_job.h, revision 1.1.1.1
1.1 misho 1: /*
2: * Copyright (C) 2010 Martin Willi
3: * HSR Hochschule fuer Technik Rapperswil
4: *
5: * This program is free software; you can redistribute it and/or modify it
6: * under the terms of the GNU General Public License as published by the
7: * Free Software Foundation; either version 2 of the License, or (at your
8: * option) any later version. See <http://www.fsf.org/copyleft/gpl.txt>.
9: *
10: * This program is distributed in the hope that it will be useful, but
11: * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
12: * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
13: * for more details.
14: */
15:
16: /**
17: * @defgroup inactivity_job inactivity_job
18: * @{ @ingroup cjobs
19: */
20:
21: #ifndef INACTIVITY_JOB_H_
22: #define INACTIVITY_JOB_H_
23:
24: #include <library.h>
25: #include <processing/jobs/job.h>
26:
27: typedef struct inactivity_job_t inactivity_job_t;
28:
29: /**
30: * Job checking for inactivity of CHILD_SA to close them.
31: *
32: * The inactivity job reschedules itself to check CHILD_SAs periodically.
33: */
34: struct inactivity_job_t {
35:
36: /**
37: * Implements job_t.
38: */
39: job_t job_interface;
40: };
41:
42: /**
43: * Create a inactivity_job instance.
44: *
45: * @param unique_id unique CHILD_SA identifier to check for inactivity
46: * @param timeout inactivity timeout in s
47: * @param close_ike close IKE_SA if the last remaining CHILD_SA is inactive?
48: * @return inactivity checking job
49: */
50: inactivity_job_t *inactivity_job_create(uint32_t unique_id, uint32_t timeout,
51: bool close_ike);
52:
53: #endif /** INACTIVITY_JOB_H_ @}*/
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>