- Sort Score
- Result 10 results
- Languages All
Results 1 - 3 of 3 for MapClaims (0.07 sec)
-
internal/jwt/parser.go
// NewMapClaims - Initializes a new map claims func NewMapClaims() *MapClaims { return &MapClaims{MapClaims: jwtgo.MapClaims{}} } // Set Adds new arbitrary claim keys and values. func (c *MapClaims) Set(key string, val interface{}) { if c == nil { return } c.MapClaims[key] = val } // Delete deletes a key named key. func (c *MapClaims) Delete(key string) { if c == nil { return }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Tue Sep 17 16:45:46 UTC 2024 - 14.1K bytes - Viewed (0) -
internal/auth/credentials.go
m["accessKey"] = accessKey jwt := jwtgo.NewWithClaims(jwtgo.SigningMethodHS512, jwtgo.MapClaims(m)) return jwt.SignedString([]byte(tokenSecret)) } // ExtractClaims extracts JWT claims from a security token using a secret key func ExtractClaims(token, secretKey string) (*jwt.MapClaims, error) { if token == "" || secretKey == "" { return nil, errors.New("invalid argument") }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Tue May 28 17:14:16 UTC 2024 - 12K bytes - Viewed (0) -
cmd/auth-handler.go
func mustGetClaimsFromToken(r *http.Request) map[string]interface{} { claims, _ := getClaimsFromToken(getSessionToken(r)) return claims } func getClaimsFromTokenWithSecret(token, secret string) (*xjwt.MapClaims, error) { // JWT token for x-amz-security-token is signed with admin // secret key, temporary credentials become invalid if // server admin credentials change. This is done to ensure
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Tue Sep 17 16:45:46 UTC 2024 - 26.1K bytes - Viewed (0)