-
Couldn't load subscription status.
- Fork 727
Description
What happened:
Given a desire to scan a host
When it reaches a symlink that point to a character special device that would block on read
It hangs
What you expected to happen:
Given a desire to scan a host
When it reaches a symlink that point to a character special device (OR a socket) [that could block on read]
It should skip it as unreadable and continue to completion.
How to reproduce it (as minimally and precisely as possible):
On a machine with a sound driver (I couldn't think of other characters that would be likely to block on read for a CI/CD environment).
syft packages dir:/run/
Hangs when Indexing file:/run/udev/static_node-tags/uaccess/snd\x2fseq
/run/udev/static_node-tags/uaccess/snd\x2fseq is a symlink to /dev/snd/seq, which is a character device
strace shows syft doing the following
It would appear that syft is correctly detecting the symlink, but then not doing the check (that it would normally do if I run syft against file:/dev/snd/seq) in detecting it as character special device.
Anything else we need to know?:
Environment:
- Output of
syft version: Version 0.32.0
Downloaded today from GitHub release using install.sh script from this repository.
- OS (e.g:
cat /etc/os-releaseor similar):
Red Hat Enterprise Linux release 8.4 (Ootpa) --- running as a graphical workstation with sound capability.