Skip to content

Commit 2480709

Browse files
authored
Merge pull request #1253 from mpreisler/tailoring_in_arf
Tailoring in arf
2 parents dcd084d + 4fe580b commit 2480709

File tree

10 files changed

+258
-13
lines changed

10 files changed

+258
-13
lines changed

src/DS/rds.c

Lines changed: 90 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@
3838
#include "ds_rds_session.h"
3939
#include "ds_rds_session_priv.h"
4040
#include "rds_priv.h"
41+
#include "sds_priv.h"
4142
#include "source/public/oscap_source.h"
4243
#include "source/oscap_source_priv.h"
4344

@@ -55,6 +56,8 @@ static const char* arf_ns_uri = "http://scap.nist.gov/schema/asset-reporting-for
5556
static const char* core_ns_uri = "http://scap.nist.gov/schema/reporting-core/1.1";
5657
static const char* arfvocab_ns_uri = "http://scap.nist.gov/specifications/arf/vocabulary/relationships/1.0#";
5758
static const char* ai_ns_uri = "http://scap.nist.gov/schema/asset-identification/1.1";
59+
static const char* xlink_ns_uri = "http://www.w3.org/1999/xlink";
60+
5861

5962
xmlNode *ds_rds_lookup_container(xmlDocPtr doc, const char *container_name)
6063
{
@@ -693,7 +696,7 @@ static void ds_rds_add_xccdf_test_results(xmlDocPtr doc, xmlNodePtr reports,
693696
}
694697
}
695698

