WSTG-v42-BUSL-05 / GUIDANCE
Test Number of Times a Function Can Be Used Limits
Many of the problems that applications are solving require limits to the number of times a function can be used or action can be executed. Applications must be "smart enough" to not allow the user to exceed their limit on the use of these functions since in many cases each time the function is used the user may gain some type of benefit that must be accounted for to properly compensate the owner. For example: an eCommerce site may only allow a users apply a discount once per transaction, or some applications may be on a subscription plan and only allow users to download three complete documents monthly. Vulnerabilities related to testing for the function limits are application specific and misuse cases must be created that strive to exercise parts of the application/functions/ or actions more than the allowable number of times. Attackers may be able to circumvent the business logic and execute a function more times than "allowable" exploiting the application for personal gain.
- Category
- OWASP assurance
- Version / scope
- OWASP WSTG pinned commit dd33419
- Affected / relevant technologies
- Web applications
- Evidence
- Documentation: pinned-source excerpt checked. Execution: not tested. Editorial: curated reference.
Defensive analysis and explicitly authorized assessment only. This website performs no scans, exploitation, model calls or infrastructure changes. Indicators below are investigation opportunities, not proof of compromise or guaranteed detectors.
Mechanism and prerequisites
Apply only to authorized systems and select the relevant scope and verification level. This publisher reference is not evidence of a completed assessment.
Potential impact
The publisher describes a verification objective; applicability does not establish a local defect or a compliance result.
Versioned source scope
This record contains normalized, sometimes shortened source excerpts with editorial safety context. Markup and executable example blocks are omitted. Source-field verification does not establish device testing, a working detector or local applicability.
Publisher: OWASP. Release: OWASP WSTG pinned commit dd33419. Source checked: 2026-11-18.
Source object: document/4-Web_Application_Security_Testing/10-Business_Logic_Testing/05-Test_Number_of_Times_a_Function_Can_Be_Used_Limits.md.
Attribution and source terms (OWASP contributors · CC BY-SA 4.0)Detection and investigation
- - Identify functions that must set limits to the times they can be called. - Assess if there is a logical limit set on the functions and if it is properly validated.
Preserve source timestamps, asset identity and collection context. Correlate independent evidence before attributing malicious intent. In OT, review passive evidence with the process owner; do not induce failures, replay commands or write to controllers to test a hypothesis.
Mitigation and response
- The application should set hard controls to prevent limit abuse. This can be achieved by setting a coupon to be no longer valid on the database level, to set a counter limit per user on the back end or database level, as all users should be identified through a session, whichever is better to the business requirement.
Apply changes through the asset owner's approved change and recovery process. Documentation review is separate from successful testing or verified production protection.
Related technical context
No protocol-specific mapping is asserted for this entry.
Authoritative sources and attribution
Identifiers and source titles belong to OWASP, MITRE, the CVE Program, CISA, NIST or the cited vendor. Source excerpts are attributed and adapted under the linked publisher license; editorial context is separate. This is not an official framework mirror. Review baseline: 2026-11-18. Live documents can change; check exact current applicability.
- https://github.com/OWASP/wstg/blob/dd33419e10edb22b78d89325a6c2aad9f184e3a2/document/4-Web_Application_Security_Testing/10-Business_Logic_Testing/05-Test_Number_of_Times_a_Function_Can_Be_Used_Limits.md — Publisher link; not separately HTTP-checked
- document/4-Web_Application_Security_Testing/10-Business_Logic_Testing/05-Test_Number_of_Times_a_Function_Can_Be_Used_Limits.md — source accessed 2026-11-18
Source review supports bounded reference text. It is not execution evidence, a completeness claim, a CVSS assessment, a compliance certification or verification of production security.
