Every program on your phone speaks to a server using an API: your bank balance, the live location of your cab, even the weather widget on your home screen. And that convenience is why API security is a major worry for developers in 2026. Attackers don’t require a fake login page when they can send requests directly to an endpoint and read whatever is sent back.
In this post, I’ll explain what APIs are, why they are exploited, and the seven vulnerabilities teams most typically encounter. You’ll also get 2 real breaches, some practical remedies and a quick Burp Suite walkthrough of testing.
What Is An API And Why Does API Security Matter?

An API ( Application Programming Interface ) is an agreement that lets one software ask another software for data or to do things . A mobile app makes an HTTP request, some logic is run on the server, and the API responds, usually with JSON. There is no nice screen in the middle sitting to disguise anything. So whatever an endpoint returns is exactly what an attacker sees too.
That’s why API security is critical. APIs are right in front of databases, payment systems and customer records and they expand fast: microservices, partner integrations, ancient mobile app versions nobody decommissioned. Everyone is a doorway. Good API security keeps those doors locked and watched, protects client data, promotes compliance with GDPR, PCI DSS and India’s new DPDP Act, and saves you the reputational harm of a leak.
Authentication Vs Authorization In API Security
Attackers benefit from people mixing these up all the time. Authentication is “who are you?” and is confirmed via passwords, API keys, tokens or certificates. Authorisation means ” What are you allowed to do ?” and is enforced through roles, scopes and policies .
If a system lacks authorisation, it can authenticate flawlessly and still leak someone else’s data. Both checks must be done on every request, on the server, and never only in the client app. Most of the vulnerabilities mentioned come down to one of them being weak or missing.
Common API Vulnerabilities

Vulnerability 1: Broken Object Level Authorization (BOLA)
BOLA is the top of the OWASP API Security Top 10. Here is where an endpoint takes an object ID, such as /api/orders/1001, and delivers the record without confirming that the caller owns it. An attacker enters in under his own account , changes 1001 to 1002 and reads a stranger ‘s order . And a simple script does that again for thousands of IDs.
Verify ownership on each item, each request, preferably in shared middleware so no one forgets. Make it right. Random UUIDs make guessing harder, but are no alternative. Add automated tests to login as user A and try to get user B’s data.
Vulnerability 2: Broken Authentication and Weak Token Validation
Broken authentication is pretty much anything that allows someone masquerade as another user. Endpoints with no authentication, default passwords, tokens that never expire, credentials in URLs or source code. Token handling is often the issue. I’ve seen JSON Web Tokens that were accepted with the algorithm set to “none”, signatures that were never being validated, expired tokens that kept working for months.
Validate each token fully signature, issuer, audience and expiration. • Enforce the algorithms allowed on the server • Use short-lived access tokens • Rotate refresh tokens • Store secrets in a vault, not in Git • Enforce multi-factor authentication for sensitive tasks This is the API security layer where a lot of significant breaches start.
Vulnerability 3: API Injection Attacks
Injection occurs when user input is taken as part of a command. SQL injection is the classic, but APIs can also be vulnerable to NoSQL, command and LDAP injection. A login endpoint that directly inserts JSON into a MongoDB query can be fooled by `{“username”: {“$ne”: null}}` which matches any user without having a password.
Use parameterized queries, evaluate every request against a rigorous schema, allow-list expected values and run database accounts with minimum access. The web application firewall is a good extra layer, but not the sole layer.
Vulnerability 4: Missing Rate Limiting and Brute-Force Protection
By default, an API will be happy to serve you a million requests. It allows attackers to brute-force passwords, replay credentials stolen from other sites, grab data or drain your servers. This is called unrestrained resource use by OWASP.
Set per user, per IP and per API key constraints, and make them stronger on login, OTP and password-reset endpoints. Implement exponential back-off, temporary lockouts and CAPTCHA on suspect flows. Cap payload sizes and page sizes, and return HTTP 429 so well-behaved clients slow down. Looking for these surges is just regular API security.
Vulnerability 5: Excessive Data Exposure
Often developers would return the entire database object assuming the front end will hide fields. The app might show you just a name but the raw response has email, phone number, internal flags and sometimes password hashes. The attackers read network traffic . Not the screen . Another issue is mass assignment, where users can provide additional fields such as “isAdmin”: true and the server would accept them. Return only the fields required by each client Specify response schemas explicitly Reject unknown attributes in requests
Vulnerability 6: Security Misconfiguration
Verbose error messages, wide-open CORS rules, default passwords, missing TLS, unpatched components and remaining debug endpoints offer attackers a head start. Harden all environments the same. Automate configuration checks in your CI process. Enforce HTTPS everywhere. Strip stack traces from production answers.
Vulnerability 7: Improper Inventory Management
You can’t defend what you don’t know is there. Older API versions, lost test endpoints and undocumented “shadow” APIs lack the controls included in the latest version. Keep your OpenAPI specs up-to-date with your inventory. Plan for the retirement of deprecated versions. Scan for endpoints that appear in traffic but not your documentation. API security always starts with a solid foundation, an exhaustive inventory of what you are protecting.
Two Real World Examples
Optus (Australia, 2022)
In September 2022 the telecom discovered a breach that impacted around 9.8 million current and former subscribers. Public reports show that attackers were able to obtain records through an API endpoint that required no authentication, a textbook example of weak authentication and poor inventory management. The leaked data included details of identity documents. The repercussions included regulatory attention and an expensive clean-up.
T-Mobile (USA, 2023)
In January 2023, T-Mobile said a single API was exploited by an attacker to grab data on around 37 million user accounts, including names, billing addresses, emails and phone numbers (Krebs on Security). The access reportedly started in late November 2022 and lasted for roughly six weeks before it was detected. A well-funded organization can still miss irregular API access if they don’t have effective monitoring, rate limitation and anomaly detection. These two cases indicate that API security must be an afterthought.
Securing APIs With OAuth 2.0, JWT And API Gateways
OAuth 2.0 is the industry standard protocol for delegated authorisation. Users allow limited access through scopes and an authorisation server issues access tokens . Passwords are not handed over to third-party apps . Web and mobile apps use the Authorisation Code flow with PKCE. Server-to-server calls use Client Credentials. No more outdated implicit flow.
JSON Web Tokens (JWT) hold claims such as user ID, scopes and expiry, which allow services to validate them without a database query. This only works if you check the signature + exp, iss and aud claims on each request, keep lifetimes short and never store secrets inside. The payload is encoded, not encrypted.
Then an API gateway sits in front of your services as a single point of enforcement. It can terminate TLS, validate tokens, set rate limitations, check request schemas, log traffic, and block problematic clients before they reach your code. Azure API management and Google’s Apigee provide these controls. Combined, OAuth 2.0, JWT and a gateway give you multilayer API security, without having to rebuild the same checks in each microservice. Add zero-trust thinking here, as well. As NIST suggests for microservices, authenticate and authorise each call, even internal ones.
API Security Testing Using Burp Suite

