protect/protect_openbsd.go

20 lines
289 B
Go
Raw Normal View History

2020-05-08 07:36:29 -06:00
//+build openbsd
package protect
import (
"golang.org/x/sys/unix"
)
2020-05-10 07:04:34 -06:00
func unveil(path string, flags string) error {
return unix.Unveil(path, flags)
2020-05-08 07:36:29 -06:00
}
2020-05-08 07:55:32 -06:00
func unveilBlock() error {
2020-05-08 07:38:58 -06:00
return unix.UnveilBlock()
2020-05-08 07:36:29 -06:00
}
2020-05-10 07:04:34 -06:00
func pledge(promises string) error {
return unix.PledgePromises(promises)
2020-05-08 07:36:29 -06:00
}