00001
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031 #ifndef OPENSCAP_CHECK_ENGINE_PLUGIN_H_
00032 #define OPENSCAP_CHECK_ENGINE_PLUGIN_H_
00033
00034 #include "xccdf_policy.h"
00035
00036 struct check_engine_plugin_def
00037 {
00038 int _reserved;
00039
00040 void *module_handle;
00041 void *user_data;
00042
00043
00044
00045
00046 int (*register_fn)(struct xccdf_policy_model *, const char*, void**);
00047
00048 int (*cleanup_fn)(struct xccdf_policy_model *, void**);
00049
00050 int (*export_results_fn)(struct xccdf_policy_model *, bool, const char*, void**);
00051
00052 const char *(*get_capabilities_fn)(void**);
00053 };
00054
00055 struct check_engine_plugin_def *check_engine_plugin_load2(const char* path, bool quiet);
00056 struct check_engine_plugin_def *check_engine_plugin_load(const char* path);
00057 void check_engine_plugin_unload(struct check_engine_plugin_def *plugin);
00058
00059 int check_engine_plugin_register(struct check_engine_plugin_def *plugin, struct xccdf_policy_model *model, const char *path_hint);
00060 int check_engine_plugin_cleanup(struct check_engine_plugin_def *plugin, struct xccdf_policy_model *model);
00061 int check_engine_plugin_export_results(struct check_engine_plugin_def *plugin, struct xccdf_policy_model *model, bool validate, const char *path_hint);
00062 const char *check_engine_plugin_get_capabilities(struct check_engine_plugin_def *plugin);
00063
00067 typedef int (*check_engine_plugin_entry_fn) (struct check_engine_plugin_def*);
00068
00069 #define OPENSCAP_CHECK_ENGINE_PLUGIN_ENTRY OPENSCAP_CHECK_ENGINE_PLUGIN_ENTRY
00070
00076 const char * const *check_engine_plugin_get_known_plugins(void);
00077
00080 #endif