feat(aa): add the Kind struct to manage aa rules.
This commit is contained in:
parent
1333ec2025
commit
3b0944c615
23 changed files with 239 additions and 223 deletions
|
|
@ -8,10 +8,10 @@ import (
|
|||
"fmt"
|
||||
)
|
||||
|
||||
const tokNETWORK = "network"
|
||||
const NETWORK Kind = "network"
|
||||
|
||||
func init() {
|
||||
requirements[tokNETWORK] = requirement{
|
||||
requirements[NETWORK] = requirement{
|
||||
"access": []string{
|
||||
"create", "bind", "listen", "accept", "connect", "shutdown",
|
||||
"getattr", "setattr", "getopt", "setopt", "send", "receive",
|
||||
|
|
@ -126,6 +126,6 @@ func (r *Network) Constraint() constraint {
|
|||
return blockKind
|
||||
}
|
||||
|
||||
func (r *Network) Kind() string {
|
||||
return tokNETWORK
|
||||
func (r *Network) Kind() Kind {
|
||||
return NETWORK
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue