Documentation ¶
Overview ¶
Package ecs provides functions to read, write and manipulate ECS files containing a mGuard configuration.
Index ¶
Constants ¶
View Source
const DefaultPassFileContent = `root\n`
DefaultPassFileContent contains the default content of the 'aca/pass' file of an ECS container.
View Source
const DefaultSnmpdFileContent = `createUser "admin" MD5 "SnmpAdmin" DES "SnmpAdmin"\n`
DefaultSnmpdFileContent contains the default content of the 'aca/snmpd' file of an ECS container.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Container ¶
type Container struct { Atv *atv.File Users *shadow.File // contains filtered or unexported fields }
Container represents a mGuard ECS container.
func ContainerFromATV ¶
ContainerFromATV wraps an ATV document in an ECS container.
func ContainerFromFile ¶
ContainerFromFile reads the specified ECS container from disk.
func ContainerFromReader ¶
ContainerFromReader reads an ECS container from the specified io.Reader.
func NewContainer ¶
func NewContainer() *Container
NewContainer returns a new and empty ECS container.
Click to show internal directories.
Click to hide internal directories.