Hi,

How about running script using omp (cli) and then attaching files to email.
works for me.

--
Eero

2015-03-23 13:09 GMT+02:00 Selam Uzun <selam.u...@gmail.com>:

> Hello,
>
> I'm trying to get around this problem by trying to do something else : is
> it possible to send an alert with 2 reports format in one email ?
> Like, one TXT included report and one attached PDF report.
>
> (It's seems not but I'd like to have confirmation).
>
> Best regards,
> S. Uzun
>
> On 20 March 2015 at 16:13, Selam Uzun <selam.u...@gmail.com> wrote:
>
>> Thanks for your suggestions Matthew.
>>
>> I changed the egrep with xmlstarlet and added the filter. Unfortunately,
>> nothing changed.
>> It's really strange, I tried some other combinations : when I have 2 high
>> severity reports, the 2 reports gives me wrong informations:
>>
>> IP,Hostname,  ........ ,CVSS,Severity,High,Medium,Low,Log,False
>> Positive,Total
>> 127.0.0.1, ........  ,0.0,None,0,0,0,10,0,10
>> IP,Hostname, ........ ,CVSS,Severity,High,Medium,Low,Log,False
>> Positive,Total
>> 127.0.0.1, ........ ,0.0,None,0,0,0,10,0,10
>>
>> When I have 2 medium severity reports, the 2 reports gives me the good
>> informations:
>>
>> IP,Hostname, ........ ,CVSS,Severity,High,Medium,Low,Log,False
>> Positive,Total
>> 127.0.0.1, ........ ,4.3,Medium,0,2,0,7,0,9
>> IP,Hostname, ........ ,CVSS,Severity,High,Medium,Low,Log,False
>> Positive,Total
>> 127.0.0.1, ........ ,4.3,Medium,0,2,0,7,0,9
>>
>> It's like, whenever I have a high severity reports and I try to get it
>> with GET_REPORTS, without providing an id, I get wrong informations.
>>
>> Best regards,
>> S. Uzun
>>
>> On 20 March 2015 at 12:03, Matthew Mundell <matthew.mund...@greenbone.net
>> > wrote:
>>
>>> > -------------------------
>>> > #!/bin/sh
>>> >
>>> > # Description: import of all reports generated by OpenVAS
>>> >
>>> > IMPORT_FILE="openvas_reports.csv"
>>> >
>>> > # csv format id
>>> > REPORT_FORMAT_ID="9087b18c-626c-11e3-8892-406186ea4fc5"
>>> >
>>> > # Get reports
>>> > omp -u admin -w admin -X '
>>> > <get_reports format_id="'$REPORT_FORMAT_ID'"/>
>>>
>>> Try adding a filter to the GET_REPORTS, like filter="rows=-1
>>> levels=hmlg",
>>> or whatever filter you're using in GSA.
>>>
>>> > ' | egrep -o 'SVAsSG9zdG5hbWUsT1M[[:alnum:]]+' \
>>>
>>> You could use something like this instead:
>>>
>>> ' | xmlstarlet sel -t -v /get_reports_response/report/text\(\)
>>>
>>> >   | base64 -d > $IMPORT_FILE
>>> > -------------------------
>>>
>>> --
>>> Greenbone Networks GmbH
>>> Neuer Graben 17, 49074 Osnabrueck, Germany | AG Osnabrueck, HR B 202460
>>> Executive Directors: Lukas Grunwald, Dr. Jan-Oliver Wagner
>>>
>>
>>
>
> _______________________________________________
> Openvas-discuss mailing list
> Openvas-discuss@wald.intevation.org
> https://lists.wald.intevation.org/cgi-bin/mailman/listinfo/openvas-discuss
>
_______________________________________________
Openvas-discuss mailing list
Openvas-discuss@wald.intevation.org
https://lists.wald.intevation.org/cgi-bin/mailman/listinfo/openvas-discuss

Reply via email to