github.com/nicocha30/gvisor-ligolo@v0.0.0-20230726075806-989fa2c0a413/pkg/sentry/strace/clone.go (about)

     1  // Copyright 2018 The gVisor Authors.
     2  //
     3  // Licensed under the Apache License, Version 2.0 (the "License");
     4  // you may not use this file except in compliance with the License.
     5  // You may obtain a copy of the License at
     6  //
     7  //     http://www.apache.org/licenses/LICENSE-2.0
     8  //
     9  // Unless required by applicable law or agreed to in writing, software
    10  // distributed under the License is distributed on an "AS IS" BASIS,
    11  // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    12  // See the License for the specific language governing permissions and
    13  // limitations under the License.
    14  
    15  package strace
    16  
    17  import (
    18  	"github.com/nicocha30/gvisor-ligolo/pkg/abi"
    19  	"github.com/nicocha30/gvisor-ligolo/pkg/abi/linux"
    20  )
    21  
    22  // CloneFlagSet is the set of clone(2) flags.
    23  var CloneFlagSet = abi.FlagSet{
    24  	{
    25  		Flag: linux.CLONE_VM,
    26  		Name: "CLONE_VM",
    27  	},
    28  	{
    29  		Flag: linux.CLONE_FS,
    30  		Name: "CLONE_FS",
    31  	},
    32  	{
    33  		Flag: linux.CLONE_FILES,
    34  		Name: "CLONE_FILES",
    35  	},
    36  	{
    37  		Flag: linux.CLONE_SIGHAND,
    38  		Name: "CLONE_SIGHAND",
    39  	},
    40  	{
    41  		Flag: linux.CLONE_PTRACE,
    42  		Name: "CLONE_PTRACE",
    43  	},
    44  	{
    45  		Flag: linux.CLONE_VFORK,
    46  		Name: "CLONE_VFORK",
    47  	},
    48  	{
    49  		Flag: linux.CLONE_PARENT,
    50  		Name: "CLONE_PARENT",
    51  	},
    52  	{
    53  		Flag: linux.CLONE_THREAD,
    54  		Name: "CLONE_THREAD",
    55  	},
    56  	{
    57  		Flag: linux.CLONE_NEWNS,
    58  		Name: "CLONE_NEWNS",
    59  	},
    60  	{
    61  		Flag: linux.CLONE_SYSVSEM,
    62  		Name: "CLONE_SYSVSEM",
    63  	},
    64  	{
    65  		Flag: linux.CLONE_SETTLS,
    66  		Name: "CLONE_SETTLS",
    67  	},
    68  	{
    69  		Flag: linux.CLONE_PARENT_SETTID,
    70  		Name: "CLONE_PARENT_SETTID",
    71  	},
    72  	{
    73  		Flag: linux.CLONE_CHILD_CLEARTID,
    74  		Name: "CLONE_CHILD_CLEARTID",
    75  	},
    76  	{
    77  		Flag: linux.CLONE_DETACHED,
    78  		Name: "CLONE_DETACHED",
    79  	},
    80  	{
    81  		Flag: linux.CLONE_UNTRACED,
    82  		Name: "CLONE_UNTRACED",
    83  	},
    84  	{
    85  		Flag: linux.CLONE_CHILD_SETTID,
    86  		Name: "CLONE_CHILD_SETTID",
    87  	},
    88  	{
    89  		Flag: linux.CLONE_NEWUTS,
    90  		Name: "CLONE_NEWUTS",
    91  	},
    92  	{
    93  		Flag: linux.CLONE_NEWIPC,
    94  		Name: "CLONE_NEWIPC",
    95  	},
    96  	{
    97  		Flag: linux.CLONE_NEWUSER,
    98  		Name: "CLONE_NEWUSER",
    99  	},
   100  	{
   101  		Flag: linux.CLONE_NEWPID,
   102  		Name: "CLONE_NEWPID",
   103  	},
   104  	{
   105  		Flag: linux.CLONE_NEWNET,
   106  		Name: "CLONE_NEWNET",
   107  	},
   108  	{
   109  		Flag: linux.CLONE_IO,
   110  		Name: "CLONE_IO",
   111  	},
   112  }