forked from security/hakurei
helper/bwrap: move sync to helper state
Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
@@ -1,9 +1,5 @@
|
||||
package bwrap
|
||||
|
||||
import (
|
||||
"os"
|
||||
)
|
||||
|
||||
type Config struct {
|
||||
// unshare every namespace we support by default if nil
|
||||
// (--unshare-all)
|
||||
@@ -61,10 +57,6 @@ type Config struct {
|
||||
// (--as-pid-1)
|
||||
AsInit bool `json:"as_init"`
|
||||
|
||||
// keep this fd open while sandbox is running
|
||||
// (--sync-fd FD)
|
||||
sync *os.File
|
||||
|
||||
/* unmapped options include:
|
||||
--unshare-user-try Create new user namespace if possible else continue by skipping it
|
||||
--unshare-cgroup-try Create new cgroup namespace if possible else continue by skipping it
|
||||
@@ -90,12 +82,6 @@ type Config struct {
|
||||
among which --args is used internally for passing arguments */
|
||||
}
|
||||
|
||||
// Sync keep this fd open while sandbox is running
|
||||
// (--sync-fd FD)
|
||||
func (c *Config) Sync() *os.File {
|
||||
return c.sync
|
||||
}
|
||||
|
||||
type UnshareConfig struct {
|
||||
// (--unshare-user)
|
||||
// create new user namespace
|
||||
|
||||
Reference in New Issue
Block a user