File tree Expand file tree Collapse file tree 2 files changed +1
-6
lines changed Expand file tree Collapse file tree 2 files changed +1
-6
lines changed Original file line number Diff line number Diff line change @@ -494,7 +494,6 @@ func TestSetPadding(t *testing.T) {
494494 data .tokenString = signToken (data .claims , data .signingMethod )
495495
496496 }
497- fmt .Println (data .tokenString )
498497
499498 // Parse the token
500499 var token * jwt.Token
Original file line number Diff line number Diff line change @@ -17,17 +17,13 @@ const (
1717var decodePaddingAllowed uint64
1818
1919// SetDecodePadding will switch the codec used for encoding/decoding JWTs respectively. Note that the JWS RFC7515
20- // states that the tokens will utilize a Base64url encoding with no padding. Unfortuneately , some implementations
20+ // states that the tokens will utilize a Base64url encoding with no padding. Unfortunately , some implementations
2121// of JWT are producing non-standard tokens, and thus require support for decoding. Note that this is a global
2222// variable, and updating it will change the behavior on a package level.
2323func SetDecodePadding (setPadding uint64 ) {
2424 atomic .SwapUint64 (& decodePaddingAllowed , setPadding )
2525}
2626
27- func init () {
28- SetDecodePadding (DisablePadding )
29- }
30-
3127// TimeFunc provides the current time when parsing token to validate "exp" claim (expiration time).
3228// You can override it to use another time value. This is useful for testing or if your
3329// server uses a different time zone than your tokens.
You can’t perform that action at this time.
0 commit comments