23 #ifndef XCCDF_ELEMENTS_H_
24 #define XCCDF_ELEMENTS_H_
29 #include "common/util.h"
30 #include "common/elements.h"
32 #include <libxml/xmlreader.h>
46 bool xccdf_is_supported_namespace(xmlNs *ns);
60 XCCDFE_RESULT_BENCHMARK,
65 XCCDFE_CHECK_CONTENT_REF,
95 XCCDFE_CPE2_PLATFORMSPEC,
96 XCCDFE_RESULT_PROFILE,
117 XCCDFE_TARGET_ADDRESS,
119 XCCDFE_TARGET_IDENTIFIER,
129 xccdf_element_t xccdf_element_get(xmlTextReaderPtr reader);
131 #define XCCDF_ASSERT_ELEMENT(reader, element) do { if (xccdf_element_get(reader) != element) return false; } while(false)
136 XCCDFA_AUTHENTICATED,
156 XCCDFA_INTERFACEHINT,
166 XCCDFA_PARENTCONTEXT,
169 XCCDFA_PROHIBITCHANGES,
193 bool xccdf_attribute_has(xmlTextReaderPtr reader, xccdf_attribute_t attr);
194 const char *xccdf_attribute_get(xmlTextReaderPtr reader, xccdf_attribute_t attr);
195 char *xccdf_attribute_copy(xmlTextReaderPtr reader, xccdf_attribute_t attr);
196 bool xccdf_attribute_get_bool(xmlTextReaderPtr reader, xccdf_attribute_t attr);
197 int xccdf_attribute_get_int(xmlTextReaderPtr reader, xccdf_attribute_t attr);
198 float xccdf_attribute_get_float(xmlTextReaderPtr reader, xccdf_attribute_t attr);
202 void xccdf_print_depth(
int depth);
203 void xccdf_print_max(
const char *str,
int max,
const char *ellipsis);
204 void xccdf_print_max_text(
const struct oscap_text *txt,
int max,
const char *ellipsis);
205 void xccdf_print_textlist(
struct oscap_text_iterator *txt,
int depth,
int max,
const char *ellipsis);