Defences only count if you prove them. PortSwigger’s Burp Suite is the standard tool for most penetration testers and the free Community Edition is more than enough to get you started. Simple workflow:
Proxy the traffic: Point your browser or phone at Burp’s proxy and install its CA cert to read HTTPS.
Map the API: Browse the app while Burp records the traffic, then scroll the HTTP history. Import your OpenAPI file and compare the two lists. Anything in one but not the other deserves a closer look.
Test BOLA: Push a request into Repeater and swap the object IDs between your two test accounts. If account A can read account B’s data, you’ve found it.
Test tokens: Mess with a JWT by editing a claim, stripping it out, or replaying an old one, expired tokens included. The server should turn down every attempt.
Test injection and limits: Intruder testing with initial payload lists and repeated login attempts – Checking status codes and response lengths
Only test systems that you own or have written authority to test. Run these checks in staging on every major release. Testing becomes a habit, not a yearly audit.
Final Thoughts
None of these seven vulnerabilities are exotic. They keep coming up because teams ship fast & test late. Start small: inventory your endpoints, authorise every object, validate tokens fully, implement rate limitations, and install a gateway in front. Then test using Burp Suite and fix what you notice. Teams who consider API security as part of the development lifecycle, not as a final gate, have considerably fewer occurrences.
Frequently Asked Questions
1. What is API Security and why do you care?
API security is the technique of safeguarding APIs from misuse and attacks using authentication, authorisation, encryption, input validation, rate limitation and monitoring. That concerns because APIs expose data and business logic directly to the internet, thus a single weak endpoint can leak millions of records.
2. Which is the most prevalent API vulnerability?
Broken Object Level Authorisation (BOLA) is #1 (API1) on the OWASP API Security Top 10 2023. simple to exploit (typically just changing an ID in the request), simple to miss in code review.
3. What is the difference between authentication and authorization in an API?
Authentication determines who the caller is. Authorisation determines what the caller can access or change . Every request to an API has to be checked.
4. Is JWT security enough for API authentication?
JWT is a good building block for API security: Validate the signature, issuer, audience and expiry, keep lifetimes short and only send tokens over HTTPS. Not doing such checks makes it a weakness. OAuth 2.0 is where it works best.
5. How do I scan my API for vulnerabilities?
Test BOLA , token handling , injection and rate limitations using a proxy tool such as Burp Suite , OWASP ZAP or Postman collections in a staging environment , with explicit permission . Automate API security checks in your CI pipeline for continuous testing.
Try Our Tools
Ready to put this into practice? For useful tools to help with daily development and security tasks, check out the ExplainMeTech tools page. Start building better habits around API security, one check at a time.
References
- OWASP Foundation. OWASP API Security Top 10 (2023). https://owasp.org/API-Security/editions/2023/en/0x11-t10/
Supports BOLA, broken authentication, rate limiting, data exposure, misconfiguration and inventory management. - NIST. SP 800-204: Security Strategies for Microservices-based Application Systems. https://csrc.nist.gov/pubs/sp/800/204/final
Supports the zero-trust advice and the API gateway section. - Microsoft Learn. Recommendations to mitigate OWASP API Security Top 10 threats using Azure API Management. https://learn.microsoft.com/azure/api-management/mitigate-owasp-api-threats
Supports the gateway, token validation and rate limiting advice. - Google Cloud. Best practices for securing your applications and APIs using Apigee. https://docs.cloud.google.com/architecture/best-practices-securing-applications-and-apis-using-apigee
Supports the gateway and layered defence section. - PortSwigger Web Security Academy. API testing. https://portswigger.net/web-security/api-testing
Supports the Burp Suite testing workflow.
If you want more technology, cybersecurity and digital-security ideas, head on over to ExplainMeTech.com and see our latest guides, tools and insights.