- 1000Page 3
Input
Use the proper HTTP method according to the operation: GET (read), POST (create), PUT/PATCH (replace/update), and DELETE (to delete a record), and respond with 405 Method Not Allowed if the requested method isn't appropriate for the requested resource.
Access
Use HTTPS on server side to avoid MITM (Man in the Middle Attack).
Access
Use HSTS header with SSL to avoid SSL Strip attack.
Access
For private APIs, only allow access from whitelisted IPs/hosts.
Access
Limit requests (Throttling) to avoid DDoS / brute-force attacks.
OAuth
Define the default scope, and validate scope parameters for each application.
OAuth
Use state parameter with a random hash to prevent CSRF on the OAuth authentication process.
OAuth
Always try to exchange for code and not tokens (don't allow response_type=token).
OAuth
Always validate redirect_uri server-side to allow only whitelisted URLs.
JWT (JSON Web Token)
Don't extract the algorithm from the header. Force the algorithm in the backend (HS256 or RS256).
JWT (JSON Web Token)
Make token expiration (TTL, RTTL) as short as possible.
JWT (JSON Web Token)
Don't store sensitive data in the JWT payload, it can be decoded easily.
An error occurred. Try again later
Your content has been submitted
- 4Page 3

