Documentation ¶
Index ¶
- Constants
- func AuthenticateClient(dbProps utils.Map, dataAuth utils.Map) (utils.Map, error)
- func GetBasicAuth(ctx *fiber.Ctx) (string, string, error)
- func ParseScope(dataAuth utils.Map) utils.Map
- func ValidateAuthCredential(dbProps utils.Map, dataAuth utils.Map) (utils.Map, error)
- func ValidateBearerAuth(ctx *fiber.Ctx, claims jwt.Claims) error
- func ValidateInputParams(ctx *fiber.Ctx) (utils.Map, error)
- type Claims
Constants ¶
View Source
const TOKEN_EXPIRY_DAYS = (7 * 24 * time.Hour) // 7 * 24 hours = 168 hours
Variables ¶
This section is empty.
Functions ¶
func AuthenticateClient ¶ added in v1.0.2
func GetBasicAuth ¶
func ValidateAuthCredential ¶
************************************************************************************* ** ** ValidateAuthCredentials: ** ** ** **************************************************************************************
func ValidateBearerAuth ¶
func ValidateBearerAuth(ctx *fiber.Ctx, claims jwt.Claims) error
validateBearerAuth -- Authenticate Application Request
func ValidateInputParams ¶
Types ¶
type Claims ¶
type Claims struct { ClientType string `json:"client_type"` ClientScope string `json:"client_scope"` ClientId string `json:"client_id"` GrandType string `json:"grant_type"` BusinessId string `json:"business_id,omitempty"` UserId string `json:"user_id,omitempty"` TokenString string `json:"token_string,omitempty"` jwt.RegisteredClaims }
func AuthValidate ¶
func GetAuthToken ¶
func GetRefreshToken ¶
func Map2Claims ¶
Click to show internal directories.
Click to hide internal directories.