anchore / anchore/syft

Add magic number classification in the FileMetadata cataloger/indexer

Open
#336 2 comments 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
Go
Stars
9.6k
Forks
954
Avg merge
23h 27m
Merged PRs (30d)
48

Description

Today we report the file type as described from the tar header for each file in the image. We do not classify beyond a "regular file" what is may be. It would be interesting to also include MIME type classification (or similar) based on the magic number for scanned payloads. Most magic numbers can be found well within the first sector of reading, so the entire contents do not need to be scanned.

Contributor guide

Open the contributing guide

Research direction

Start at the FileMetadata cataloger/indexer and review how file types are currently taken from tar headers. Define the magic-number and MIME classification scope, including the bounded read needed for scanned payloads. Done means regular files can receive a useful classification without scanning their entire contents.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
tooling
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.