mirror of
https://github.com/saltbo/zpan.git
synced 2026-08-28 15:51:29 +08:00
feat: establish unified authorization kernel (#533)
* feat: establish unified authorization kernel Agent-Profile: https://agent-kanban.dev/agents/e0a1ce35687e48ef * docs(v2.9): sync confirmed agent access plan --------- Co-authored-by: Ravi Shah <ravi-shah@mails.agent-kanban.dev> Co-authored-by: saltbo <saltbo@foxmail.com>
This commit is contained in:
committed by
GitHub
parent
ddb87f4901
commit
038e23172b
@@ -1068,16 +1068,23 @@ func (e AdminDashboardDownloadersItemsStatus) Valid() bool {
|
||||
|
||||
// Defines values for AuditEventActorType.
|
||||
const (
|
||||
AuditEventActorTypeAgent AuditEventActorType = "agent"
|
||||
AuditEventActorTypeAgentOauth AuditEventActorType = "agent_oauth"
|
||||
AuditEventActorTypeAnonymous AuditEventActorType = "anonymous"
|
||||
AuditEventActorTypeApiKey AuditEventActorType = "api_key"
|
||||
AuditEventActorTypeDownloader AuditEventActorType = "downloader"
|
||||
AuditEventActorTypeSystem AuditEventActorType = "system"
|
||||
AuditEventActorTypeTaskUpload AuditEventActorType = "task-upload"
|
||||
AuditEventActorTypeUser AuditEventActorType = "user"
|
||||
)
|
||||
|
||||
// Valid indicates whether the value is a known member of the AuditEventActorType enum.
|
||||
func (e AuditEventActorType) Valid() bool {
|
||||
switch e {
|
||||
case AuditEventActorTypeAgent:
|
||||
return true
|
||||
case AuditEventActorTypeAgentOauth:
|
||||
return true
|
||||
case AuditEventActorTypeAnonymous:
|
||||
return true
|
||||
case AuditEventActorTypeApiKey:
|
||||
@@ -1086,6 +1093,8 @@ func (e AuditEventActorType) Valid() bool {
|
||||
return true
|
||||
case AuditEventActorTypeSystem:
|
||||
return true
|
||||
case AuditEventActorTypeTaskUpload:
|
||||
return true
|
||||
case AuditEventActorTypeUser:
|
||||
return true
|
||||
default:
|
||||
|
||||
Reference in New Issue
Block a user