Files
lincodex/runner/testdata/hostile/go/mount_proc.go
T

15 lines
273 B
Go

// Escape attempt: mounting a fresh procfs is killed by the seccomp policy.
package main
import (
"fmt"
"os"
"syscall"
)
func main() {
_ = os.MkdirAll("/tmp/proc", 0o700)
err := syscall.Mount("proc", "/tmp/proc", "proc", 0, "")
fmt.Println("mount returned", err)
}