Documentation ¶
Index ¶
- Constants
- func Commands() []internal.Command
- func GetPasswordType(password string) string
- func RemoveDuplicateEntries(entries []string, allAlias string) (res []string)
- type ACL
- func (acl *ACL) AuthenticateConnection(_ context.Context, conn *net.Conn, cmd []string) error
- func (acl *ACL) AuthorizeConnection(conn *net.Conn, cmd []string, command internal.Command, ...) error
- func (acl *ACL) CompileGlobs()
- func (acl *ACL) DeleteUser(_ context.Context, usernames []string) error
- func (acl *ACL) LockUsers()
- func (acl *ACL) RLockUsers()
- func (acl *ACL) RUnlockUsers()
- func (acl *ACL) RegisterConnection(conn *net.Conn)
- func (acl *ACL) SetUser(cmd []string) error
- func (acl *ACL) UnlockUsers()
- type Connection
- type Password
- type User
Constants ¶
View Source
const ( PasswordPlainText = "plaintext" PasswordSHA256 = "SHA256" )
Variables ¶
This section is empty.
Functions ¶
func GetPasswordType ¶
func RemoveDuplicateEntries ¶
Types ¶
type ACL ¶
type ACL struct { Users []*User // List of ACL user profiles UsersMutex sync.RWMutex // RWMutex for concurrency control when accessing ACL profile list Connections map[*net.Conn]Connection // Connections to the echovault that are currently registered with the ACL module Config config.Config // SugarDB configuration that contains the relevant ACL config options GlobPatterns map[string]glob.Glob }
func (*ACL) AuthenticateConnection ¶
func (*ACL) AuthorizeConnection ¶
func (*ACL) CompileGlobs ¶
func (acl *ACL) CompileGlobs()
func (*ACL) RLockUsers ¶
func (acl *ACL) RLockUsers()
func (*ACL) RUnlockUsers ¶
func (acl *ACL) RUnlockUsers()
func (*ACL) RegisterConnection ¶
func (*ACL) UnlockUsers ¶
func (acl *ACL) UnlockUsers()
type Connection ¶
type User ¶
type User struct { Username string `json:"Username" yaml:"Username"` Enabled bool `json:"Enabled" yaml:"Enabled"` NoPassword bool `json:"NoPassword" yaml:"NoPassword"` NoKeys bool `json:"NoKeys" yaml:"NoKeys"` Passwords []Password `json:"Passwords" yaml:"Passwords"` IncludedCategories []string `json:"IncludedCategories" yaml:"IncludedCategories"` ExcludedCategories []string `json:"ExcludedCategories" yaml:"ExcludedCategories"` IncludedCommands []string `json:"IncludedCommands" yaml:"IncludedCommands"` ExcludedCommands []string `json:"ExcludedCommands" yaml:"ExcludedCommands"` IncludedReadKeys []string `json:"IncludedReadKeys" yaml:"IncludedReadKeys"` IncludedWriteKeys []string `json:"IncludedWriteKeys" yaml:"IncludedWriteKeys"` IncludedPubSubChannels []string `json:"IncludedPubSubChannels" yaml:"IncludedPubSubChannels"` ExcludedPubSubChannels []string `json:"ExcludedPubSubChannels" yaml:"ExcludedPubSubChannels"` }
func CreateUser ¶
func (*User) UpdateUser ¶
Click to show internal directories.
Click to hide internal directories.