json-web-token

Is it ok to store user credentials in the JWT

我的未来我决定 提交于 2020-02-26 12:07:25
问题 Is it ok to store user credentials (username / password) in the JWT (so sign it and verify the resulted token later)? I heard that No, it is not secure to send a password in a JWT. This is because the JWT claims are simply encoded and can easily be decoded by anyone that sees them. It is not secure to store any sensitive information in a JWT that returned to a user but I don't know why does the JWT website recommends using it for authentication purposes then: When should you use JSON Web

JWT with Spring OAuth2

不问归期 提交于 2020-01-11 09:58:09
问题 I have created the Spring Authorization Server which issues JWT-s and a Resource Server which checks the JWT, its claims and permissions on the Authorization Server. To do so, I have followed this article. My question is why I need to send the Authorization header with HTTP Basic authorization and Base64 encoded username/password (ClientId:ClientSecret) in get token request? I have seen JWT implementations where only username and password are required. 回答1: It is part of the specification,

JWT with Spring OAuth2

ⅰ亾dé卋堺 提交于 2020-01-11 09:58:06
问题 I have created the Spring Authorization Server which issues JWT-s and a Resource Server which checks the JWT, its claims and permissions on the Authorization Server. To do so, I have followed this article. My question is why I need to send the Authorization header with HTTP Basic authorization and Base64 encoded username/password (ClientId:ClientSecret) in get token request? I have seen JWT implementations where only username and password are required. 回答1: It is part of the specification,

Why do we need JWT when we have client sessions?

孤人 提交于 2020-01-03 09:24:34
问题 I understand that JWT are stateless tokens that store signed information about the client's claim and are passed to a server via the Authorization HTTP header. My question is, why do we need JWT when we already have client sessions (https://github.com/mozilla/node-client-sessions)? Client sessions are conceptually the same. They're cookies that contained signed information which when verified means the cookie hasn't been tempered with. Also, client sessions are stored in a cookie and passed

How to return a JSON Web Token in a C# WEB API?

狂风中的少年 提交于 2019-12-22 11:15:59
问题 I am trying to wrap my ahead around using JWT to secure a WEB API written in C#, but am getting hung up on a few things. From my understanding the flow should be something like this: Client provides username/password to the Web API from some client application (Angular, .NET, Mobile, etc) The Web API validates that the username/password is correct and then generates a JWT (JSON Web Token) that contains the user's roles, information, expiration date, and other relevant information. The JWT is

How to keep client JSON web token secure in a React Native app?

依然范特西╮ 提交于 2019-12-20 12:27:27
问题 We are building a React Native app for iOS and we are using an internal API built on node + express + jsonwebtoken. When the user logs in with username/password, the server validates those credentials and sends the client back a JSON web token that they must then send along with every API request. So the React native app must store this token. How do I securely store this client token in the React native app? Is it necessary to take any additional steps besides just storing the token in a