Register for our Dec 19th Webinar: Beyond the Perimeter: Achieving Comprehensive API Security

Blog Post

Technical

API4:2023 Unrestricted Resource Consumption

Stephanie Best
Jun 6, 2023

The Unrestricted Resource Consumption vulnerability has replaced Lack of Resources and Rate Limiting in the OWASP API Security Top 10, but, although the name changed, the vulnerability remains the same overall.

API requests consume resources such as network, CPU, memory, and storage. The number of resources required to satisfy a request greatly depends on the input from the user and the business logic of the endpoint.

APIs do not always impose restrictions on the size or number of resources that can be requested by the client or user, creating security vulnerabilities that can not only impact the API server performance, leading to Denial of Service (DoS), but also leave the door open to brute-forcing and enumeration attacks against APIs that provide authentication and data fetching functionality. This includes automated threats like credential cracking and token cracking, among others.

Get the comprehensive list of best practices to guide your API security journey.

Potential Impact of Unrestricted Resource Consumption

When determining the potential impact of Unrestricted Resource Consumption — number four in the OWASP API Security Top 10 — it is best to break down the impact of this issue into two sub-components:

  1. With respect to lack of resource limiting, an attacker can craft a single API call that can overwhelm an application, impacting the application’s performance and responsiveness or causing it to become unresponsive. This type of attack is sometimes referred to as an application-level DoS. These types of attacks not only impact availability though. They may also expose the system, application or API to authentication attacks and excessive data leakage.
  2. With respect to lack of rate limiting, an attacker may craft and submit high volumes of API requests to overwhelm system resources, brute force login credentials, quickly enumerate through large data sets, or exfiltrate large amounts of data.

What Does Unrestricted Resource Consumption Look Like?

In the example above of a lack of resource limit, the attacker has increased the max_return and page_size values for the search filter from 250 to 20,000. This increase would cause the application to return an excessive number of items in response to a query. It could also cause the application to slow down or become unresponsive for all users.

Real-World Example: the DDoS attack on Poland’s Tax Portal

A very popular example of this type of attack are distributed denial-of-service (DDoS) attacks targeting APIs. One recent example shows how Poland’s key tax portal was rendered unavailable to Polish citizens due to an attack of this category, where hackers were able to exploit the resources that support the APIs behind the central tax service and make it unavailable for several hours.

With Polish government officials quickly pointing the finger at Russian hackers, in light of the Ukraine war, this attack comes to show how today’s social and political landscape makes cybersecurity, and API security in particular, even more crucial for businesses and government institutions alike.

Why Existing Tools Fail to Protect You Against Unrestricted Resource Consumption Attacks

Traditional security controls like WAFs, API gateways, and other proxying mechanisms will commonly offer basic or static rate limiting which are difficult to enforce at scale. Security teams may not know enough about the application design to know what “normal” looks like to enforce limits to thwart attackers while not impacting business functionality. WAFs and API gateways lack the context required to inform security teams on what a normal value should be for an API parameter, and they will miss attacks where an attacker manipulates a single API parameter value to overwhelm the application. These proxies may also only cover ingress, or inbound requests, as opposed to egress traffic, or outbound requests and responses.

How to Protect Your APIs Against Unrestricted Resource Consumption Threats

An API security solution must be able to identify calls to API endpoints and alterations to API parameter values that fall outside of normal usage. This would be done by analyzing all API traffic to create a baseline of typical behavior and identifying deviations that fall outside of that baseline.

In the example above an API security solution will have created a baseline of values for the max_return and page_size parameters and will identify that a value of 20,000 is abnormal. The solution could then alert on and block an attacker who crafts API requests that deviate from the baseline.

To learn more about how Salt can help defend your organization from API risks, you can connect with a rep or schedule a personalized demo.

Tags

Salt Security Blog

Sign up for the Salt Newsletter for the latest resources and blog posts.

November 27, 2024

Eric Schwake
Head of Product Marketing

Industry

Beyond Traditional Security: Addressing the API Security Gap

To safeguard your business from API-specific threats, you need a dedicated solution that offers comprehensive visibility, in-depth contextual analysis, automated governance, robust data protection, and AI-driven threat prevention.

Read more

November 21, 2024

Eric Schwake
Head of Product Marketing

Industry

API (In)security: The Hidden Risk of Black Friday

Learn how, for online retailers, Black Friday represents both a lucrative opportunity and a significant cybersecurity challenge.

Read more

November 5, 2024

Eric Schwake
Head of Product Marketing

Industry

API Security: The Non-Negotiable for Modern Transportation

Airlines and transportation companies heavily rely on APIs to handle sensitive data, from customer information to payment details and flight schedules. While crucial for efficient operations, these APIs are also prime cyberattack targets.

Read more

Download this guide for advice on evaluating key capabilities in API Security

Get the guide
Back