25#ifndef SCE_ENGINE_API_H_
26#define SCE_ENGINE_API_H_
30#include "oscap_export.h"
64OSCAP_API
const char* sce_check_result_get_basename(
struct sce_check_result* v);
77OSCAP_API
const char* sce_check_result_get_stdout(
struct sce_check_result* v);
90OSCAP_API
const char* sce_check_result_get_stderr(
struct sce_check_result* v);
144OSCAP_API
struct sce_session* sce_session_new(
void);
149OSCAP_API
void sce_session_free(
struct sce_session* s);
188OSCAP_API
void sce_session_export_to_directory(
struct sce_session* s,
const char* directory);
211OSCAP_API
const char* sce_parameters_get_xccdf_directory(
struct sce_parameters* v);
233OSCAP_API
void sce_parameters_allocate_session(
struct sce_parameters* v);
241 struct xccdf_value_binding_iterator *value_binding_it,
xccdf_test_result_type_t
Test result.
Definition xccdf_benchmark.h:170
bool xccdf_policy_model_register_engine_sce(struct xccdf_policy_model *model, struct sce_parameters *parameters)
Registers SCE to given policy model.
Definition sce_engine.c:727
xccdf_test_result_type_t sce_engine_eval_rule(struct xccdf_policy *policy, const char *rule_id, const char *id, const char *href, struct xccdf_value_binding_iterator *value_binding_it, struct xccdf_check_import_iterator *check_import_it, void *usr)
Internal rule evaluation callback, don't use directly.
Definition sce_engine.c:368
void sce_parameters_set_xccdf_directory(struct sce_parameters *v, const char *value)
Sets the directory that contains XCCDF that will reference SCE checks.
Definition sce_engine.c:298
Iterator over collections of sce_check_results.
Definition sce_engine.c:68
OSCAP_API void sce_check_result_set_stdout(struct sce_check_result *v, const char *details)
Sets stdout that was captured while script was evaluating.
Definition sce_engine.c:128
OSCAP_API void sce_check_result_add_environment_variable(struct sce_check_result *v, const char *var)
Adds an environment variable entry to list of environment variables that were passed to the script.
Definition sce_engine.c:166
OSCAP_API void sce_check_result_set_xccdf_result(struct sce_check_result *v, xccdf_test_result_type_t result)
Sets the final xccdf result (after exit code to xccdf mapping takes place)
Definition sce_engine.c:171
OSCAP_API void sce_check_result_set_exit_code(struct sce_check_result *v, int exit_code)
Sets exit code with which the script ended execution after evaluation.
Definition sce_engine.c:150
OSCAP_API void sce_check_result_export(struct sce_check_result *v, const char *target_file)
Exports details (in XML form) of given check result to given file.
Definition sce_engine.c:181
OSCAP_API void sce_check_result_set_href(struct sce_check_result *v, const char *href)
Sets the href used to execute the check that yielded given check result.
Definition sce_engine.c:106
OSCAP_API void sce_check_result_reset_environment_variables(struct sce_check_result *v)
Clears the list of passed environment variables.
Definition sce_engine.c:160
OSCAP_API void sce_check_result_set_basename(struct sce_check_result *v, const char *basename)
Sets basename of the script that was used for check evaluation.
Definition sce_engine.c:117
OSCAP_API void sce_check_result_set_stderr(struct sce_check_result *v, const char *details)
Sets stderr that was captured while script was evaluating.
Definition sce_engine.c:139
Definition sce_engine.c:273
OSCAP_API void sce_parameters_set_session(struct sce_parameters *v, struct sce_session *value)
Sets SCE session to use for check results storage.
Definition sce_engine.c:311
Definition sce_engine.c:218
OSCAP_API void sce_session_add_check_result(struct sce_session *s, struct sce_check_result *result)
Adds a check result to the session.
Definition sce_engine.c:245
OSCAP_API void sce_session_reset(struct sce_session *s)
Removes all check results from the session.
Definition sce_engine.c:239
XCCDF policy model structure contains xccdf_benchmark as reference to Benchmark element in XML file a...
Definition xccdf_policy_priv.h:38
XCCDF policy structure is abstract (class) structure of Profile element from benchmark.
Definition xccdf_policy_priv.h:57
Open-scap XCCDF library interface.
Open-scap XCCDF Policy library interface.