Security Flashcards
Security patterns
Access Token
Access token: context
You have applied the Microservice architecture and API Gateway patterns. The application consists of numerous services. The API gateway is the single entry point for client requests. It authenticates requests, and forwards them to other services, which might in turn invoke other services.
Access token: problem
How to communicate the identity of the requestor to the services that handle the request?
Access token: forces
Services often need to verify that a user is authorized to perform an operation
Access token: solution
The API Gateway authenticates the request and passes an access token (e.g. JSON Web Token) that securely identifies the requestor in each request to the services. A service can include the access token in requests it makes to other services.
Access token: example
See JSON Web Token for usage examples and supporting libraries.
Access token: result
- The identity of the requestor is securely passed around the system
- Services can verify that the requestor is authorized to perform an operation
Access token: related
The API Gateway uses this pattern.