Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.
Sign upimplement friendly field aliases (like "date" instead of "public_date" and "severity" instead of "threat_severity") for --fields option #30
Comments
ryran
added
the
enhancement
label
Nov 7, 2016
ryran
self-assigned this
Nov 7, 2016
ryran
changed the title from
implement friendly field aliases (like "date" instead of "public_date" and "impact" instead of "threat_severity") for --fields option; make fields case-insensitive
to
implement friendly field aliases (like "date" instead of "public_date" and "severity" instead of "threat_severity") for --fields option
Nov 8, 2016
added a commit
that referenced
this issue
Nov 8, 2016
This comment has been minimized.
Show comment
Hide comment
This comment has been minimized.
Show comment
Hide comment
ryran
Nov 8, 2016
Owner
DONE!
$ rhsecapi --help
...
CVE DISPLAY OPTIONS:
-f, --fields FIELDS Customize field display via comma-separated case-
insensitive list (default: threat_severity,
public_date, bugzilla, affected_release,
package_state); see --all-fields option for full list
of official API-provided fields; shorter field
aliases: threat_severity → severity, public_date →
date, affected_release → fixed_releases or fixed or
releases, package_state → fix_states or states;
optionally prepend FIELDS with plus (+) sign to add
fields to the default (e.g., '-f +iava,cvss3') or a
caret (^) to remove fields from the default (e.g., '-f
^bugzilla,severity')
...
$ rhsecapi CVE-2016-6302 -f janky
rhsecapi: Field 'janky' is not a supported field; valid fields:
threat_severity, public_date, iava, cwe, cvss, cvss3, bugzilla, acknowledgement, details, statement, mitigation, upstream_fix, references, affected_release, package_state, severity, releases, fixed_releases, states, fix_states, date, fixed
$ rhsecapi CVE-2016-6302 -vf releases,severity
DEBUG THREADS: '1'
Getting 'https://access.redhat.com/labs/securitydataapi/cve/CVE-2016-6302.json' ...
Valid Red Hat CVE results retrieved: 1 of 1
DEBUG FIELDS: 'affected_release,threat_severity'
CVE-2016-6302
SEVERITY: Moderate Impact
FIXED_RELEASES:
Red Hat Enterprise Linux 6 [openssl-1.0.1e-48.el6_8.3]: RHSA-2016:1940
Red Hat Enterprise Linux 7 [openssl-1:1.0.1e-51.el7_2.7]: RHSA-2016:1940
|
DONE!
|
ryran
closed this
Nov 8, 2016
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
ryran commentedNov 7, 2016
Yep!