mirror of
https://github.com/anchore/syft.git
synced 2025-11-17 16:33:21 +01:00
fix: traefik classifier (#3077)
Signed-off-by: witchcraze <witchcraze@gmail.com>
This commit is contained in:
parent
1cd75b7d68
commit
490e05adb2
@ -204,6 +204,17 @@ func Test_Cataloger_PositiveCases(t *testing.T) {
|
|||||||
Metadata: metadata("traefik-binary"),
|
Metadata: metadata("traefik-binary"),
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
logicalFixture: "traefik/3.0.4/linux-riscv64",
|
||||||
|
expected: pkg.Package{
|
||||||
|
Name: "traefik",
|
||||||
|
Version: "3.0.4",
|
||||||
|
Type: "binary",
|
||||||
|
PURL: "pkg:generic/traefik@3.0.4",
|
||||||
|
Locations: locations("traefik"),
|
||||||
|
Metadata: metadata("traefik-binary"),
|
||||||
|
},
|
||||||
|
},
|
||||||
{
|
{
|
||||||
logicalFixture: "memcached/1.6.18/linux-amd64",
|
logicalFixture: "memcached/1.6.18/linux-amd64",
|
||||||
expected: pkg.Package{
|
expected: pkg.Package{
|
||||||
|
|||||||
@ -263,7 +263,8 @@ func DefaultClassifiers() []Classifier {
|
|||||||
EvidenceMatcher: FileContentsVersionMatcher(
|
EvidenceMatcher: FileContentsVersionMatcher(
|
||||||
// [NUL]v1.7.34[NUL]
|
// [NUL]v1.7.34[NUL]
|
||||||
// [NUL]2.9.6[NUL]
|
// [NUL]2.9.6[NUL]
|
||||||
`(?m)(\x00|\x{FFFD})v?(?P<version>[0-9]+\.[0-9]+\.[0-9]+(-alpha[0-9]|-beta[0-9]|-rc[0-9])?)\x00`),
|
// 3.0.4[NUL]
|
||||||
|
`(?m)(\x00|\x{FFFD})?v?(?P<version>[0-9]+\.[0-9]+\.[0-9]+(-alpha[0-9]|-beta[0-9]|-rc[0-9])?)\x00`),
|
||||||
Package: "traefik",
|
Package: "traefik",
|
||||||
PURL: mustPURL("pkg:generic/traefik@version"),
|
PURL: mustPURL("pkg:generic/traefik@version"),
|
||||||
CPEs: singleCPE("cpe:2.3:a:traefik:traefik:*:*:*:*:*:*:*:*"),
|
CPEs: singleCPE("cpe:2.3:a:traefik:traefik:*:*:*:*:*:*:*:*"),
|
||||||
|
|||||||
@ -448,6 +448,12 @@ from-images:
|
|||||||
paths:
|
paths:
|
||||||
- /usr/local/bin/traefik
|
- /usr/local/bin/traefik
|
||||||
|
|
||||||
|
- version: 3.0.4
|
||||||
|
images:
|
||||||
|
- ref: traefik:3.0.4@sha256:12a7cc4232b5b7fe027673da8c096144525f59a8eabc87e52260aac0ec5a1219
|
||||||
|
platform: linux/riscv64
|
||||||
|
paths:
|
||||||
|
- /usr/local/bin/traefik
|
||||||
|
|
||||||
# from the original dynamic fixtures...
|
# from the original dynamic fixtures...
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user