security-review-owasp-bean-validation

Identify missing or unsafe Jakarta Bean Validation controls in Java code.

Updated Mar 26, 2026
One-click install
npx skills add https://github.com/sjinks/ai-owasp-skillset --skill security-review-owasp-bean-validation
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: security-review-owasp-bean-validation
Source: https://github.com/sjinks/ai-owasp-skillset/tree/main/.github/skills/security-review-owasp-bean-validation
Command: npx skills add https://github.com/sjinks/ai-owasp-skillset --skill security-review-owasp-bean-validation

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill helps security reviewers spot missing, weak, or inconsistently triggered Bean Validation controls that allow unsafe input to reach sensitive Java business logic.

Core Features & Use Cases

  • Constraint coverage review: Checks whether externally controlled fields have the right size, format, range, and structure constraints.
  • Trigger-point analysis: Verifies that validation actually runs at controllers, service boundaries, nested object graphs, and other trust boundaries.
  • Validator safety review: Flags risky regex patterns, fail-open custom validators, and validation code that mixes business logic with enforcement.
  • Use case: Review a REST API or service layer to find where malformed DTOs, nested beans, or custom constraints could bypass intended input controls.

Quick Start

Ask Copilot to review the selected Java validation flow for missing constraints, trigger points, regex safety, and custom validator behavior with the Bean Validation skill.

Frequently Asked Questions about security-review-owasp-bean-validation

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

FAQPage Schema
How do I find missing Jakarta Bean Validation constraints on Java DTOs?

To find missing Jakarta Bean Validation constraints on Java DTOs, review externally controlled fields for evidence of size, format, range, and structure constraints. This identifies where unsafe input could bypass intended input controls and reach sensitive business logic.

What is a fail-open custom validator in Jakarta Bean Validation?

A fail-open custom validator in Jakarta Bean Validation occurs when validation code mixes business logic with enforcement, allowing malformed input to pass through instead of blocking it. Validator safety review flags these risky patterns and ensures fail-closed behavior before trust-boundary execution.

How do I check if Bean Validation triggers at the right trust boundaries?

To check if Bean Validation triggers at the right trust boundaries, verify that validation actually runs at controllers, service boundaries, and nested object graphs. Trigger-point analysis confirms validation enforcement occurs before trust-boundary execution processes the input.

Does this Bean Validation review check regex safety in custom constraints?

Yes, this Bean Validation review checks regex safety in custom constraints by flagging risky regex patterns that could cause ReDoS or bypass enforcement. It ensures regex-backed constraints handle invalid input safely before trust-boundary execution.

What is the best way to review nested object graphs for validation gaps?

The best way to review nested object graphs for validation gaps is to apply constraint coverage and trigger-point analysis across the entire object graph, verifying that validation cascades through nested beans and custom constraints at each trust boundary.

When should I not rely solely on Bean Validation for Java security?

You should not rely solely on Bean Validation for Java security when validation code mixes business logic with enforcement or lacks fail-closed behavior. Constraint coverage review identifies these gaps but cannot replace comprehensive security assessment workflows.