Grokking Spring Boot
0% completed
Stateless APIs with JWT
{"iss":"https://login.example.com","sub":"ana@example.com","exp":1794319162,"iat":1794318262,"roles":["CUSTOMER"]}
This JSON is the middle part of a token that Ana's app sends with every request. It names the issuer and the user, the times of issue and expiry 15 minutes apart, and Ana's role. When POST /bookings arrives with this token, the booking service books seat A12 without reading the customer table and without checking any password.
The service trusts these few fields because they are signed
.....
.....
.....
Like the course? Get enrolled and start learning!
Reading Progress
0%