cfg

package
v0.0.0-...-c3de88e Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 4, 2024 License: GPL-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// Root is the root directory for the build
	Root *paths.Path = paths.New(".build")

	// RootApparmord is the final built apparmor.d directory
	RootApparmord *paths.Path = Root.Join("apparmor.d")

	// DistDir is the directory where the distribution specific files are stored
	DistDir *paths.Path = paths.New("dists")

	// FlagDir is the directory where the flags are stored
	FlagDir *paths.Path = DistDir.Join("flags")

	// IgnoreDir is the directory where the ignore files are stored
	IgnoreDir *paths.Path = DistDir.Join("ignore")

	// SystemdDir is the directory where the systemd drop-in files are stored
	SystemdDir *paths.Path = paths.New("systemd")

	// DebianDir is the directory where the debian specific files are stored
	DebianDir *paths.Path = paths.New("debian")

	// AppArmor 4.0 contains several profiles that allow userns and are otherwise
	// unconfined. Overwriter disables upstream profile in favor of (better) apparmor.d
	// counterpart
	Overwrite Overwriter = false

	// DebianHide is the path to the debian/apparmor.d.hide file
	DebianHide = DebianHider{/* contains filtered or unexported fields */}

	Ignore = Ignorer{}
	Flags  = Flagger{}
)
View Source
var (
	Distribution = getDistribution()
	Release      = getOSRelease()
	Family       = getFamily()
)
View Source
var Hide = `` /* 195-byte string literal not displayed */

Default content of debian/apparmor.d.hide. Whonix has special addition.

Functions

func Help

func Help[T BaseInterface](name string, tasks map[string]T) string

func Usage

func Usage[T BaseInterface](name string, tasks map[string]T) string

Types

type Base

type Base struct {
	Msg     string
	Keyword string
	Help    string
}

func (Base) Message

func (b Base) Message() string

func (Base) Name

func (b Base) Name() string

func (Base) Usage

func (b Base) Usage() string

type BaseInterface

type BaseInterface interface {
	Message() string
	Name() string
	Usage() string
}

type DebianHider

type DebianHider struct {
	// contains filtered or unexported fields
}

func (DebianHider) Init

func (d DebianHider) Init() error

Initialize the file with content from Hide

type Flagger

type Flagger struct{}

func (Flagger) Read

func (f Flagger) Read(name string) map[string][]string

type Ignorer

type Ignorer struct{}

func (Ignorer) Read

func (i Ignorer) Read(name string) []string

type Overwriter

type Overwriter bool

func (Overwriter) Apply

func (o Overwriter) Apply() error

Overwrite upstream profile: disable upstream & rename ours

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL