aboutsummaryrefslogtreecommitdiffhomepage
path: root/helper/bwrap.go
diff options
context:
space:
mode:
authorOphestra <cat@gensokyo.uk>2025-03-15 02:21:59 +0900
committerOphestra <cat@gensokyo.uk>2025-03-15 02:27:40 +0900
commit10a21ce3ef0566194d874b9da9b437971e968133 (patch)
tree486d7a93d4abab4c377db632db169e1543c91ae4 /helper/bwrap.go
parent0f1f0e43643d302494c0dac8bbc3eda7813f06bb (diff)
helper: expose extra files to direct
Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'helper/bwrap.go')
-rw-r--r--helper/bwrap.go12
1 files changed, 3 insertions, 9 deletions
diff --git a/helper/bwrap.go b/helper/bwrap.go
index f94cf7f3..97eacf8e 100644
--- a/helper/bwrap.go
+++ b/helper/bwrap.go
@@ -7,7 +7,6 @@ import (
"os/exec"
"slices"
"strconv"
- "syscall"
"git.gensokyo.uk/security/fortify/helper/bwrap"
"git.gensokyo.uk/security/fortify/helper/proc"
@@ -26,12 +25,11 @@ func MustNewBwrap(
stat bool,
argF func(argsFd, statFd int) []string,
cmdF func(cmd *exec.Cmd),
- conf *bwrap.Config,
- setpgid bool,
extraFiles []*os.File,
+ conf *bwrap.Config,
syncFd *os.File,
) Helper {
- b, err := NewBwrap(ctx, name, wt, stat, argF, cmdF, conf, setpgid, extraFiles, syncFd)
+ b, err := NewBwrap(ctx, name, wt, stat, argF, cmdF, extraFiles, conf, syncFd)
if err != nil {
panic(err.Error())
} else {
@@ -49,15 +47,11 @@ func NewBwrap(
stat bool,
argF func(argsFd, statFd int) []string,
cmdF func(cmd *exec.Cmd),
- conf *bwrap.Config,
- setpgid bool,
extraFiles []*os.File,
+ conf *bwrap.Config,
syncFd *os.File,
) (Helper, error) {
b, args := newHelperCmd(ctx, BubblewrapName, wt, stat, argF, extraFiles)
- if setpgid {
- b.Cmd.SysProcAttr = &syscall.SysProcAttr{Setpgid: true}
- }
var argsFd uintptr
if v, err := NewCheckedArgs(conf.Args(syncFd, b.extraFiles, &b.files)); err != nil {