Sulu Block System Recursion Limits
0 reputation · 02 Feb 2026, 04:33 UTC
Nested Block Validation
Sulu CMS 2.x allows the definition of reusable content structures via block types. When configuring allowed_types, it is possible to create a block type that references itself or forms a circular dependency with other block types.
The BlockResolver service processes these structures recursively. However, the current configuration options for block types do not provide a native mechanism to enforce a maximum nesting depth or prevent circular references during content creation in the admin UI.
Without a configurable recursion guard, deeply nested or recursive structures may lead to stack overflows during serialization or page rendering, with PHP memory limits serving as the only boundary.
- Does the Sulu 2.x core provide a documented way to restrict the maximum depth of nested blocks?
- Is there a built-in validation mechanism to detect and block circular block references before content is saved?