mirror of
https://github.com/anchore/syft.git
synced 2025-11-17 08:23:15 +01:00
fix: support traefik binary from the official Docker image (#2484)
Signed-off-by: Laurent Goderre <laurent.goderre@docker.com>
This commit is contained in:
parent
e61aac0b53
commit
fecfb2f939
@ -133,6 +133,17 @@ func Test_Cataloger_PositiveCases(t *testing.T) {
|
||||
Metadata: metadata("traefik-binary"),
|
||||
},
|
||||
},
|
||||
{
|
||||
logicalFixture: "traefik/2.10.7/linux-amd64",
|
||||
expected: pkg.Package{
|
||||
Name: "traefik",
|
||||
Version: "2.10.7",
|
||||
Type: "binary",
|
||||
PURL: "pkg:generic/traefik@2.10.7",
|
||||
Locations: locations("traefik"),
|
||||
Metadata: metadata("traefik-binary"),
|
||||
},
|
||||
},
|
||||
{
|
||||
logicalFixture: "memcached/1.6.18/linux-amd64",
|
||||
expected: pkg.Package{
|
||||
|
||||
@ -214,7 +214,7 @@ func DefaultClassifiers() []Classifier {
|
||||
EvidenceMatcher: FileContentsVersionMatcher(
|
||||
// [NUL]v1.7.34[NUL]
|
||||
// [NUL]2.9.6[NUL]
|
||||
`(?m)\x00v?(?P<version>[0-9]+\.[0-9]+\.[0-9]+(-alpha[0-9]|-beta[0-9]|-rc[0-9])?)\x00`),
|
||||
`(?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",
|
||||
PURL: mustPURL("pkg:generic/traefik@version"),
|
||||
},
|
||||
|
||||
Binary file not shown.
@ -329,6 +329,13 @@ from-images:
|
||||
paths:
|
||||
- /usr/local/bin/traefik
|
||||
|
||||
- version: 2.10.7
|
||||
images:
|
||||
- ref: traefik:2.10.7@sha256:a98415716a91066ef5e442969887ebb3df7d80775b5bfa7b67fcaed989833d84
|
||||
platform: linux/amd64
|
||||
paths:
|
||||
- /usr/local/bin/traefik
|
||||
|
||||
|
||||
# from the original dynamic fixtures...
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user