public inbox for openembedded-core@lists.openembedded.org
 help / color / mirror / Atom feed
From: Richard Purdie <richard.purdie@linuxfoundation.org>
To: martin.vonwillebrand@doubleopen.io,
	 openembedded-core@lists.openembedded.org
Cc: Joshua Watt <JPEWhacker@gmail.com>
Subject: Re: [OE-core] [RFC] Adding PURL identifiers to SPDX 3.0.1 install package elements
Date: Wed, 08 Apr 2026 22:23:21 +0100	[thread overview]
Message-ID: <f4bf51a0b26fcff35191bcedf8e51c09e27b856d.camel@linuxfoundation.org> (raw)
In-Reply-To: <e615740d-eff9-4125-a6e6-e6b58ee29225@doubleopen.io>

On Wed, 2026-04-08 at 16:19 +0300, Martin von Willebrand via lists.openembedded.org wrote:
> While working with ORT (OSS Review Toolkit) to analyse Yocto-generated 
> SPDX 3.0.1 documents for ongoing vulnerability management and 
> monitoring, I noticed that install package elements 
> (`software_primaryPurpose: install`) carry only a wildcard CPE 
> identifier, e.g.:
> 
> cpe:2.3:*:*:busybox:1.36.1:*:*:*:*:*:*:*
> 
> ORT recently released an SPDX analyzer (since ORT 83.0) targeting Yocto 
> 5.0 generated SPDX 3.0.1 documents, which makes this gap more visible: 
> the analyzer can consume the package graph, but the identifiers 
> available are not sufficient to drive post-release CVE monitoring 
> against external vulnerability databases such as NVD or VulnerableCode, 
> since wildcard CPEs cannot be used directly as query keys.
> 
> If I understand correctly, sbom-cve-check faces the same underlying 
> limitation. In our understanding it would benefit from this change too, 
> though the two approaches are complementary rather than overlapping.
> 
> The upstream download URL for tarball-based packages is available at 
> build time and is already derived from SRC_URI via `fetch_data_to_uri()` 
> in `spdx30_tasks.py`. A PURL constructed from that URL and placed 
> directly as an `externalIdentifier` on the install package element would 
> give downstream consumers a durable, canonical identifier for 
> post-release vulnerability monitoring.
> 
> Before drafting a patch I wanted to ask:
> 
> 1. Is there a specific reason PURL is not currently emitted on install 
> package elements — policy, technical constraint, or simply not yet done?
> 2. Would a contribution adding PURL for example as an 
> `externalIdentifier` on install packages (derived from SRC_URI fetch 
> data) be welcome in OE-Core master?
> 
> Happy to hear comments, and discuss scope and approach before writing code.

I'm not sure this is as simple as it first appears. We support the
notion of "premirrors" and "mirrors", which are searched before and
after the primary SRC_URI. We validate a checksum of the resulting
download to verify we did get what we expected but it doesn't always
come from that SRC_URI but can be cached. I guess we assume you use the
unmodified original SRC_URI?

What happens if there are two items in SRC_URI? If we patch the tarball
with other entries in SRC_URI, is the PURL still valid?

What happens in the cases where the recipe uses git to fetch the
sources instead of a tarball?

Can the external tooling not look at the url data already in the SPDX
output and work out the purls itself if it wants to?

I guess what I'm saying is we're trying to avoid too much "processing"
of the data we put into the SPDX so I'm cautious about duplicating
info. If the purl is always derived from the SRC_URI and we include
that, should we be adding the extra data?

I'm not trying to be negative, I'm just worried about where this might
lead and the corner cases that may be involved.

Coping Joshua who I suspect also may have thoughts on this.

Cheers,

Richard






  reply	other threads:[~2026-04-08 21:23 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-04-08 13:19 [RFC] Adding PURL identifiers to SPDX 3.0.1 install package elements Martin von Willebrand
2026-04-08 21:23 ` Richard Purdie [this message]
2026-04-09  8:55   ` [OE-core] " Martin von Willebrand
2026-04-09 13:21     ` Joshua Watt
2026-04-10  7:46       ` Martin von Willebrand

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=f4bf51a0b26fcff35191bcedf8e51c09e27b856d.camel@linuxfoundation.org \
    --to=richard.purdie@linuxfoundation.org \
    --cc=JPEWhacker@gmail.com \
    --cc=martin.vonwillebrand@doubleopen.io \
    --cc=openembedded-core@lists.openembedded.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox