File tree 1 file changed +4
-2
lines changed
1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -71,8 +71,8 @@ Example encode/decode headers
71
71
Decoding the JWT headers without verifying the JWT first is NOT recommended, and is not supported by
72
72
this library. This is because without verifying the JWT, the header values could have been tampered with.
73
73
Any value pulled from an unverified header should be treated as if it could be any string sent in from an
74
- attacker. If this is something you still want to do in your application for whatever reason, it's possible to
75
- decode the header values manually simply by calling ` json_decode ` and ` base64_decode ` on the JWT
74
+ attacker. If this is something you still want to do in your application for whatever reason, it's possible to
75
+ decode the header values manually simply by calling ` json_decode ` and ` base64_decode ` on the JWT
76
76
header part:
77
77
``` php
78
78
use Firebase\JWT\JWT;
@@ -377,6 +377,8 @@ All exceptions in the `Firebase\JWT` namespace extend `UnexpectedValueException`
377
377
like this:
378
378
379
379
``` php
380
+ use Firebase\JWT\JWT;
381
+ use UnexpectedValueException;
380
382
try {
381
383
$decoded = JWT::decode($payload, $keys);
382
384
} catch (LogicException $e) {
You can’t perform that action at this time.
0 commit comments