Bug 14630 - cve-check mishandles -
Summary: cve-check mishandles -
Status: RESOLVED NOTABUG
Alias: None
Product: OE-Core
Classification: Build System, Metadata & Runtime
Component: devtools / tool chain (show other bugs)
Version: 4.0
Hardware: x86 Multiple
: Medium+ enhancement
Target Milestone: 4.2 M4
Assignee: Geoffrey Giry
QA Contact:
URL:
Whiteboard:
Depends on:
Blocks:
 
Reported: 2021-11-15 17:34 UTC by Ross Burton
Modified: 2023-04-03 08:58 UTC (History)
5 users (show)

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: No (bug/feature does not impact docs)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ross Burton 2021-11-15 17:34:30 UTC
https://nvd.nist.gov/vuln/detail/CVE-2021-3682 has this CPE:

cpe:2.3:a:qemu:qemu:6.1.0:-:*:*:*:*:*:*

That means "not 6.1.0". This isn't handled by our comparison logic as this CVE gets reported although have 6.1.0.

References to the specs:
https://nvlpubs.nist.gov/nistpubs/Legacy/IR/nistir7695.pdf
https://nvlpubs.nist.gov/nistpubs/Legacy/IR/nistir7696.pdf
Comment 1 Geoffrey Giry 2023-03-03 11:04:41 UTC
The hyphen ("-") in the given CPE is part of the update field.

This field allows specifying the update name of the version.

From my understanding of the linked documentation, CPE should be read as follows:

cpe:2.3:a:qemu:qemu:6.1.0:rc1:*:*:*:*:*:* points to 6.1.0-rc1
cpe:2.3:a:qemu:qemu:6.1.0:-:*:*:*:*:*:* points to 6.1.0, with no update applied
cpe:2.3:a:qemu:qemu:6.1.0:*:*:*:*:*:*:* points to all updates of 6.1.0

If I misunderstood the notation, can you please point to the part of the doc detailing the usage of hyphen to means "not in"?

If I did understand the notation correctly, then I think the issue is in NVD, and the line cpe:2.3:a:qemu:qemu:6.1.0:-:*:*:*:*:*:* should not be listed as impacted configuration.
And in that case I think cve-check works as intended
Comment 2 Yoann Congal 2023-03-07 17:28:29 UTC
Ross, what do you think about the above comment?
(Setting NEEDINFO and owner)
Comment 3 Ross Burton 2023-03-30 16:05:24 UTC
I like that argument.  Geoffrey: would you be willing to contact NIST and get the CPE updated?  If they accept the changes, I was wrong, and we can close this bug
Comment 4 Geoffrey Giry 2023-03-31 07:30:51 UTC
Ross, I have sent a mail to NVD for change.
I will update the ticket as soon as I have news
Comment 5 Geoffrey Giry 2023-03-31 22:02:24 UTC
I already have news, NVD approved the change and the CVE page is already updated: https://nvd.nist.gov/vuln/detail/CVE-2021-3682

Therefore, I am closing this ticket.
Comment 6 Ross Burton 2023-04-03 08:58:27 UTC
Perfect, thanks!