Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for ExtractToken (0.15 sec)

  1. cmd/jwt.go

    // Returns errAuthentication for all other errors.
    func metricsRequestAuthenticate(req *http.Request) (*xjwt.MapClaims, []string, bool, error) {
    	token, err := jwtreq.AuthorizationHeaderExtractor.ExtractToken(req)
    	if err != nil {
    		if err == jwtreq.ErrNoTokenInRequest {
    			return nil, nil, false, errNoAuthToken
    		}
    		return nil, nil, false, err
    	}
    	claims := xjwt.NewMapClaims()
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Mon Jul 22 07:04:48 UTC 2024
    - 4.5K bytes
    - Viewed (0)
  2. cmd/storage-rest-server.go

    	}
    
    	return nil
    }
    
    // Authenticates storage client's requests and validates for skewed time.
    func storageServerRequestValidate(r *http.Request) error {
    	token, err := jwtreq.AuthorizationHeaderExtractor.ExtractToken(r)
    	if err != nil {
    		if err == jwtreq.ErrNoTokenInRequest {
    			return errNoAuthToken
    		}
    		return errMalformedAuth
    	}
    
    	if err = validateStorageRequestToken(token); err != nil {
    		return err
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Wed Aug 14 17:11:51 UTC 2024
    - 45.7K bytes
    - Viewed (0)
Back to top