00001
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039 #ifndef OVAL_DEFINITIONS
00040 #define OVAL_DEFINITIONS
00041
00042 #include "oval_adt.h"
00043 #include "oval_types.h"
00044 #include "oval_version.h"
00045 #include <stdbool.h>
00046
00052 typedef enum {
00053 OVAL_AFCFML_UNKNOWN = 0,
00054 OVAL_AFCFML_CATOS = 1,
00055 OVAL_AFCFML_IOS = 2,
00056 OVAL_AFCFML_MACOS = 3,
00057 OVAL_AFCFML_PIXOS = 4,
00058 OVAL_AFCFML_UNDEFINED = 5,
00059 OVAL_AFCFML_UNIX = 6,
00060 OVAL_AFCFML_WINDOWS = 7
00061 } oval_affected_family_t;
00062
00064 typedef enum {
00065 OVAL_NODETYPE_UNKNOWN = 0,
00066 OVAL_NODETYPE_CRITERIA = 1,
00067 OVAL_NODETYPE_CRITERION = 2,
00068 OVAL_NODETYPE_EXTENDDEF = 3
00069 } oval_criteria_node_type_t;
00070
00072 typedef enum {
00073 OVAL_OPERATOR_UNKNOWN = 0,
00074 OVAL_OPERATOR_AND = 1,
00075 OVAL_OPERATOR_ONE = 2,
00076 OVAL_OPERATOR_OR = 3,
00077 OVAL_OPERATOR_XOR = 4
00078 } oval_operator_t;
00079
00081 typedef enum {
00082 OVAL_OPERATION_UNKNOWN = 0,
00083 OVAL_OPERATION_BITWISE_AND,
00084 OVAL_OPERATION_BITWISE_OR,
00085 OVAL_OPERATION_CASE_INSENSITIVE_EQUALS,
00086 OVAL_OPERATION_CASE_INSENSITIVE_NOT_EQUAL,
00087 OVAL_OPERATION_EQUALS,
00088 OVAL_OPERATION_GREATER_THAN,
00089 OVAL_OPERATION_GREATER_THAN_OR_EQUAL,
00090 OVAL_OPERATION_LESS_THAN,
00091 OVAL_OPERATION_LESS_THAN_OR_EQUAL,
00092 OVAL_OPERATION_NOT_EQUAL,
00093 OVAL_OPERATION_PATTERN_MATCH,
00094 OVAL_OPERATION_SUBSET_OF,
00095 OVAL_OPERATION_SUPERSET_OF,
00096 } oval_operation_t;
00097
00098
00100 typedef enum {
00101 OVAL_EXISTENCE_UNKNOWN = 0,
00102 OVAL_ALL_EXIST = 1,
00103 OVAL_ANY_EXIST = 2,
00104 OVAL_AT_LEAST_ONE_EXISTS = 3,
00105 OVAL_ONLY_ONE_EXISTS = 4,
00106 OVAL_NONE_EXIST = 5
00107 } oval_existence_t;
00108
00110 typedef enum {
00111 OVAL_CHECK_UNKNOWN = 0,
00112 OVAL_CHECK_ALL = 1,
00113 OVAL_CHECK_AT_LEAST_ONE = 2,
00114 OVAL_CHECK_NONE_EXIST = 3,
00115 OVAL_CHECK_NONE_SATISFY = 4,
00116 OVAL_CHECK_ONLY_ONE = 5
00117 } oval_check_t;
00118
00120 typedef enum {
00121 OVAL_OBJECTCONTENT_UNKNOWN = 0,
00122 OVAL_OBJECTCONTENT_ENTITY = 1,
00123 OVAL_OBJECTCONTENT_SET = 2,
00124 OVAL_OBJECTCONTENT_FILTER = 3
00125 } oval_object_content_type_t;
00126
00128 typedef enum {
00129 OVAL_ENTITY_TYPE_UNKNOWN,
00130 OVAL_ENTITY_TYPE_ANY,
00131 OVAL_ENTITY_TYPE_BINARY,
00132 OVAL_ENTITY_TYPE_BOOLEAN,
00133 OVAL_ENTITY_TYPE_FLOAT,
00134 OVAL_ENTITY_TYPE_INTEGER,
00135 OVAL_ENTITY_TYPE_STRING,
00136 } oval_entity_type_t;
00137
00139 typedef enum {
00140 OVAL_FILTER_ACTION_UNKNOWN = 0,
00141 OVAL_FILTER_ACTION_EXCLUDE,
00142 OVAL_FILTER_ACTION_INCLUDE
00143 } oval_filter_action_t;
00144
00146 typedef enum {
00147 OVAL_DATATYPE_UNKNOWN = 0,
00148 OVAL_DATATYPE_BINARY,
00149 OVAL_DATATYPE_BOOLEAN,
00150 OVAL_DATATYPE_EVR_STRING,
00151 OVAL_DATATYPE_FILESET_REVISION,
00152 OVAL_DATATYPE_FLOAT,
00153 OVAL_DATATYPE_INTEGER,
00154 OVAL_DATATYPE_IOS_VERSION,
00155 OVAL_DATATYPE_IPV4ADDR,
00156 OVAL_DATATYPE_IPV6ADDR,
00157 OVAL_DATATYPE_RECORD,
00158 OVAL_DATATYPE_SEXP,
00159 OVAL_DATATYPE_STRING,
00160 OVAL_DATATYPE_STRING_M,
00161 OVAL_DATATYPE_VERSION,
00162 } oval_datatype_t;
00163
00165 typedef enum {
00166 OVAL_ENTITY_VARREF_UNKNOWN,
00167 OVAL_ENTITY_VARREF_NONE,
00168 OVAL_ENTITY_VARREF_ATTRIBUTE,
00169 OVAL_ENTITY_VARREF_ELEMENT
00170 } oval_entity_varref_type_t;
00171
00173 typedef enum {
00174 OVAL_SET_UNKNOWN,
00175 OVAL_SET_AGGREGATE,
00176 OVAL_SET_COLLECTIVE
00177 } oval_setobject_type_t;
00178
00180 typedef enum {
00181 OVAL_SET_OPERATION_UNKNOWN,
00182 OVAL_SET_OPERATION_COMPLEMENT = 1,
00183 OVAL_SET_OPERATION_INTERSECTION = 2,
00184 OVAL_SET_OPERATION_UNION = 3
00185 } oval_setobject_operation_t;
00186
00188 typedef enum {
00189 OVAL_VARIABLE_UNKNOWN,
00190 OVAL_VARIABLE_EXTERNAL,
00191 OVAL_VARIABLE_CONSTANT,
00192 OVAL_VARIABLE_LOCAL
00193 } oval_variable_type_t;
00194
00195 #define OVAL_FUNCTION 4
00197 typedef enum {
00198 OVAL_COMPONENT_UNKNOWN = 0,
00199 OVAL_COMPONENT_LITERAL = 1,
00200 OVAL_COMPONENT_OBJECTREF = 2,
00201 OVAL_COMPONENT_VARREF = 3,
00202 OVAL_COMPONENT_FUNCTION = 4,
00203 OVAL_FUNCTION_BEGIN = OVAL_FUNCTION + 1,
00204 OVAL_FUNCTION_CONCAT = OVAL_FUNCTION + 2,
00205 OVAL_FUNCTION_END = OVAL_FUNCTION + 3,
00206 OVAL_FUNCTION_SPLIT = OVAL_FUNCTION + 4,
00207 OVAL_FUNCTION_SUBSTRING = OVAL_FUNCTION + 5,
00208 OVAL_FUNCTION_TIMEDIF = OVAL_FUNCTION + 6,
00209 OVAL_FUNCTION_ESCAPE_REGEX = OVAL_FUNCTION + 7,
00210 OVAL_FUNCTION_REGEX_CAPTURE = OVAL_FUNCTION + 8,
00211 OVAL_FUNCTION_ARITHMETIC = OVAL_FUNCTION + 9,
00212 OVAL_FUNCTION_COUNT = OVAL_FUNCTION + 10,
00213 OVAL_FUNCTION_UNIQUE = OVAL_FUNCTION + 11,
00214 OVAL_FUNCTION_LAST = OVAL_FUNCTION + 12
00215 } oval_component_type_t;
00216
00218 typedef enum {
00219 OVAL_ARITHMETIC_UNKNOWN = 0,
00220 OVAL_ARITHMETIC_ADD = 1,
00221 OVAL_ARITHMETIC_MULTIPLY = 2,
00222 OVAL_ARITHMETIC_SUBTRACT = 3,
00223 OVAL_ARITHMETIC_DIVIDE = 4
00224 } oval_arithmetic_operation_t;
00225
00227 typedef enum {
00228 OVAL_DATETIME_UNKNOWN = 0,
00229 OVAL_DATETIME_YEAR_MONTH_DAY = 1,
00230 OVAL_DATETIME_MONTH_DAY_YEAR = 2,
00231 OVAL_DATETIME_DAY_MONTH_YEAR = 3,
00232 OVAL_DATETIME_WIN_FILETIME = 4,
00233 OVAL_DATETIME_SECONDS_SINCE_EPOCH = 5
00234 } oval_datetime_format_t;
00235
00236 typedef enum {
00237 OVAL_RECORD_FIELD_UNKNOWN = 0,
00238 OVAL_RECORD_FIELD_STATE = 1,
00239 OVAL_RECORD_FIELD_ITEM = 2,
00240 } oval_record_field_type_t;
00241
00245 oval_family_t oval_subtype_get_family(oval_subtype_t);
00246 const char *oval_operator_get_text(oval_operator_t);
00247 const char *oval_subtype_get_text(oval_subtype_t);
00248 const char *oval_family_get_text(oval_family_t);
00249 const char *oval_check_get_text(oval_check_t);
00250 const char *oval_existence_get_text(oval_existence_t);
00251 const char *oval_affected_family_get_text(oval_affected_family_t);
00252 const char *oval_datatype_get_text(oval_datatype_t);
00253 oval_datatype_t oval_datatype_from_text(const char *);
00254 const char *oval_operation_get_text(oval_operation_t);
00255 const char *oval_set_operation_get_text(oval_setobject_operation_t);
00256 const char *oval_datetime_format_get_text(oval_datetime_format_t);
00257 const char *oval_arithmetic_operation_get_text(oval_arithmetic_operation_t);
00258 const char *oval_filter_action_get_text(oval_filter_action_t);
00259
00260
00265 struct oval_definition_model;
00266
00273 struct oval_definition;
00278 struct oval_definition_iterator;
00284 struct oval_test;
00289 struct oval_test_iterator;
00298 struct oval_object;
00303 struct oval_object_iterator;
00310 struct oval_state;
00315 struct oval_state_iterator;
00330 struct oval_variable;
00335 struct oval_variable_iterator;
00356 struct oval_affected;
00361 struct oval_affected_iterator;
00369 struct oval_reference;
00374 struct oval_reference_iterator;
00383 struct oval_criteria_node;
00388 struct oval_criteria_node_iterator;
00393 struct oval_object_content;
00398 struct oval_object_content_iterator;
00403 struct oval_behavior;
00408 struct oval_behavior_iterator;
00413 struct oval_state_content;
00418 struct oval_state_content_iterator;
00423 struct oval_value;
00428 struct oval_value_iterator;
00433 struct oval_entity;
00437 struct oval_entity_iterator;
00441 struct oval_record_field;
00445 struct oval_record_field_iterator;
00450 struct oval_setobject;
00455 struct oval_setobject_iterator;
00460 struct oval_filter;
00464 struct oval_filter_iterator;
00565 struct oval_component;
00570 struct oval_component_iterator;
00571
00575 struct oval_generator;
00576
00577 struct oval_generator *oval_generator_new(void);
00578 void oval_generator_free(struct oval_generator *generator);
00579 struct oval_generator *oval_generator_clone(struct oval_generator *old_generator);
00580 char *oval_generator_get_product_name(struct oval_generator *generator);
00581 char *oval_generator_get_product_version(struct oval_generator *generator);
00582 char *oval_generator_get_schema_version(struct oval_generator *generator);
00583 char *oval_generator_get_timestamp(struct oval_generator *generator);
00584 void oval_generator_set_product_name(struct oval_generator *generator, char *product_name);
00585 void oval_generator_set_product_version(struct oval_generator *generator, char *product_version);
00586 void oval_generator_set_schema_version(struct oval_generator *generator, char *schema_version);
00587 void oval_generator_set_timestamp(struct oval_generator *generator, char *timestamp);
00588
00593 struct oval_definition_model *oval_definition_model_new(void);
00600 struct oval_definition_model * oval_definition_model_import(const char *file);
00601
00610 int oval_definition_model_merge(struct oval_definition_model *model, const char *file);
00611
00617 struct oval_definition_model *oval_definition_model_clone(struct oval_definition_model *);
00623 int oval_definition_model_export(struct oval_definition_model *, const char *file);
00628 void oval_definition_model_free(struct oval_definition_model *model);
00629
00634 void oval_definition_model_set_generator(struct oval_definition_model *model, struct oval_generator *generator);
00640 int oval_definition_model_bind_variable_model(struct oval_definition_model *, struct oval_variable_model *);
00641
00642 void oval_definition_model_clear_external_variables(struct oval_definition_model *);
00649 struct oval_generator *oval_definition_model_get_generator(struct oval_definition_model *model);
00657 struct oval_definition *oval_definition_model_get_definition(struct oval_definition_model *, const char *id);
00666 struct oval_test *oval_definition_model_get_test(struct oval_definition_model *model, const char *id);
00675 struct oval_object *oval_definition_model_get_object(struct oval_definition_model *model, const char *id);
00684 struct oval_state *oval_definition_model_get_state(struct oval_definition_model *model, const char *id);
00693 struct oval_variable *oval_definition_model_get_variable(struct oval_definition_model *model, const char *id);
00698 struct oval_definition_iterator *oval_definition_model_get_definitions(struct oval_definition_model *model);
00705 struct oval_test_iterator *oval_definition_model_get_tests(struct oval_definition_model *model);
00712 struct oval_object_iterator *oval_definition_model_get_objects(struct oval_definition_model *model);
00719 struct oval_state_iterator *oval_definition_model_get_states(struct oval_definition_model *model);
00726 struct oval_variable_iterator *oval_definition_model_get_variables(struct oval_definition_model *model);
00727
00733 const char * oval_definition_model_supported(void);
00739 struct oval_variable_model_iterator *oval_definition_model_get_variable_models(struct oval_definition_model *);
00765 struct oval_definition *oval_definition_new(struct oval_definition_model *, const char *id);
00766
00772 struct oval_definition *oval_definition_clone(struct oval_definition_model *new_model, struct oval_definition *old_definition);
00773
00783 void oval_definition_free(struct oval_definition *);
00784
00796 void oval_definition_set_version(struct oval_definition *, int version);
00804 void oval_definition_set_class(struct oval_definition *, oval_definition_class_t);
00810 void oval_definition_set_deprecated(struct oval_definition *, bool deprecated);
00818 void oval_definition_set_title(struct oval_definition *, char *title);
00826 void oval_definition_set_description(struct oval_definition *, char *description);
00837 void oval_definition_add_affected(struct oval_definition *, struct oval_affected *affected);
00848 void oval_definition_add_reference(struct oval_definition *, struct oval_reference *reference);
00854 void oval_definition_add_note(struct oval_definition *, char *note);
00868 void oval_definition_set_criteria(struct oval_definition *, struct oval_criteria_node *criteria);
00879 char *oval_definition_get_id(struct oval_definition *);
00885 int oval_definition_get_version(struct oval_definition *);
00890 oval_definition_class_t oval_definition_get_class(struct oval_definition *);
00895 bool oval_definition_get_deprecated(struct oval_definition *);
00901 char *oval_definition_get_title(struct oval_definition *);
00907 char *oval_definition_get_description(struct oval_definition *);
00914 struct oval_affected_iterator *oval_definition_get_affected(struct oval_definition *);
00921 struct oval_reference_iterator *oval_definition_get_references(struct oval_definition *);
00928 struct oval_string_iterator *oval_definition_get_notes(struct oval_definition *);
00934 struct oval_criteria_node *oval_definition_get_criteria(struct oval_definition *);
00951 bool oval_definition_iterator_has_more(struct oval_definition_iterator *);
00957 struct oval_definition *oval_definition_iterator_next(struct oval_definition_iterator *);
00962 void oval_definition_iterator_free(struct oval_definition_iterator *);
00985 struct oval_test *oval_test_new(struct oval_definition_model *, const char *id);
00991 struct oval_test *oval_test_clone(struct oval_definition_model *new_model, struct oval_test *old_test);
00996 void oval_test_free(struct oval_test *);
00997
01011 void oval_test_set_subtype(struct oval_test *, oval_subtype_t subtype);
01017 void oval_test_add_note(struct oval_test *, char *note);
01023 void oval_test_set_comment(struct oval_test *, char *comment);
01028 void oval_test_set_deprecated(struct oval_test *, bool deprecated);
01037 void oval_test_set_version(struct oval_test *, int version);
01042 void oval_test_set_state_operator(struct oval_test *, oval_operator_t);
01051 void oval_test_set_existence(struct oval_test *, oval_existence_t);
01061 void oval_test_set_check(struct oval_test *, oval_check_t);
01070 void oval_test_set_object(struct oval_test *, struct oval_object *);
01076 void oval_test_add_state(struct oval_test *, struct oval_state *);
01087 oval_family_t oval_test_get_family(struct oval_test *);
01092 oval_subtype_t oval_test_get_subtype(struct oval_test *);
01099 struct oval_string_iterator *oval_test_get_notes(struct oval_test *);
01105 char *oval_test_get_comment(struct oval_test *);
01111 char *oval_test_get_id(struct oval_test *);
01116 bool oval_test_get_deprecated(struct oval_test *);
01121 int oval_test_get_version(struct oval_test *);
01126 oval_operator_t oval_test_get_state_operator(struct oval_test *);
01131 oval_existence_t oval_test_get_existence(struct oval_test *);
01136 oval_check_t oval_test_get_check(struct oval_test *);
01142 struct oval_object *oval_test_get_object(struct oval_test *);
01149 struct oval_state_iterator *oval_test_get_states(struct oval_test *);
01150
01167 bool oval_test_iterator_has_more(struct oval_test_iterator *);
01172 struct oval_test *oval_test_iterator_next(struct oval_test_iterator *);
01177 void oval_test_iterator_free(struct oval_test_iterator *);
01198 struct oval_object *oval_object_new(struct oval_definition_model *, const char *id);
01204 struct oval_object *oval_object_clone(struct oval_definition_model *new_model, struct oval_object *old_object);
01209 void oval_object_free(struct oval_object *);
01210
01224 void oval_object_set_subtype(struct oval_object *, oval_subtype_t subtype);
01230 void oval_object_add_note(struct oval_object *, char *note);
01231
01237 void oval_object_set_comment(struct oval_object *, char *comment);
01238
01243 void oval_object_set_deprecated(struct oval_object *, bool deprecated);
01252 void oval_object_set_version(struct oval_object *, int version);
01265 void oval_object_add_object_content(struct oval_object *, struct oval_object_content *content);
01278 void oval_object_add_behavior(struct oval_object *, struct oval_behavior *behavior);
01289 oval_family_t oval_object_get_family(struct oval_object *);
01295 const char *oval_object_get_name(struct oval_object *);
01300 oval_subtype_t oval_object_get_subtype(struct oval_object *);
01307 struct oval_string_iterator *oval_object_get_notes(struct oval_object *);
01313 char *oval_object_get_comment(struct oval_object *);
01319 char *oval_object_get_id(struct oval_object *);
01320
01325 bool oval_object_get_deprecated(struct oval_object *);
01330 int oval_object_get_version(struct oval_object *);
01331
01335 oval_version_t oval_object_get_schema_version(struct oval_object *object);
01336
01343 struct oval_object_content_iterator *oval_object_get_object_contents(struct oval_object *);
01350 struct oval_behavior_iterator *oval_object_get_behaviors(struct oval_object *);
01367 bool oval_object_iterator_has_more(struct oval_object_iterator *);
01372 struct oval_object *oval_object_iterator_next(struct oval_object_iterator *);
01377 void oval_object_iterator_free(struct oval_object_iterator *);
01398 struct oval_state *oval_state_new(struct oval_definition_model *, const char *id);
01404 struct oval_state *oval_state_clone(struct oval_definition_model *new_model, struct oval_state *old_state);
01409 void oval_state_free(struct oval_state *);
01410
01424 void oval_state_set_subtype(struct oval_state *, oval_subtype_t subtype);
01430 void oval_state_add_note(struct oval_state *, char *note);
01436 void oval_state_set_comment(struct oval_state *, char *comment);
01441 void oval_state_set_deprecated(struct oval_state *, bool deprecated);
01450 void oval_state_set_version(struct oval_state *, int version);
01455 void oval_state_set_operator(struct oval_state *, oval_operator_t);
01468 void oval_state_add_content(struct oval_state *, struct oval_state_content *content);
01479 oval_family_t oval_state_get_family(struct oval_state *);
01485 const char *oval_state_get_name(struct oval_state *);
01490 oval_subtype_t oval_state_get_subtype(struct oval_state *);
01497 struct oval_string_iterator *oval_state_get_notes(struct oval_state *);
01503 char *oval_state_get_comment(struct oval_state *);
01509 char *oval_state_get_id(struct oval_state *);
01514 bool oval_state_get_deprecated(struct oval_state *);
01519 int oval_state_get_version(struct oval_state *);
01524 int oval_state_get_operator(struct oval_state *);
01531 struct oval_state_content_iterator *oval_state_get_contents(struct oval_state *);
01542 bool oval_state_iterator_has_more(struct oval_state_iterator *);
01547 struct oval_state *oval_state_iterator_next(struct oval_state_iterator *);
01552 void oval_state_iterator_free(struct oval_state_iterator *);
01585 struct oval_variable *oval_variable_new(struct oval_definition_model *model, const char *id, oval_variable_type_t type);
01591 struct oval_variable *oval_variable_clone(struct oval_definition_model *new_model, struct oval_variable *old_variable);
01596 void oval_variable_free(struct oval_variable *);
01597
01609 void oval_variable_set_comment(struct oval_variable *, char *comment);
01617 void oval_variable_set_version(struct oval_variable *, int version);
01623 void oval_variable_set_deprecated(struct oval_variable *, bool deprecated);
01631 void oval_variable_set_datatype(struct oval_variable *, oval_datatype_t);
01645 void oval_variable_add_value(struct oval_variable *, struct oval_value *);
01646
01647 void oval_variable_clear_values(struct oval_variable *);
01660 void oval_variable_set_component(struct oval_variable *, struct oval_component *component);
01672 char *oval_variable_get_id(struct oval_variable *);
01678 char *oval_variable_get_comment(struct oval_variable *);
01683 int oval_variable_get_version(struct oval_variable *);
01688 bool oval_variable_get_deprecated(struct oval_variable *);
01693 oval_variable_type_t oval_variable_get_type(struct oval_variable *);
01698 oval_datatype_t oval_variable_get_datatype(struct oval_variable *);
01706 struct oval_value_iterator *oval_variable_get_values(struct oval_variable *);
01713 struct oval_component *oval_variable_get_component(struct oval_variable *);
01718 const char *oval_component_type_get_text(oval_component_type_t type);
01729 bool oval_variable_iterator_has_more(struct oval_variable_iterator *);
01734 struct oval_variable *oval_variable_iterator_next(struct oval_variable_iterator *);
01739 void oval_variable_iterator_free(struct oval_variable_iterator *);
01752 struct oval_affected *oval_affected_new(struct oval_definition_model *);
01758 struct oval_affected *oval_affected_clone(struct oval_definition_model *new_model, struct oval_affected *old_affected);
01763 void oval_affected_free(struct oval_affected *);
01764
01773 void oval_affected_set_family(struct oval_affected *, oval_affected_family_t family);
01778 void oval_affected_add_platform(struct oval_affected *, char *platform_name);
01783 void oval_affected_add_product(struct oval_affected *, char *product_name);
01796 oval_affected_family_t oval_affected_get_family(struct oval_affected *);
01804 struct oval_string_iterator *oval_affected_get_platforms(struct oval_affected *);
01812 struct oval_string_iterator *oval_affected_get_products(struct oval_affected *);
01829 bool oval_affected_iterator_has_more(struct oval_affected_iterator *);
01834 struct oval_affected *oval_affected_iterator_next(struct oval_affected_iterator *);
01839 void oval_affected_iterator_free(struct oval_affected_iterator *);
01845 struct oval_reference *oval_reference_new(struct oval_definition_model *);
01850 struct oval_reference *oval_reference_clone
01851 (struct oval_definition_model *new_model, struct oval_reference *old_reference);
01855 void oval_reference_free(struct oval_reference *);
01856
01866 void oval_reference_set_source(struct oval_reference *, char *);
01870 void oval_reference_set_id(struct oval_reference *, char *);
01874 void oval_reference_set_url(struct oval_reference *, char *);
01886 char *oval_reference_get_source(struct oval_reference *);
01892 char *oval_reference_get_id(struct oval_reference *);
01898 char *oval_reference_get_url(struct oval_reference *);
01908 bool oval_reference_iterator_has_more(struct oval_reference_iterator *);
01912 struct oval_reference *oval_reference_iterator_next(struct oval_reference_iterator *);
01916 void oval_reference_iterator_free(struct oval_reference_iterator *);
01945 struct oval_criteria_node *oval_criteria_node_new(struct oval_definition_model *, oval_criteria_node_type_t type);
01951 struct oval_criteria_node *oval_criteria_node_clone
01952 (struct oval_definition_model *new_model, struct oval_criteria_node *old_node);
01957 void oval_criteria_node_free(struct oval_criteria_node *);
01958
01968 void oval_criteria_node_set_negate(struct oval_criteria_node *, bool negate);
01974 void oval_criteria_node_set_applicability_check(struct oval_criteria_node *, bool applicability_check);
01980 void oval_criteria_set_node_type(struct oval_criteria_node *node, oval_criteria_node_type_t type);
01986 void oval_criteria_node_set_comment(struct oval_criteria_node *, char *comment);
01994 void oval_criteria_node_set_operator(struct oval_criteria_node *, oval_operator_t op);
02005 void oval_criteria_node_add_subnode(struct oval_criteria_node *, struct oval_criteria_node *node);
02013 void oval_criteria_node_set_test(struct oval_criteria_node *, struct oval_test *);
02021 void oval_criteria_node_set_definition(struct oval_criteria_node *, struct oval_definition *);
02032 oval_criteria_node_type_t oval_criteria_node_get_type(struct oval_criteria_node *);
02037 bool oval_criteria_node_get_negate(struct oval_criteria_node *);
02042 bool oval_criteria_node_get_applicability_check(struct oval_criteria_node *);
02043
02049 char *oval_criteria_node_get_comment(struct oval_criteria_node *);
02055 oval_operator_t oval_criteria_node_get_operator(struct oval_criteria_node *);
02063 struct oval_criteria_node_iterator *oval_criteria_node_get_subnodes(struct oval_criteria_node *);
02070 struct oval_test *oval_criteria_node_get_test(struct oval_criteria_node *);
02077 struct oval_definition *oval_criteria_node_get_definition(struct oval_criteria_node *);
02088 bool oval_criteria_node_iterator_has_more(struct oval_criteria_node_iterator *);
02094 struct oval_criteria_node *oval_criteria_node_iterator_next(struct oval_criteria_node_iterator *);
02099 void oval_criteria_node_iterator_free(struct oval_criteria_node_iterator *);
02111 struct oval_object_content *oval_object_content_new(struct oval_definition_model *model, oval_object_content_type_t type);
02112
02117 struct oval_object_content *oval_object_content_clone
02118 (struct oval_definition_model *new_model, struct oval_object_content *old_content);
02119
02123 void oval_object_content_free(struct oval_object_content *);
02124
02133 void oval_object_content_set_type(struct oval_object_content *, oval_object_content_type_t);
02137 void oval_object_content_set_field_name(struct oval_object_content *, char *);
02141 void oval_object_content_set_entity(struct oval_object_content *, struct oval_entity *);
02145 void oval_object_content_set_varCheck(struct oval_object_content *, oval_check_t);
02149 void oval_object_content_set_setobject(struct oval_object_content *, struct oval_setobject *);
02161 char *oval_object_content_get_field_name(struct oval_object_content *);
02166 oval_object_content_type_t oval_object_content_get_type(struct oval_object_content *);
02172 struct oval_entity *oval_object_content_get_entity(struct oval_object_content *);
02177 oval_check_t oval_object_content_get_varCheck(struct oval_object_content *);
02183 struct oval_setobject *oval_object_content_get_setobject(struct oval_object_content *);
02193 bool oval_object_content_iterator_has_more(struct oval_object_content_iterator *);
02197 struct oval_object_content *oval_object_content_iterator_next(struct oval_object_content_iterator *);
02201 void oval_object_content_iterator_free(struct oval_object_content_iterator *);
02213 struct oval_behavior *oval_behavior_new(struct oval_definition_model *);
02214
02219 struct oval_behavior *oval_behavior_clone(struct oval_definition_model *new_model, struct oval_behavior *old_behavior);
02223 void oval_behavior_free(struct oval_behavior *);
02224
02232 void oval_behavior_set_keyval(struct oval_behavior *behavior, const char *key, const char *value);
02244 char *oval_behavior_get_key(struct oval_behavior *);
02250 char *oval_behavior_get_value(struct oval_behavior *);
02260 bool oval_behavior_iterator_has_more(struct oval_behavior_iterator *);
02264 struct oval_behavior *oval_behavior_iterator_next(struct oval_behavior_iterator *);
02268 void oval_behavior_iterator_free(struct oval_behavior_iterator *);
02280 struct oval_state_content *oval_state_content_new(struct oval_definition_model *);
02285 struct oval_state_content *oval_state_content_clone (struct oval_definition_model *new_model, struct oval_state_content *old_content);
02289 void oval_state_content_free(struct oval_state_content *);
02290
02298 void oval_state_content_set_entity(struct oval_state_content *, struct oval_entity *);
02302 void oval_state_content_add_record_field(struct oval_state_content *, struct oval_record_field *);
02306 void oval_state_content_set_varcheck(struct oval_state_content *, oval_check_t);
02310 void oval_state_content_set_entcheck(struct oval_state_content *, oval_check_t);
02322 struct oval_entity *oval_state_content_get_entity(struct oval_state_content *);
02326 struct oval_record_field_iterator *oval_state_content_get_record_fields(struct oval_state_content *);
02331 oval_check_t oval_state_content_get_var_check(struct oval_state_content *);
02336 oval_check_t oval_state_content_get_ent_check(struct oval_state_content *);
02347 bool oval_state_content_iterator_has_more(struct oval_state_content_iterator *);
02351 struct oval_state_content *oval_state_content_iterator_next(struct oval_state_content_iterator *);
02355 void oval_state_content_iterator_free(struct oval_state_content_iterator *);
02361 struct oval_value *oval_value_new(oval_datatype_t datatype, char *text_value);
02366 struct oval_value *oval_value_clone(struct oval_value *old_value);
02370 void oval_value_free(struct oval_value *);
02371
02379 void oval_value_set_datatype(struct oval_value *, oval_datatype_t);
02380
02389 oval_datatype_t oval_value_get_datatype(struct oval_value *);
02395 char *oval_value_get_text(struct oval_value *);
02400 unsigned char *oval_value_get_binary(struct oval_value *);
02405 bool oval_value_get_boolean(struct oval_value *);
02410 float oval_value_get_float(struct oval_value *);
02415 long long oval_value_get_integer(struct oval_value *);
02425 bool oval_value_iterator_has_more(struct oval_value_iterator *);
02429 struct oval_value *oval_value_iterator_next(struct oval_value_iterator *);
02433 int oval_value_iterator_remaining(struct oval_value_iterator *iterator);
02437 void oval_value_iterator_free(struct oval_value_iterator *);
02449 struct oval_entity *oval_entity_new(struct oval_definition_model *);
02454 struct oval_entity *oval_entity_clone(struct oval_definition_model *model, struct oval_entity *old_entity);
02458 void oval_entity_free(struct oval_entity *);
02459
02467 void oval_entity_set_type(struct oval_entity *, oval_entity_type_t);
02471 void oval_entity_set_datatype(struct oval_entity *, oval_datatype_t);
02475 void oval_entity_set_mask(struct oval_entity *, int);
02479 void oval_entity_set_varref_type(struct oval_entity *, oval_entity_varref_type_t);
02483 void oval_entity_set_variable(struct oval_entity *, struct oval_variable *);
02487 void oval_entity_set_value(struct oval_entity *, struct oval_value *);
02491 void oval_entity_set_name(struct oval_entity *, char *);
02495 void oval_entity_set_operation(struct oval_entity *, oval_operation_t);
02507 char *oval_entity_get_name(struct oval_entity *);
02512 oval_entity_type_t oval_entity_get_type(struct oval_entity *);
02517 oval_datatype_t oval_entity_get_datatype(struct oval_entity *);
02522 oval_operation_t oval_entity_get_operation(struct oval_entity *);
02528 struct oval_variable *oval_entity_get_variable(struct oval_entity *);
02534 struct oval_value *oval_entity_get_value(struct oval_entity *);
02539 int oval_entity_get_mask(struct oval_entity *);
02544 oval_entity_varref_type_t oval_entity_get_varref_type(struct oval_entity *);
02554 bool oval_entity_iterator_has_more(struct oval_entity_iterator *);
02558 struct oval_entity *oval_entity_iterator_next(struct oval_entity_iterator *);
02562 void oval_entity_iterator_free(struct oval_entity_iterator *);
02574 struct oval_record_field *oval_record_field_new(oval_record_field_type_t);
02578 struct oval_record_field *oval_record_field_clone(struct oval_record_field *);
02582 void oval_record_field_free(struct oval_record_field *);
02583
02591 void oval_record_field_set_name(struct oval_record_field *, char *);
02595 void oval_record_field_set_value(struct oval_record_field *, char *);
02599 void oval_record_field_set_datatype(struct oval_record_field *, oval_datatype_t);
02603 void oval_record_field_set_mask(struct oval_record_field *, int);
02607 void oval_record_field_set_operation(struct oval_record_field *, oval_operation_t);
02611 void oval_record_field_set_variable(struct oval_record_field *, struct oval_variable *);
02615 void oval_record_field_set_var_check(struct oval_record_field *, oval_check_t);
02619 void oval_record_field_set_ent_check(struct oval_record_field *, oval_check_t);
02629 oval_record_field_type_t oval_record_field_get_type(struct oval_record_field *);
02633 char *oval_record_field_get_name(struct oval_record_field *);
02637 char *oval_record_field_get_value(struct oval_record_field *);
02641 oval_datatype_t oval_record_field_get_datatype(struct oval_record_field *);
02645 int oval_record_field_get_mask(struct oval_record_field *);
02649 oval_operation_t oval_record_field_get_operation(struct oval_record_field *);
02653 struct oval_variable *oval_record_field_get_variable(struct oval_record_field *);
02657 oval_check_t oval_record_field_get_var_check(struct oval_record_field *);
02661 oval_check_t oval_record_field_get_ent_check(struct oval_record_field *);
02671 bool oval_record_field_iterator_has_more(struct oval_record_field_iterator *);
02675 struct oval_record_field *oval_record_field_iterator_next(struct oval_record_field_iterator *);
02679 void oval_record_field_iterator_free(struct oval_record_field_iterator *);
02691 struct oval_filter *oval_filter_new(struct oval_definition_model *);
02695 void oval_filter_free(struct oval_filter *);
02699 struct oval_filter *oval_filter_clone(struct oval_definition_model *, struct oval_filter *);
02700
02708 void oval_filter_set_state(struct oval_filter *, struct oval_state *);
02712 void oval_filter_set_filter_action(struct oval_filter *, oval_filter_action_t );
02722 struct oval_state *oval_filter_get_state(struct oval_filter *);
02726 oval_filter_action_t oval_filter_get_filter_action(struct oval_filter *);
02736 bool oval_filter_iterator_has_more(struct oval_filter_iterator *);
02740 struct oval_filter *oval_filter_iterator_next(struct oval_filter_iterator *);
02744 void oval_filter_iterator_free(struct oval_filter_iterator *);
02756 struct oval_setobject *oval_setobject_new(struct oval_definition_model *);
02761 struct oval_setobject *oval_setobject_clone(struct oval_definition_model *new_model, struct oval_setobject *old_setobject);
02765 void oval_setobject_free(struct oval_setobject *);
02766
02773 void oval_setobject_set_type(struct oval_setobject *, oval_setobject_type_t);
02777 void oval_setobject_set_operation(struct oval_setobject *, oval_setobject_operation_t);
02781 void oval_setobject_add_subset(struct oval_setobject *, struct oval_setobject *);
02785 void oval_setobject_add_object(struct oval_setobject *, struct oval_object *);
02789 void oval_setobject_add_filter(struct oval_setobject *, struct oval_filter *);
02800 oval_setobject_type_t oval_setobject_get_type(struct oval_setobject *);
02805 oval_setobject_operation_t oval_setobject_get_operation(struct oval_setobject *);
02813 struct oval_setobject_iterator *oval_setobject_get_subsets(struct oval_setobject *);
02821 struct oval_object_iterator *oval_setobject_get_objects(struct oval_setobject *);
02829 struct oval_filter_iterator *oval_setobject_get_filters(struct oval_setobject *);
02839 bool oval_setobject_iterator_has_more(struct oval_setobject_iterator *);
02843 struct oval_setobject *oval_setobject_iterator_next(struct oval_setobject_iterator *);
02847 void oval_setobject_iterator_free(struct oval_setobject_iterator *);
02899 struct oval_component *oval_component_new(struct oval_definition_model *, oval_component_type_t type);
02905 struct oval_component *oval_component_clone(struct oval_definition_model *new_model,
02906 struct oval_component *old_component);
02911 void oval_component_free(struct oval_component *);
02912
02921 void oval_component_set_type(struct oval_component *component, oval_component_type_t type);
02927 void oval_component_set_object(struct oval_component *, struct oval_object *object);
02932 void oval_component_set_item_field(struct oval_component *, char *);
02937 void oval_component_set_record_field(struct oval_component *, char *);
02943 void oval_component_set_variable(struct oval_component *, struct oval_variable *variable);
02947 void oval_component_add_function_component(struct oval_component *, struct oval_component *);
02951 void oval_component_set_arithmetic_operation(struct oval_component *, oval_arithmetic_operation_t);
02955 void oval_component_set_prefix(struct oval_component *, char *);
02959 void oval_component_set_suffix(struct oval_component *, char *);
02963 void oval_component_set_split_delimiter(struct oval_component *, char *);
02967 void oval_component_set_substring_start(struct oval_component *, int);
02971 void oval_component_set_substring_length(struct oval_component *, int);
02975 void oval_component_set_timedif_format_1(struct oval_component *, oval_datetime_format_t);
02979 void oval_component_set_timedif_format_2(struct oval_component *, oval_datetime_format_t);
02983 void oval_component_set_regex_pattern(struct oval_component *, char *);
02987 void oval_component_set_literal_value(struct oval_component *, struct oval_value *);
02998 oval_component_type_t oval_component_get_type(struct oval_component *);
03006 struct oval_object *oval_component_get_object(struct oval_component *);
03013 char *oval_component_get_item_field(struct oval_component *);
03020 char *oval_component_get_record_field(struct oval_component *);
03028 struct oval_variable *oval_component_get_variable(struct oval_component *);
03036 struct oval_component_iterator *oval_component_get_function_components(struct oval_component *);
03042 oval_arithmetic_operation_t oval_component_get_arithmetic_operation(struct oval_component *);
03050 char *oval_component_get_prefix(struct oval_component *);
03058 char *oval_component_get_suffix(struct oval_component *);
03066 char *oval_component_get_split_delimiter(struct oval_component *);
03072 int oval_component_get_substring_start(struct oval_component *);
03078 int oval_component_get_substring_length(struct oval_component *);
03084 oval_datetime_format_t oval_component_get_timedif_format_1(struct oval_component *);
03090 oval_datetime_format_t oval_component_get_timedif_format_2(struct oval_component *);
03098 char *oval_component_get_regex_pattern(struct oval_component *);
03106 struct oval_value *oval_component_get_literal_value(struct oval_component *);
03117 bool oval_component_iterator_has_more(struct oval_component_iterator *);
03123 struct oval_component *oval_component_iterator_next(struct oval_component_iterator *);
03128 void oval_component_iterator_free(struct oval_component_iterator *);
03133 int oval_component_iterator_remaining(struct oval_component_iterator *);
03151 char *oval_determine_document_schema_version(const char *, oscap_document_type_t);
03152
03156 #endif