Conducting threat modeling of APIs
Another advantage of a shift-left approach to API development is that it allows security and development teams to participate in joint threat modeling activities. While a detailed description of threat modeling is beyond the scope of this book, the concept is a simple one (from the Threat Modeling Manifesto):
- What are we working on?
- What can go wrong?
- What are we going to do about it?
- Did we do a good enough job?
The value of threat modeling is best demonstrated with an example. Let us revisit the vulnerability affecting the website of a global shipping company covered in Chapter 4. The website developers made three basic errors in their design:
- They relied on security by obscurity by returning a map imageāthe researchers were able to get an exact postcode from the maps by searching the street names
- They did not rate-limit their tracking-query endpoint, which allowed the researchers to guess the parcel...