|
70 | 70 | #define XCCDF_NUMERIC_SIZE 32
|
71 | 71 |
|
72 | 72 | // References containing STIG Rule IDs can be found by their href attribute, it must match the following url
|
73 |
| -static const char *DISA_STIG_VIEWER_HREF = "http://iase.disa.mil/stigs/Pages/stig-viewing-guidance.aspx"; |
| 73 | +static const char *DISA_STIG_VIEWER_HREF[] = { "http://iase.disa.mil/stigs/Pages/stig-viewing-guidance.aspx", |
| 74 | + "https://public.cyber.mil/stigs/srg-stig-tools/" }; |
74 | 75 |
|
75 | 76 | // constants
|
76 | 77 | static const xccdf_numeric XCCDF_SCORE_MAX_DAFAULT = 100.0f;
|
@@ -1085,7 +1086,8 @@ void xccdf_result_to_dom(struct xccdf_result *result, xmlNode *result_node, xmlD
|
1085 | 1086 | struct oscap_reference_iterator *references = xccdf_item_get_references(item);
|
1086 | 1087 | while (oscap_reference_iterator_has_more(references)) {
|
1087 | 1088 | struct oscap_reference *ref = oscap_reference_iterator_next(references);
|
1088 |
| - if (strcmp(oscap_reference_get_href(ref), DISA_STIG_VIEWER_HREF) == 0) { |
| 1089 | + if (strcmp(oscap_reference_get_href(ref), DISA_STIG_VIEWER_HREF[0]) == 0 || |
| 1090 | + strcmp(oscap_reference_get_href(ref), DISA_STIG_VIEWER_HREF[1]) == 0) { |
1089 | 1091 | const char *stig_rule_id = oscap_reference_get_title(ref);
|
1090 | 1092 |
|
1091 | 1093 | xccdf_test_result_type_t other_res = (xccdf_test_result_type_t)oscap_htable_detach(nodes_by_rule_id, stig_rule_id);
|
@@ -1292,7 +1294,8 @@ void xccdf_rule_result_to_dom(struct xccdf_rule_result *result, xmlDoc *doc, xml
|
1292 | 1294 | struct oscap_reference_iterator *references = xccdf_item_get_references(item);
|
1293 | 1295 | while (oscap_reference_iterator_has_more(references)) {
|
1294 | 1296 | struct oscap_reference *ref = oscap_reference_iterator_next(references);
|
1295 |
| - if (strcmp(oscap_reference_get_href(ref), DISA_STIG_VIEWER_HREF) == 0) { |
| 1297 | + if (strcmp(oscap_reference_get_href(ref), DISA_STIG_VIEWER_HREF[0]) == 0 || |
| 1298 | + strcmp(oscap_reference_get_href(ref), DISA_STIG_VIEWER_HREF[1]) == 0) { |
1296 | 1299 | const char *stig_rule_id = oscap_reference_get_title(ref);
|
1297 | 1300 |
|
1298 | 1301 | xccdf_test_result_type_t expected_res = (xccdf_test_result_type_t)oscap_htable_get(nodes_by_rule_id, stig_rule_id);
|
|
0 commit comments