denial-of-service

Identifies denial-of-service risks in Solidity contracts from unsafe iteration patterns.

120|12|Updated Apr 10, 2026
One-click install
npx skills add https://github.com/ccashwell/evm-cortex --skill denial-of-service
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: denial-of-service
Source: https://github.com/ccashwell/evm-cortex/tree/main/skills/denial-of-service
Command: npx skills add https://github.com/ccashwell/evm-cortex --skill denial-of-service

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Denial-of-service patterns in Solidity contracts can cause unbounded loops, failed external calls, and griefing, leading to gas exhaustion and degraded user experience.

Core Features & Use Cases

  • Prevents unbounded iteration by favoring pull-based patterns where users claim rewards or state updates.
  • Supports paginated processing for batch operations to stay within gas limits.
  • Provides guidance for handling external calls and failure scenarios to avoid blocking execution.

Quick Start

Describe a safe iteration approach for processing user-controlled lists without running into gas or DoS issues.

Frequently Asked Questions about denial-of-service

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
What causes denial-of-service risks in Solidity smart contracts?

Denial-of-service risks in Solidity contracts stem from unbounded loops, failed external calls, and griefing, leading to gas exhaustion and degraded user experience when processing user-controlled lists.

How do I prevent gas exhaustion when iterating over user data in Solidity?

Prevent gas exhaustion in Solidity iteration by favoring pull-based patterns where users claim rewards or state updates, and by implementing paginated processing for batch operations to stay within gas limits.

What is the pull pattern for Solidity batch processing?

The pull pattern in Solidity allows users to claim rewards or state updates individually, preventing unbounded iteration and ensuring batch processing operations do not exceed block gas limits or block execution.

How do external calls cause denial-of-service in smart contracts?

External calls cause denial-of-service in smart contracts when failures block execution, requiring guidance on handling failure scenarios to prevent griefing and ensure withdrawal mechanisms function properly under varying input sizes.

Can I use pagination to handle large batch operations in Solidity?

Pagination supports batch operations in Solidity by processing user-controlled lists in segments, ensuring operations stay within gas limits and preventing unbounded iteration that causes denial-of-service vulnerabilities.

When should I avoid on-chain loops over user data in smart contracts?

Avoid on-chain loops over user data in smart contracts when input size can vary unpredictably, as unbounded iteration causes gas exhaustion; instead use pull-based patterns or paginated processing to prevent denial-of-service.