696-
static int ds_rds_create_from_dom(xmlDocPtr* ret, xmlDocPtr sds_doc, xmlDocPtr xccdf_result_file_doc, struct oscap_htable* oval_result_sources, struct oscap_htable* oval_result_mapping, struct oscap_htable *arf_report_mapping)
699+
static int ds_rds_create_from_dom(xmlDocPtr* ret, xmlDocPtr sds_doc, xmlDocPtr tailoring_doc, const char* tailoring_filepath, char *tailoring_doc_timestamp, xmlDocPtr xccdf_result_file_doc, struct oscap_htable* oval_result_sources, struct oscap_htable* oval_result_mapping, struct oscap_htable *arf_report_mapping)
697700
{
698701
*ret = NULL;
699702

@@ -730,6 +733,68 @@ static int ds_rds_create_from_dom(xmlDocPtr* ret, xmlDocPtr sds_doc, xmlDocPtr x
730733
xmlDOMWrapReconcileNamespaces(sds_wrap_ctxt, sds_res_node, 0);
731734
xmlDOMWrapFreeCtxt(sds_wrap_ctxt);
732735

736+
if (tailoring_doc && strcmp(tailoring_filepath, "NONEXISTENT")) {
737+
char *mangled_tailoring_filepath = ds_sds_mangle_filepath(tailoring_filepath);
738+
char *tailoring_component_id = oscap_sprintf("scap_org.open-scap_comp_%s_tailoring", mangled_tailoring_filepath);
739+
char *tailoring_component_ref_id = oscap_sprintf("scap_org.open-scap_cref_%s_tailoring", mangled_tailoring_filepath);
740+
741+
// Need unique id (ref_id) - if generated already exists, then create new one
742+
int counter = 0;
743+
while (lookup_component_in_collection(sds_doc, tailoring_component_id) != NULL) {
744+
free(tailoring_component_id);
745+
tailoring_component_id = oscap_sprintf("scap_org.open-scap_comp_%s_tailoring%03d", mangled_tailoring_filepath, counter++);
746+
}
747+
748+
counter = 0;
749+
while (ds_sds_find_component_ref(xmlDocGetRootElement(sds_res_node)->children, tailoring_component_ref_id) != NULL) {
750+
free(tailoring_component_ref_id);
751+
tailoring_component_ref_id = oscap_sprintf("scap_org.open-scap_cref_%s_tailoring%03d", mangled_tailoring_filepath, counter++);
752+
}
753+
754+
free(mangled_tailoring_filepath);
755+
756+
xmlDOMWrapCtxtPtr tailoring_wrap_ctxt = xmlDOMWrapNewCtxt();
757+
xmlNodePtr tailoring_res_node = NULL;
758+
xmlDOMWrapCloneNode(tailoring_wrap_ctxt, tailoring_doc, xmlDocGetRootElement(tailoring_doc),
759+
&tailoring_res_node, doc, NULL, 1, 0);
760+
xmlNsPtr sds_ns = sds_res_node->ns;
761+
xmlNodePtr tailoring_component = xmlNewNode(sds_ns, BAD_CAST "component");
762+
xmlSetProp(tailoring_component, BAD_CAST "id", BAD_CAST tailoring_component_id);
763+
xmlSetProp(tailoring_component, BAD_CAST "timestamp", BAD_CAST tailoring_doc_timestamp);
764+
xmlAddChild(tailoring_component, tailoring_res_node);
765+
xmlAddChild(sds_res_node, tailoring_component);
766+
767+
xmlNodePtr checklists_element = NULL;
768+
xmlNodePtr datastream_element = node_get_child_element(sds_res_node, "data-stream");
769+
if (datastream_element == NULL) {
770+
datastream_element = xmlNewNode(sds_ns, "data-stream");
771+
xmlAddChild(sds_res_node, datastream_element);
772+
checklists_element = xmlNewNode(sds_ns, "checklists");
773+
xmlAddChild(datastream_element, checklists_element);
774+
}
775+
else {
776+
checklists_element = node_get_child_element(datastream_element, "checklists");
777+
}
778+
779+
xmlNodePtr tailoring_component_ref = xmlNewNode(sds_ns, BAD_CAST "component-ref");
780+
xmlSetProp(tailoring_component_ref, BAD_CAST "id", BAD_CAST tailoring_component_ref_id);
781+
char *tailoring_cref_href = oscap_sprintf("#%s", tailoring_component_id);
782+
xmlNsPtr xlink_ns = xmlSearchNsByHref(doc, sds_res_node, BAD_CAST xlink_ns_uri);
783+
if (!xlink_ns) {
784+
oscap_seterr(OSCAP_EFAMILY_XML,
785+
"Unable to find namespace '%s' in the XML DOM tree. "
786+
"This is most likely an internal error!.",
787+
xlink_ns_uri);
788+
return -1;
789+
}
790+
xmlSetNsProp(tailoring_component_ref, xlink_ns, BAD_CAST "href", BAD_CAST tailoring_cref_href);
791+
free(tailoring_cref_href);
792+
xmlAddChild(checklists_element, tailoring_component_ref);
793+
794+
xmlDOMWrapReconcileNamespaces(tailoring_wrap_ctxt, tailoring_res_node, 0);
795+
xmlDOMWrapFreeCtxt(tailoring_wrap_ctxt);
796+
}
797+
733798
xmlAddChild(report_request, arf_content);
734799

735800
xmlAddChild(report_requests, report_request);
@@ -758,22 +823,43 @@ static int ds_rds_create_from_dom(xmlDocPtr* ret, xmlDocPtr sds_doc, xmlDocPtr x
758823
return 0;
759824
}
760825

761-
struct oscap_source *ds_rds_create_source(struct oscap_source *sds_source, struct oscap_source *xccdf_result_source, struct oscap_htable *oval_result_sources, struct oscap_htable *oval_result_mapping, struct oscap_htable *arf_report_mapping, const char *target_file)
826+
struct oscap_source *ds_rds_create_source(struct oscap_source *sds_source, struct oscap_source *tailoring_source, struct oscap_source *xccdf_result_source, struct oscap_htable *oval_result_sources, struct oscap_htable *oval_result_mapping, struct oscap_htable *arf_report_mapping, const char *target_file)
762827
{
763828
xmlDoc *sds_doc = oscap_source_get_xmlDoc(sds_source);
764829
if (sds_doc == NULL) {
765830
return NULL;
766831
}
832+
767833
xmlDoc *result_file_doc = oscap_source_get_xmlDoc(xccdf_result_source);
768834
if (result_file_doc == NULL) {
769835
return NULL;
770836
}
771837

838+
xmlDoc *tailoring_doc = NULL;
839+
char *tailoring_doc_timestamp = NULL;
840+
char *tailoring_filepath = NULL;
841+
if (tailoring_source) {
842+
tailoring_doc = oscap_source_get_xmlDoc(tailoring_source);
843+
if (tailoring_doc == NULL) {
844+
return NULL;
845+
}
846+
tailoring_filepath = oscap_source_get_filepath(tailoring_source);
847+
struct stat file_stat;
848+
if (stat(tailoring_filepath, &file_stat) == 0) {
849+
const size_t max_timestamp_len = 32;
850+
tailoring_doc_timestamp = malloc(max_timestamp_len);
851+
strftime(tailoring_doc_timestamp, max_timestamp_len, "%Y-%m-%dT%H:%M:%S", localtime(&file_stat.st_mtime));
852+
}
853+
}
854+
772855
xmlDocPtr rds_doc = NULL;
773-
if (ds_rds_create_from_dom(&rds_doc, sds_doc, result_file_doc,
856+
857+
if (ds_rds_create_from_dom(&rds_doc, sds_doc, tailoring_doc, tailoring_filepath, tailoring_doc_timestamp, result_file_doc,
774858
oval_result_sources, oval_result_mapping, arf_report_mapping) != 0) {
859+
free(tailoring_doc_timestamp);
775860
return NULL;
776861
}
862+
free(tailoring_doc_timestamp);
777863
return oscap_source_new_from_xmlDoc(rds_doc, target_file);
778864
}
779865

@@ -803,7 +889,7 @@ int ds_rds_create(const char* sds_file, const char* xccdf_result_file, const cha
803889
}
804890
}
805891
if (result == 0) {
806-
struct oscap_source *target_rds = ds_rds_create_source(sds_source, xccdf_result_source, oval_result_sources, oval_result_mapping, arf_report_mapping, target_file);
892+
struct oscap_source *target_rds = ds_rds_create_source(sds_source, NULL, xccdf_result_source, oval_result_sources, oval_result_mapping, arf_report_mapping, target_file);
807893
result = target_rds == NULL;
808894
if (result == 0) {
809895
result = oscap_source_save_as(target_rds, NULL);

src/DS/rds_priv.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ OSCAP_HIDDEN_START;
3737
xmlNode *ds_rds_lookup_container(xmlDocPtr doc, const char *container_name);
3838
xmlNode *ds_rds_lookup_component(xmlDocPtr doc, const char *container_name, const char *component_name, const char *id);
3939
int ds_rds_dump_arf_content(struct ds_rds_session *session, const char *container_name, const char *component_name, const char *content_id);
40-
struct oscap_source *ds_rds_create_source(struct oscap_source *sds_source, struct oscap_source *xccdf_result_source, struct oscap_htable *oval_result_sources, struct oscap_htable *oval_result_mapping, struct oscap_htable *arf_report_mapping, const char *target_file);
40+
struct oscap_source *ds_rds_create_source(struct oscap_source *sds_source, struct oscap_source *tailoring_source, struct oscap_source *xccdf_result_source, struct oscap_htable *oval_result_sources, struct oscap_htable *oval_result_mapping, struct oscap_htable *arf_report_mapping, const char *target_file);
4141
xmlNodePtr ds_rds_create_report(xmlDocPtr target_doc, xmlNodePtr reports_node, xmlDocPtr source_doc, const char* report_id);
4242

4343
OSCAP_HIDDEN_END;

src/DS/sds.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ xmlNode *containter_get_component_ref_by_id(xmlNode *container, const char *comp
113113
return NULL;
114114
}
115115

116-
static xmlNodePtr ds_sds_find_component_ref(xmlNodePtr datastream, const char* id)
116+
xmlNodePtr ds_sds_find_component_ref(xmlNodePtr datastream, const char* id)
117117
{
118118
/* This searches for a ds:component-ref (XLink) element with a given id.
119119
* It returns a first such element in a given ds:data-stream.
@@ -133,7 +133,7 @@ static xmlNodePtr ds_sds_find_component_ref(xmlNodePtr datastream, const char* i
133133
return NULL;
134134
}
135135

136-
static xmlNodePtr _lookup_component_in_collection(xmlDocPtr doc, const char *component_id)
136+
xmlNodePtr lookup_component_in_collection(xmlDocPtr doc, const char *component_id)
137137
{
138138
xmlNodePtr root = xmlDocGetRootElement(doc);
139139
xmlNodePtr component = NULL;
@@ -271,7 +271,7 @@ static xmlNodePtr ds_sds_get_component_root_by_id(xmlDoc *doc, const char* compo
271271
if (component_id == NULL) {
272272
component = (xmlNodePtr)doc;
273273
} else {
274-
component = _lookup_component_in_collection(doc, component_id);
274+
component = lookup_component_in_collection(doc, component_id);
275275
if (component == NULL)
276276
{
277277
oscap_seterr(OSCAP_EFAMILY_XML, "Component of given id '%s' was not found in the document.", component_id);
@@ -774,7 +774,7 @@ static int ds_sds_compose_catalog_has_uri(xmlDocPtr doc, xmlNodePtr catalog, con
774774

775775
// takes given relative filepath and mangles it so that it's acceptable
776776
// as a component id
777-
static char* ds_sds_mangle_filepath(const char* filepath)
777+
char* ds_sds_mangle_filepath(const char* filepath)
778778
{
779779
if (filepath == NULL)
780780
return NULL;
@@ -1063,7 +1063,7 @@ static int ds_sds_compose_add_component_source_with_ref(xmlDocPtr doc, xmlNodePt
10631063
extended_component ? "e" : "", mangled_filepath);
10641064

10651065
int counter = 0;
1066-
while (_lookup_component_in_collection(doc, comp_id) != NULL) {
1066+
while (lookup_component_in_collection(doc, comp_id) != NULL) {
10671067
// While a component of the given ID already exists, generate a new one
10681068
free(comp_id);
10691069
comp_id = oscap_sprintf("scap_org.open-scap_%scomp_%s%03d",

src/DS/sds_priv.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,5 +45,10 @@ int ds_sds_dump_component_ref_as(const xmlNodePtr component_ref, struct ds_sds_s
4545
xmlDocPtr ds_sds_compose_xmlDoc_from_xccdf(const char *xccdf_file);
4646
xmlDocPtr ds_sds_compose_xmlDoc_from_xccdf_source(struct oscap_source *xccdf_source);
4747

48+
xmlNodePtr lookup_component_in_collection(xmlDocPtr doc, const char *component_id);
49+
xmlNodePtr ds_sds_find_component_ref(xmlNodePtr datastream, const char *id);
50+
51+
char *ds_sds_mangle_filepath(const char *filepath);
52+
4853
OSCAP_HIDDEN_END;
4954
#endif

src/XCCDF/xccdf_session.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@ static struct oscap_source* xccdf_session_create_arf_source(struct xccdf_session
234234
sds_source = oscap_source_new_from_xmlDoc(sds_doc, NULL);
235235
}
236236

237-
session->oval.arf_report = ds_rds_create_source(sds_source, session->xccdf.result_source, session->oval.result_sources, session->oval.results_mapping, session->oval.arf_report_mapping, session->export.arf_file);
237+
session->oval.arf_report = ds_rds_create_source(sds_source, session->tailoring.user_file, session->xccdf.result_source, session->oval.result_sources, session->oval.results_mapping, session->oval.arf_report_mapping, session->export.arf_file);
238238
if (!xccdf_session_is_sds(session)) {
239239
oscap_source_free(sds_source);
240240
}

tests/API/XCCDF/tailoring/Makefile.am

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,7 @@ EXTRA_DIST = \
1515
simple-tailoring.xml \
1616
simple-tailoring11.xml \
1717
simple-tailoring-autonegotiation.xml \
18-
simple-ds.xml
18+
simple-ds.xml \
19+
baseline.xccdf.xml \
20+
baseline.oval.xml \
21+
baseline.tailoring.xml

tests/API/XCCDF/tailoring/all.sh

Lines changed: 55 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
. ../../../test_common.sh
77

8-
#set -e -o pipefail
8+
set -e -o pipefail
99

1010
function test_api_xccdf_tailoring {
1111
local INPUT=$srcdir/$1
@@ -84,6 +84,56 @@ function test_api_xccdf_tailoring_autonegotiation {
8484
rm -f $result
8585
}
8686

87+
function test_api_xccdf_tailoring_simple_include_in_arf {
88+
local INPUT=$srcdir/$1
89+
local TAILORING=$srcdir/$2
90+
91+
result=`mktemp`
92+
$OSCAP xccdf eval --tailoring-file $TAILORING --results-arf $result $INPUT
93+
if [ "$?" != "0" ]; then
94+
return 1
95+
fi
96+
97+
assert_exists 1 '/arf:asset-report-collection/arf:report-requests/arf:report-request/arf:content/ds:data-stream-collection/ds:component/Tailoring'
98+
rm -f $result
99+
}
100+
101+
function test_api_xccdf_tailoring_profile_include_in_arf {
102+
local INPUT=$srcdir/$1
103+
local TAILORING=$srcdir/$2
104+
105+
result=`mktemp`
106+
# "xccdf_com.example.www_profile_customized" customizes "xccdf_com.example.www_profile_baseline1"
107+
$OSCAP xccdf eval --tailoring-file $TAILORING --profile "xccdf_com.example.www_profile_customized" --results-arf $result $INPUT || [ "$?" == "2" ]
108+
109+
component_xpath='/arf:asset-report-collection/arf:report-requests/arf:report-request/arf:content/ds:data-stream-collection/ds:component'
110+
assert_exists 3 $component_xpath
111+
assert_exists 3 $component_xpath'/@timestamp'
112+
assert_exists 1 $component_xpath'/xccdf:Tailoring'
113+
assert_exists 1 $component_xpath'/xccdf:Tailoring/xccdf:Profile'
114+
assert_exists 1 $component_xpath'/xccdf:Tailoring/xccdf:Profile[@id="xccdf_com.example.www_profile_customized"]'
115+
assert_exists 1 $component_xpath'/xccdf:Tailoring/xccdf:Profile[@extends="xccdf_com.example.www_profile_baseline1"]'
116+
rm -f $result
117+
}
118+
119+
function test_api_xccdf_tailoring_profile_generate_fix {
120+
local INPUT=$srcdir/$1
121+
local TAILORING=$srcdir/$2
122+
123+
tailoring_result=`mktemp`
124+
fix_result=`mktemp`
125+
# tailoring profile only with "always fail" rule and generate bash fix
126+
$OSCAP xccdf eval --tailoring-file $TAILORING --profile "xccdf_com.example.www_profile_customized" --results-arf $tailoring_result $INPUT || [ "$?" == "2" ]
127+
tailoring_id=$($XPATH $tailoring_result 'string(//ds:component-ref[contains(@id, "_tailoring")]/@id)')
128+
$OSCAP xccdf generate fix --tailoring-id $tailoring_id --result-id xccdf_org.open-scap_test-result_xccdf-com.example.www_profile_customized --results $fix_result $tailoring_result
129+
130+
if ! grep -q "echo \"Fix the first rule\"" $fix_result; then
131+
return 1
132+
fi
133+
134+
rm -f $tailoring_result $fix_result
135+
}
136+
87137
# Testing.
88138

89139
test_init "test_api_xccdf_tailoring.log"
@@ -101,5 +151,9 @@ test_run "test_api_xccdf_tailoring_ds_hybrid_override" test_api_xccdf_tailoring_
101151
test_run "test_api_xccdf_tailoring_oscap_info_11" test_api_xccdf_tailoring_oscap_info simple-tailoring11.xml 1
102152
test_run "test_api_xccdf_tailoring_oscap_info_12" test_api_xccdf_tailoring_oscap_info simple-tailoring.xml 1
103153
test_run "test_api_xccdf_tailoring_autonegotiation" test_api_xccdf_tailoring_autonegotiation simple-tailoring-autonegotiation.xml xccdf_org.open-scap_profile_default 1
154+
test_run "test_api_xccdf_tailoring_simple_include_in_arf" test_api_xccdf_tailoring_simple_include_in_arf simple-xccdf.xml simple-tailoring.xml
155+
test_run "test_api_xccdf_tailoring_profile_include_in_arf" test_api_xccdf_tailoring_profile_include_in_arf baseline.xccdf.xml baseline.tailoring.xml
156+
test_run "test_api_xccdf_tailoring_profile_generate_fix" test_api_xccdf_tailoring_profile_generate_fix baseline.xccdf.xml baseline.tailoring.xml
157+
104158

105159
test_exit
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
<oval_definitions xsi:schemaLocation="http://oval.mitre.org/XMLSchema/oval-definitions-5 oval-definitions-schema.xsd http://oval.mitre.org/XMLSchema/oval-definitions-5#independent independent-definitions-schema.xsd http://oval.mitre.org/XMLSchema/oval-definitions-5#windows windows-definitions-schema.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://oval.mitre.org/XMLSchema/oval-definitions-5" xmlns:ind-def="http://oval.mitre.org/XMLSchema/oval-definitions-5#independent" xmlns:oval-def="http://oval.mitre.org/XMLSchema/oval-definitions-5" xmlns:oval="http://oval.mitre.org/XMLSchema/oval-common-5" xmlns:win-def="http://oval.mitre.org/XMLSchema/oval-definitions-5#windows">
2+
<generator>
3+
<oval:schema_version>5.11</oval:schema_version>
4+
<oval:timestamp>2018-01-12T10:41:00-05:00</oval:timestamp>
5+
</generator>
6+
<definitions>
7+
<definition class="compliance" id="oval:x:def:1" version="1">
8+
<metadata>
9+
<title>FAIL</title>
10+
<description>always fail</description>
11+
</metadata>
12+
<criteria>
13+
<criterion comment="always failing test" test_ref="oval:x:tst:1"/>
14+
</criteria>
15+
</definition>
16+
<definition class="compliance" id="oval:x:def:2" version="1">
17+
<metadata>
18+
<title>PASS</title>
19+
<description>always pass</description>
20+
</metadata>
21+
<criteria>
22+
<criterion comment="always passing test" test_ref="oval:x:tst:2"/>
23+
</criteria>
24+
</definition>
25+
</definitions>
26+
<tests>
27+
<variable_test id="oval:x:tst:1" check="all" comment="always fail" version="1" xmlns="http://oval.mitre.org/XMLSchema/oval-definitions-5#independent">
28+
<object object_ref="oval:x:obj:1"/>
29+
<state state_ref="oval:x:ste:1"/>
30+
</variable_test>
31+
<variable_test id="oval:x:tst:2" check="all" comment="always pass" version="1" xmlns="http://oval.mitre.org/XMLSchema/oval-definitions-5#independent">
32+
<object object_ref="oval:x:obj:1"/>
33+
<state state_ref="oval:x:ste:2"/>
34+
</variable_test>
35+
</tests>
36+
<objects>
37+
<variable_object id="oval:x:obj:1" version="1" comment="x" xmlns="http://oval.mitre.org/XMLSchema/oval-definitions-5#independent">
38+
<var_ref>oval:x:var:1</var_ref>
39+
</variable_object>
40+
</objects>
41+
<states>
42+
<variable_state id="oval:x:ste:1" version="1" xmlns="http://oval.mitre.org/XMLSchema/oval-definitions-5#independent">
43+
<value datatype="int" operation="equals">0</value>
44+
</variable_state>
45+
<variable_state id="oval:x:ste:2" version="1" xmlns="http://oval.mitre.org/XMLSchema/oval-definitions-5#independent">
46+
<value datatype="int" operation="equals">100</value>
47+
</variable_state>
48+
</states>
49+
<variables>
50+
<constant_variable id="oval:x:var:1" version="1" comment="x" datatype="int">
51+
<value>100</value>
52+
</constant_variable>
53+
</variables>
54+
</oval_definitions>
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<xccdf:Tailoring xmlns:xccdf="http://checklists.nist.gov/xccdf/1.2" id="xccdf_scap-workbench_tailoring_default">
3+
<xccdf:benchmark href="/tmp/SCAP Workbench-cpJkKp/baseline.xccdf.xml"/>
4+
<xccdf:version time="2018-12-13T10:02:12">1</xccdf:version>
5+
<xccdf:Profile id="xccdf_com.example.www_profile_customized" extends="xccdf_com.example.www_profile_baseline1">
6+
<xccdf:title xmlns:xhtml="http://www.w3.org/1999/xhtml" xml:lang="en-US" override="true">Baseline Testing Profile 1 [CUSTOMIZED]</xccdf:title>
7+
<xccdf:description xmlns:xhtml="http://www.w3.org/1999/xhtml" xml:lang="en-US" override="true">This profile customizes 'xccdf_com.example.www_profile_baseline1'. This profile selects only the first rule.</xccdf:description>
8+
<xccdf:select idref="xccdf_com.example.www_rule_second" selected="false"/>
9+
</xccdf:Profile>
10+
</xccdf:Tailoring>

0 commit comments

Comments
 (0)