Parse parses, validates, verifies the signature and returns the parsed token. keyFunc will receive the parsed token and should return the key for validating.
(tokenString string, keyFunc Keyfunc)
| 44 | // Parse parses, validates, verifies the signature and returns the parsed token. |
| 45 | // keyFunc will receive the parsed token and should return the key for validating. |
| 46 | func (p *Parser) Parse(tokenString string, keyFunc Keyfunc) (*Token, error) { |
| 47 | return p.ParseWithClaims(tokenString, MapClaims{}, keyFunc) |
| 48 | } |
| 49 | |
| 50 | // ParseWithClaims parses, validates, and verifies like Parse, but supplies a default object implementing the Claims |
| 51 | // interface. This provides default values which can be overridden and allows a caller to use their own type, rather |