Generate jwt with user information

后端 未结 1 2078
别跟我提以往
别跟我提以往 2020-12-21 23:40

I using HttpBasicAuthentication from Slim/PHP to protect access to my "/login" route, after validate access a JWT will be create to give access to all routes. So I

1条回答
  •  时光取名叫无心
    2020-12-22 00:13

    if you have $token , $key, algorithm , you can retrieve payload with code down

    JWT::decode($token, $key, array(‘HS256’));
    

    0 讨论(0)
提交回复
热议问题