optiopay / klar

Integration of Clair and Docker Registry
MIT License
506 stars 140 forks source link

Klar output JSON #101

Closed vasartori closed 6 years ago

vasartori commented 6 years ago

When we turn on the output of klar in json, at least 3 first lines is a non json. See the example:

$ ./klar <image-path>
clair timeout 1m0s
docker timeout: 1m0s
no whitelist file
{"LayerCount":6,"Vulnerabilities":{"High":[{"Name":"CVE-2016-9843","NamespaceName":"alpine:v3.4","Link":"https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2016-9843","Severity":"High","Metadata":{"NVD":{"CVSSv2":{"Score":7.5,"Vectors":"AV:N/AC:L/Au:N/C:P/I:P"}}},"FixedBy":"1.2.11-r0"},{"Name":"CVE-2016-9841","NamespaceName":"alpine:v3.4","Link":"https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2016-9841","Severity":"High","Metadata":{"NVD":{"CVSSv2":{"Score":7.5,"Vectors":"AV:N/AC:L/Au:N/C:P/I:P"}}},"FixedBy":"1.2.11-r0"}]}}
hashmap commented 6 years ago

Fixed in 2.1.1, good work @vasartori