Skip to content

Commit

Permalink
Edited security comment - Luke review
Browse files Browse the repository at this point in the history
  • Loading branch information
jeoffreyfischer authored Oct 29, 2024
1 parent fbec695 commit 2530550
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions rules/key-principles-of-rest-api-design/rule.md
Original file line number Diff line number Diff line change
Expand Up @@ -72,9 +72,9 @@ Consistent sorting parameters allow developers to retrieve and organize data eff

## Tip \#6 - Security should not be an afterthought

Security is paramount in API design. Pass sensitive information, like access tokens, securely via headers (e.g., `Authorization: Bearer {token}`).
Security is paramount when building REST APIs. Most REST APIs are hosted online, and you don't want to rely on "security via obscurity". Ensure you spend time hardening your surface area.

Common security headers should also be considered:
Common sense approaches include protecting your endpoints via short-lived access tokens (even for seemingly benign functionality), as well as your typical security headers such as:

* Content-Security-Policy (CSP)
* Strict-Transport-Security (HSTS)
Expand Down

0 comments on commit 2530550

Please sign in to comment.