Compare commits
2 Commits
2cf3077c07
...
c9eeafbbf0
Author | SHA1 | Date | |
---|---|---|---|
c9eeafbbf0 | |||
2f1d42c8dd |
@ -7,7 +7,6 @@ import (
|
||||
"errors"
|
||||
"fmt"
|
||||
"io"
|
||||
"log"
|
||||
"os"
|
||||
"os/exec"
|
||||
"runtime"
|
||||
@ -15,7 +14,6 @@ import (
|
||||
. "syscall"
|
||||
"time"
|
||||
|
||||
"hakurei.app/container/landlock"
|
||||
"hakurei.app/container/seccomp"
|
||||
)
|
||||
|
||||
@ -94,8 +92,6 @@ type (
|
||||
RetainSession bool
|
||||
// Do not [syscall.CLONE_NEWNET].
|
||||
HostNet bool
|
||||
// Scope abstract UNIX domain sockets using LANDLOCK_SCOPE_ABSTRACT_UNIX_SOCKET.
|
||||
ScopeAbstract bool
|
||||
// Retain CAP_SYS_ADMIN.
|
||||
Privileged bool
|
||||
}
|
||||
@ -189,12 +185,6 @@ func (p *Container) Start() error {
|
||||
"prctl(PR_SET_NO_NEW_PRIVS):")
|
||||
}
|
||||
|
||||
if p.ScopeAbstract {
|
||||
if err := landlock.ScopeAbstract(); err != nil {
|
||||
log.Fatalf("could not scope abstract unix sockets: %v", err)
|
||||
}
|
||||
}
|
||||
|
||||
msg.Verbose("starting container init")
|
||||
if err := p.cmd.Start(); err != nil {
|
||||
return msg.WrapErr(err, err.Error())
|
||||
|
Loading…
x
Reference in New Issue
Block a user