Debian Codegraph @

src/OVAL/oval_probe_ext.h

raw symbols SCIP
1 /*
2 * Copyright 2010 Red Hat Inc., Durham, North Carolina.
3 * All Rights Reserved.
4 *
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
9 *
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
14 *
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this library; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
18 *
19 * Authors:
20 * "Daniel Kopecek" <[email protected]>
21 */
22 #ifndef OVAL_PROBE_EXT_H
23 #define OVAL_PROBE_EXT_H
24
25 #include "_seap.h"
26 #include <pthread.h>
27 #include <stdbool.h>
28 #include "oval_probe_impl.h"
29 #include "oval_system_characteristics_impl.h"
30 #include "common/util.h"
31
32 typedef struct {
33 oval_subtype_t subtype;
34 int sd;
35 char *uri;
36 } oval_pd_t;
37
38 typedef struct {
39 oval_pd_t **memb;
40 size_t count;
41 SEAP_CTX_t *ctx;
42 } oval_pdtbl_t;
43
44 struct oval_pext {
45 pthread_mutex_t lock;
46 bool do_init;
47
48 SEAP_CTX_t *sctx;
49 oval_pdtbl_t *pdtbl;
50
51 void *sess_ptr;
52 struct oval_syschar_model **model;
53 };
54
55 typedef struct oval_pext oval_pext_t;
56
57 oval_pext_t *oval_pext_new(void);
58 void oval_pext_free(oval_pext_t *pext);
59 int oval_probe_ext_init(oval_pext_t *pext);
60 int oval_probe_ext_eval(SEAP_CTX_t *ctx, oval_pd_t *pd, oval_pext_t *pext, struct oval_syschar *syschar, int flags);
61 int oval_probe_ext_reset(SEAP_CTX_t *ctx, oval_pd_t *pd, oval_pext_t *pext);
62 int oval_probe_ext_abort(SEAP_CTX_t *ctx, oval_pd_t *pd, oval_pext_t *pext);
63
64 int oval_probe_ext_handler(oval_subtype_t type, void *ptr, int act, ...);
65 int oval_probe_sys_handler(oval_subtype_t type, void *ptr, int act, ...);
66
67 #endif /* OVAL_PROBE_EXT_H */