|
@@ -88,6 +88,17 @@ func DefaultProfile(rs *specs.Spec) *types.Seccomp {
|
|
Action: types.ActAllow,
|
|
Action: types.ActAllow,
|
|
Args: []*types.Arg{},
|
|
Args: []*types.Arg{},
|
|
},
|
|
},
|
|
|
|
+ {
|
|
|
|
+ Name: "chown",
|
|
|
|
+ Action: types.ActAllow,
|
|
|
|
+ Args: []*types.Arg{},
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ Name: "chown32",
|
|
|
|
+ Action: types.ActAllow,
|
|
|
|
+ Args: []*types.Arg{},
|
|
|
|
+ },
|
|
|
|
+
|
|
{
|
|
{
|
|
Name: "clock_getres",
|
|
Name: "clock_getres",
|
|
Action: types.ActAllow,
|
|
Action: types.ActAllow,
|
|
@@ -243,6 +254,21 @@ func DefaultProfile(rs *specs.Spec) *types.Seccomp {
|
|
Action: types.ActAllow,
|
|
Action: types.ActAllow,
|
|
Args: []*types.Arg{},
|
|
Args: []*types.Arg{},
|
|
},
|
|
},
|
|
|
|
+ {
|
|
|
|
+ Name: "fchown",
|
|
|
|
+ Action: types.ActAllow,
|
|
|
|
+ Args: []*types.Arg{},
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ Name: "fchown32",
|
|
|
|
+ Action: types.ActAllow,
|
|
|
|
+ Args: []*types.Arg{},
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ Name: "fchownat",
|
|
|
|
+ Action: types.ActAllow,
|
|
|
|
+ Args: []*types.Arg{},
|
|
|
|
+ },
|
|
{
|
|
{
|
|
Name: "fcntl",
|
|
Name: "fcntl",
|
|
Action: types.ActAllow,
|
|
Action: types.ActAllow,
|
|
@@ -588,6 +614,16 @@ func DefaultProfile(rs *specs.Spec) *types.Seccomp {
|
|
Action: types.ActAllow,
|
|
Action: types.ActAllow,
|
|
Args: []*types.Arg{},
|
|
Args: []*types.Arg{},
|
|
},
|
|
},
|
|
|
|
+ {
|
|
|
|
+ Name: "lchown",
|
|
|
|
+ Action: types.ActAllow,
|
|
|
|
+ Args: []*types.Arg{},
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ Name: "lchown32",
|
|
|
|
+ Action: types.ActAllow,
|
|
|
|
+ Args: []*types.Arg{},
|
|
|
|
+ },
|
|
{
|
|
{
|
|
Name: "lgetxattr",
|
|
Name: "lgetxattr",
|
|
Action: types.ActAllow,
|
|
Action: types.ActAllow,
|
|
@@ -1591,44 +1627,6 @@ func DefaultProfile(rs *specs.Spec) *types.Seccomp {
|
|
var cap string
|
|
var cap string
|
|
for _, cap = range rs.Process.Capabilities {
|
|
for _, cap = range rs.Process.Capabilities {
|
|
switch cap {
|
|
switch cap {
|
|
- case "CAP_CHOWN":
|
|
|
|
- syscalls = append(syscalls, []*types.Syscall{
|
|
|
|
- {
|
|
|
|
- Name: "chown",
|
|
|
|
- Action: types.ActAllow,
|
|
|
|
- Args: []*types.Arg{},
|
|
|
|
- },
|
|
|
|
- {
|
|
|
|
- Name: "chown32",
|
|
|
|
- Action: types.ActAllow,
|
|
|
|
- Args: []*types.Arg{},
|
|
|
|
- },
|
|
|
|
- {
|
|
|
|
- Name: "fchown",
|
|
|
|
- Action: types.ActAllow,
|
|
|
|
- Args: []*types.Arg{},
|
|
|
|
- },
|
|
|
|
- {
|
|
|
|
- Name: "fchown32",
|
|
|
|
- Action: types.ActAllow,
|
|
|
|
- Args: []*types.Arg{},
|
|
|
|
- },
|
|
|
|
- {
|
|
|
|
- Name: "fchownat",
|
|
|
|
- Action: types.ActAllow,
|
|
|
|
- Args: []*types.Arg{},
|
|
|
|
- },
|
|
|
|
- {
|
|
|
|
- Name: "lchown",
|
|
|
|
- Action: types.ActAllow,
|
|
|
|
- Args: []*types.Arg{},
|
|
|
|
- },
|
|
|
|
- {
|
|
|
|
- Name: "lchown32",
|
|
|
|
- Action: types.ActAllow,
|
|
|
|
- Args: []*types.Arg{},
|
|
|
|
- },
|
|
|
|
- }...)
|
|
|
|
case "CAP_DAC_READ_SEARCH":
|
|
case "CAP_DAC_READ_SEARCH":
|
|
syscalls = append(syscalls, []*types.Syscall{
|
|
syscalls = append(syscalls, []*types.Syscall{
|
|
{
|
|
{
|
|
@@ -1853,17 +1851,6 @@ func DefaultProfile(rs *specs.Spec) *types.Seccomp {
|
|
}...)
|
|
}...)
|
|
}
|
|
}
|
|
|
|
|
|
- // We need some additional syscalls in this case see #22252
|
|
|
|
- if !rs.Process.NoNewPrivileges {
|
|
|
|
- syscalls = append(syscalls, []*types.Syscall{
|
|
|
|
- {
|
|
|
|
- Name: "fchown",
|
|
|
|
- Action: types.ActAllow,
|
|
|
|
- Args: []*types.Arg{},
|
|
|
|
- },
|
|
|
|
- }...)
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
return &types.Seccomp{
|
|
return &types.Seccomp{
|
|
DefaultAction: types.ActErrno,
|
|
DefaultAction: types.ActErrno,
|
|
Architectures: arches(),
|
|
Architectures: arches(),
|