Documentation ¶
Index ¶
Constants ¶
View Source
const ( RuleSetUnknown = "unknown" RuleSetRoot = "root" RuleSetAdmin = "admin" RuleSetGuest = "guest" )
View Source
const ( UnknownRole = "Unknown" RootRole = "root" GuestRole = "guest" AdminRole = "admin" )
Variables ¶
View Source
var ( ErrNotFound = errors.New("not found") ErrSessionTimedOut = errors.New("session timed out") ErrNotAllowed = errors.New("not allowed") )
Errors
Functions ¶
This section is empty.
Types ¶
type Certificate ¶
type DatabaseConfig ¶
type HttpServerConfig ¶
type Identity ¶
type Identity struct { Metadata `gorm:"embedded;embeddedPrefix:metadata_"` Password Password `gorm:"embedded"` Certificates []Certificate `gorm:"many2many:identity_certificates;"` Roles []Role `gorm:"many2many:identity_roles;"` }
type Namespace ¶
type Namespace struct { // The namespace field of Metadata will be empty Metadata `gorm:"embedded;embeddedPrefix:metadata_"` }
type RootConfig ¶
type Rule ¶
type Rule struct { Metadata `gorm:"embedded;embeddedPrefix:metadata_"` Namespace string Name string ObjectType string Operation string Instances []Metadata `gorm:"many2many:Rule_instances;"` }
A Rule is needed to permit something. Default everything is denied
func (*Rule) AsPermissive ¶
AsPermissive assert this rule is as permissive as the other rule The other rule can be less permissive, but not more permissive.
type SOIDConfig ¶
type SOIDConfig struct { Metadata `gorm:"embedded;embeddedPrefix:metadata_"` SoidNamespace string `yaml:"soid_namespace"` SystemAdminUserPassword string `yaml:"system_admin_password"` Root RootConfig Database DatabaseConfig `yaml:"database"` HTTPServer HttpServerConfig `yaml:"http_server"` }
Click to show internal directories.
Click to hide internal directories.