forked from pool/openscap
This commit is contained in:
parent
128a9a554b
commit
99499cd1d3
@ -1,15 +1,18 @@
|
|||||||
diff -ru openscap-1.2.16/utils/oscap-cvrf.c openscap-1.2.16.xx/utils/oscap-cvrf.c
|
Index: openscap-1.2.16/utils/oscap-cvrf.c
|
||||||
--- openscap-1.2.16/utils/oscap-cvrf.c 2017-11-14 12:48:32.000000000 +0100
|
===================================================================
|
||||||
+++ openscap-1.2.16.xx/utils/oscap-cvrf.c 2017-11-14 14:59:57.353065728 +0100
|
--- openscap-1.2.16.orig/utils/oscap-cvrf.c
|
||||||
@@ -60,6 +60,7 @@
|
+++ openscap-1.2.16/utils/oscap-cvrf.c
|
||||||
|
@@ -59,7 +59,8 @@ static struct oscap_module CVRF_EVALUATE
|
||||||
|
.func = app_cvrf_evaluate,
|
||||||
.help = "Options:\n"
|
.help = "Options:\n"
|
||||||
" --index\r\t\t\t\t - Use index file to evaluate a directory of CVRF files.\n"
|
" --index\r\t\t\t\t - Use index file to evaluate a directory of CVRF files.\n"
|
||||||
" --results\r\t\t\t\t - Filename to which evaluation results will be saved.\n",
|
- " --results\r\t\t\t\t - Filename to which evaluation results will be saved.\n",
|
||||||
|
+ " --results\r\t\t\t\t - Filename to which evaluation results will be saved.\n"
|
||||||
+ " --productid\r\t\t\t\t - Product ID to use (currently not yet auto-detected).\n",
|
+ " --productid\r\t\t\t\t - Product ID to use (currently not yet auto-detected).\n",
|
||||||
};
|
};
|
||||||
|
|
||||||
static struct oscap_module CVRF_EXPORT_MODULE = {
|
static struct oscap_module CVRF_EXPORT_MODULE = {
|
||||||
@@ -98,10 +99,18 @@
|
@@ -98,10 +99,18 @@ static int app_cvrf_evaluate(const struc
|
||||||
// Temporary hardcoded CPE until CPE name can be found without input by CVRF functions
|
// Temporary hardcoded CPE until CPE name can be found without input by CVRF functions
|
||||||
// themselves
|
// themselves
|
||||||
const char *os_name = "Red Hat Enterprise Linux Desktop Supplementary (v. 6)";
|
const char *os_name = "Red Hat Enterprise Linux Desktop Supplementary (v. 6)";
|
||||||
@ -31,7 +34,7 @@ diff -ru openscap-1.2.16/utils/oscap-cvrf.c openscap-1.2.16.xx/utils/oscap-cvrf.
|
|||||||
|
|
||||||
if (oscap_source_save_as(export_source, action->cvrf_action->f_results) == -1) {
|
if (oscap_source_save_as(export_source, action->cvrf_action->f_results) == -1) {
|
||||||
result = OSCAP_ERROR;
|
result = OSCAP_ERROR;
|
||||||
@@ -180,6 +189,7 @@
|
@@ -180,6 +189,7 @@ enum cvrf_opt {
|
||||||
CVRF_OPT_INDEX,
|
CVRF_OPT_INDEX,
|
||||||
CVRF_OPT_RESULT_FILE,
|
CVRF_OPT_RESULT_FILE,
|
||||||
CVRF_OPT_OUTPUT_FILE,
|
CVRF_OPT_OUTPUT_FILE,
|
||||||
@ -39,7 +42,7 @@ diff -ru openscap-1.2.16/utils/oscap-cvrf.c openscap-1.2.16.xx/utils/oscap-cvrf.
|
|||||||
};
|
};
|
||||||
|
|
||||||
bool getopt_cvrf(int argc, char **argv, struct oscap_action *action) {
|
bool getopt_cvrf(int argc, char **argv, struct oscap_action *action) {
|
||||||
@@ -191,6 +201,7 @@
|
@@ -191,6 +201,7 @@ bool getopt_cvrf(int argc, char **argv,
|
||||||
{"index", 0, NULL, CVRF_OPT_INDEX},
|
{"index", 0, NULL, CVRF_OPT_INDEX},
|
||||||
{"results", 1, NULL, CVRF_OPT_RESULT_FILE},
|
{"results", 1, NULL, CVRF_OPT_RESULT_FILE},
|
||||||
{"output", 1, NULL, CVRF_OPT_OUTPUT_FILE},
|
{"output", 1, NULL, CVRF_OPT_OUTPUT_FILE},
|
||||||
@ -47,7 +50,7 @@ diff -ru openscap-1.2.16/utils/oscap-cvrf.c openscap-1.2.16.xx/utils/oscap-cvrf.
|
|||||||
{0, 0, 0, 0}
|
{0, 0, 0, 0}
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -206,6 +217,9 @@
|
@@ -206,6 +217,9 @@ bool getopt_cvrf(int argc, char **argv,
|
||||||
case CVRF_OPT_OUTPUT_FILE:
|
case CVRF_OPT_OUTPUT_FILE:
|
||||||
cvrf_action->f_output = optarg;
|
cvrf_action->f_output = optarg;
|
||||||
break;
|
break;
|
||||||
@ -57,10 +60,11 @@ diff -ru openscap-1.2.16/utils/oscap-cvrf.c openscap-1.2.16.xx/utils/oscap-cvrf.
|
|||||||
default:
|
default:
|
||||||
return oscap_module_usage(action->module, stderr, NULL);
|
return oscap_module_usage(action->module, stderr, NULL);
|
||||||
}
|
}
|
||||||
diff -ru openscap-1.2.16/utils/oscap-tool.h openscap-1.2.16.xx/utils/oscap-tool.h
|
Index: openscap-1.2.16/utils/oscap-tool.h
|
||||||
--- openscap-1.2.16/utils/oscap-tool.h 2017-11-14 12:48:32.000000000 +0100
|
===================================================================
|
||||||
+++ openscap-1.2.16.xx/utils/oscap-tool.h 2017-11-14 14:58:35.981147877 +0100
|
--- openscap-1.2.16.orig/utils/oscap-tool.h
|
||||||
@@ -104,6 +104,7 @@
|
+++ openscap-1.2.16/utils/oscap-tool.h
|
||||||
|
@@ -104,6 +104,7 @@ struct cvrf_action {
|
||||||
char *f_cvrf;
|
char *f_cvrf;
|
||||||
char *f_results;
|
char *f_results;
|
||||||
char *f_output;
|
char *f_output;
|
||||||
|
Loading…
Reference in New Issue
Block a user