Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type AllowReason ¶
type AllowedByAnyone ¶
type AllowedByAnyone struct{}
func NewAllowedByAnyone ¶
func NewAllowedByAnyone() AllowedByAnyone
func (AllowedByAnyone) GetReasonType ¶
func (a AllowedByAnyone) GetReasonType() string
func (AllowedByAnyone) ImplementsAllowReason ¶
func (a AllowedByAnyone) ImplementsAllowReason()
func (AllowedByAnyone) IsServiceUserReason ¶
func (a AllowedByAnyone) IsServiceUserReason() bool
func (AllowedByAnyone) String ¶
func (a AllowedByAnyone) String() string
type AllowedByOwnership ¶
type AllowedByOwnership struct{}
func NewAllowedByOwnership ¶
func NewAllowedByOwnership() AllowedByOwnership
func (AllowedByOwnership) GetReasonType ¶
func (a AllowedByOwnership) GetReasonType() string
func (AllowedByOwnership) ImplementsAllowReason ¶
func (a AllowedByOwnership) ImplementsAllowReason()
func (AllowedByOwnership) IsServiceUserReason ¶
func (a AllowedByOwnership) IsServiceUserReason() bool
func (AllowedByOwnership) String ¶
func (a AllowedByOwnership) String() string
type AllowedByPermission ¶
type AllowedByPermission struct {
Permission permissions.Permission
SourceRoles []roles.Role
}
func NewAllowedByPermission ¶
func NewAllowedByPermission(permission permissions.Permission, sourceRoles []roles.Role) AllowedByPermission
func (AllowedByPermission) GetReasonType ¶
func (a AllowedByPermission) GetReasonType() string
func (AllowedByPermission) ImplementsAllowReason ¶
func (a AllowedByPermission) ImplementsAllowReason()
func (AllowedByPermission) IsServiceUserReason ¶
func (a AllowedByPermission) IsServiceUserReason() bool
func (AllowedByPermission) String ¶
func (a AllowedByPermission) String() string
type AuditLogger ¶
type PolicyResult ¶
type PolicyResult struct {
// contains filtered or unexported fields
}
func Allowed ¶
func Allowed(userId uuid.UUID, virtualServerId uuid.UUID, reason AllowReason) PolicyResult
func PermissionBasedPolicy ¶
func PermissionBasedPolicy(ctx context.Context, permission permissions.Permission) (PolicyResult, error)
func (PolicyResult) IsAllowed ¶
func (p PolicyResult) IsAllowed() bool
func (PolicyResult) Reason ¶
func (p PolicyResult) Reason() AllowReason
func (PolicyResult) UserId ¶
func (p PolicyResult) UserId() uuid.UUID
func (PolicyResult) VirtualServerId ¶
func (p PolicyResult) VirtualServerId() uuid.UUID
Click to show internal directories.
Click to hide internal directories.