How do I create a report with OVAL vulnerabilities and the machines that have them?
Is there a way to add to this report a column that lists PCs that have each listed vulnerability? Also, if there aren't any machines that have it marked as vunerable I don't need them in the list.
select OVALNUMBER AS 'Definition ID',
if((upper(substring(source, 1, 3)) = 'CVE' || upper(substring(source, 1, 3)) = 'CAN'), SOURCE, '') as 'Reference' ,
TITLE as Name,
CLASS as Class from KBSYS.OVAL_DEFINITION D where D.CLASS = 'vulnerability' order by REFERENCE DESC
Edit: I'd have exactly what I needed if I could somehow combine the above report with this one:
select MACHINE.NAME as Machine,SYSTEM_DESCRIPTION as Description,OS_NAME as 'Operating System',
sum(CLASS='vulnerability' and RESULT = 'VULNERABLE') as Vulnerable,
sum(RESULT = 'SAFE' or (CLASS='inventory' AND RESULT='VULNERABLE')) as Safe,
sum(RESULT not in ('SAFE','VULNERABLE')) as Other ,count(*) as Tested from OVAL_STATUS, MACHINE, KBSYS.OVAL_DEFINITION O
where MACHINE.ID = MACHINE_ID and O.ID = OVAL_STATUS.OVAL_DEFINITION_ID
group by MACHINE_ID
I'm just not sure how...
Thank you,
awingren
select OVALNUMBER AS 'Definition ID',
if((upper(substring(source, 1, 3)) = 'CVE' || upper(substring(source, 1, 3)) = 'CAN'), SOURCE, '') as 'Reference' ,
TITLE as Name,
CLASS as Class from KBSYS.OVAL_DEFINITION D where D.CLASS = 'vulnerability' order by REFERENCE DESC
Edit: I'd have exactly what I needed if I could somehow combine the above report with this one:
select MACHINE.NAME as Machine,SYSTEM_DESCRIPTION as Description,OS_NAME as 'Operating System',
sum(CLASS='vulnerability' and RESULT = 'VULNERABLE') as Vulnerable,
sum(RESULT = 'SAFE' or (CLASS='inventory' AND RESULT='VULNERABLE')) as Safe,
sum(RESULT not in ('SAFE','VULNERABLE')) as Other ,count(*) as Tested from OVAL_STATUS, MACHINE, KBSYS.OVAL_DEFINITION O
where MACHINE.ID = MACHINE_ID and O.ID = OVAL_STATUS.OVAL_DEFINITION_ID
group by MACHINE_ID
I'm just not sure how...
Thank you,
awingren
1 Comment
[ + ] Show comment
Answers (0)
Please log in to answer
Be the first to answer this question
http://www.itninja.com/question/k1000-oval-reporting-1 - awingren 10 years ago