From 58dc43de862cd0d7d624a7e625f80018b0c1aac7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Prpi=C4=8D?= Date: Tue, 28 Jan 2025 12:56:55 -0500 Subject: [PATCH] fix: update namespace value for OpenSUSE distros (#3615) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Instead of namespacing them to the specific distro version, such as Leap or Tumbleweed, the namespace value is set to the vendor itself: "opensuse". Resolves #3534 Signed-off-by: Martin Prpič --- syft/pkg/cataloger/redhat/package.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/syft/pkg/cataloger/redhat/package.go b/syft/pkg/cataloger/redhat/package.go index 8bbcfe9a0..66c5f6053 100644 --- a/syft/pkg/cataloger/redhat/package.go +++ b/syft/pkg/cataloger/redhat/package.go @@ -92,6 +92,9 @@ func packageURL(name, arch string, epoch *int, srpm string, version, release str if namespace == "rhel" { namespace = "redhat" } + if strings.HasPrefix(namespace, "opensuse") { + namespace = "opensuse" + } qualifiers := map[string]string{}