implement auth and a simple admin-follows whitelist
Some checks failed
Go / build (push) Has been cancelled
Some checks failed
Go / build (push) Has been cancelled
This commit is contained in:
26
pkg/acl/none.go
Normal file
26
pkg/acl/none.go
Normal file
@@ -0,0 +1,26 @@
|
||||
package acl
|
||||
|
||||
import (
|
||||
"lol.mleku.dev/log"
|
||||
)
|
||||
|
||||
type None struct{}
|
||||
|
||||
func (n None) Configure(cfg ...any) (err error) { return }
|
||||
|
||||
func (n None) GetAccessLevel(pub []byte) (level string) {
|
||||
return "write"
|
||||
}
|
||||
|
||||
func (n None) GetACLInfo() (name, description, documentation string) {
|
||||
return "none", "no ACL", "blanket write access for all clients"
|
||||
}
|
||||
|
||||
func (n None) Type() string {
|
||||
return "none"
|
||||
}
|
||||
|
||||
func init() {
|
||||
log.T.F("registering none ACL")
|
||||
Registry.Register(new(None))
|
||||
}
|
||||
Reference in New Issue
Block a user