aboutsummaryrefslogtreecommitdiffstats
path: root/pkg/host/syscalls_linux.go
diff options
context:
space:
mode:
Diffstat (limited to 'pkg/host/syscalls_linux.go')
-rw-r--r--pkg/host/syscalls_linux.go4
1 files changed, 3 insertions, 1 deletions
diff --git a/pkg/host/syscalls_linux.go b/pkg/host/syscalls_linux.go
index 079a4503d..693ec3f3e 100644
--- a/pkg/host/syscalls_linux.go
+++ b/pkg/host/syscalls_linux.go
@@ -168,13 +168,15 @@ func isSupportedSyzkall(sandbox string, c *prog.Syscall) (bool, string) {
case "syz_open_dev":
if _, ok := c.Args[0].(*prog.ConstType); ok {
// This is for syz_open_dev$char/block.
- // They are currently commented out, but in case one enables them.
return true, ""
}
fname, ok := extractStringConst(c.Args[0])
if !ok {
panic("first open arg is not a pointer to string const")
}
+ if !strings.Contains(fname, "#") {
+ panic(fmt.Sprintf("%v does not contain # in the file name (should be openat)", c.Name))
+ }
if checkUSBInjection() == "" {
// These entries might not be available at boot time,
// but will be created by connected USB devices.