MSP-7470 Init user auth
This commit is contained in:
1 parent
b67eb8137c
commit
eb6326c343
35 files changed
+1059
-142
No files matched your search
@@ -0,0 +1,7 @@
|
||||
package entity
|
||||
|
||||
type AdminAuthenticateResponse struct {
|
||||
Authenticated bool
|
||||
ErrorReason string
|
||||
AdminId int
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
package entity
|
||||
|
||||
type AppAuthData struct {
|
||||
AppName string
|
||||
SystemId int
|
||||
DomainId int
|
||||
ServiceId int
|
||||
ApplicationId int
|
||||
}
|
||||
@@ -0,0 +1,30 @@
|
||||
package entity
|
||||
|
||||
type AuthenticateRequest struct {
|
||||
Token string
|
||||
}
|
||||
|
||||
type AuthenticateResponse struct {
|
||||
Authenticated bool
|
||||
ErrorReason string
|
||||
AuthData *AppAuthData
|
||||
}
|
||||
|
||||
type AuthorizeRequest struct {
|
||||
ApplicationId int
|
||||
HttpMethod string
|
||||
Endpoint string
|
||||
}
|
||||
|
||||
type AuthorizeResponse struct {
|
||||
Authorized bool
|
||||
}
|
||||
|
||||
type AdminAuthorizeRequest struct {
|
||||
AdminId int
|
||||
Permission string
|
||||
}
|
||||
|
||||
type AdminAuthorizeResponse struct {
|
||||
Authorized bool
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
package entity
|
||||
|
||||
type UserAuthenticateRequest struct {
|
||||
Token string
|
||||
}
|
||||
|
||||
type UserAuthenticateResponse struct {
|
||||
Authenticated bool
|
||||
ErrorReason string
|
||||
AuthData *UserAuthData
|
||||
}
|
||||
|
||||
type UserAuthData struct {
|
||||
Identity string
|
||||
IdentityHeader string
|
||||
ExtraHeaders map[string][]string
|
||||
}
|
||||
Reference in new issue
Block a user