-
Notifications
You must be signed in to change notification settings - Fork 282
Description
Describe the bug
I have many modules in use and many modules provide many permissions
As soon as the Form hits a threshold which can be triggered by providing permissions like that but in a bigger context, storing the form with the Administrative Access switch on is no longer working.
$this->providePermission('strange/40', $this->translate('somemessage'));
To Reproduce
-
Create an IcingaWeb2 Instance with icingadb. it is not that important but raises the amount of form elements.
You can see the modules in the testsetup in the screenshot below -
Create a directory with any name, I used "strange"
-
Create a configuration.php with the following content:
<?php
/** @var \Icinga\Application\Modules\Module $this */
$counter = 400;
while ($counter > 0) {
$this->providePermission('strange/text_'.$counter, $this->translate('somepermission'));
$counter--;
}
?>- Create a new Role with Administrative Access switched on
- Try to store the Role
- No error message no anything, just a reload of the form
- Play with the counter (<280 was still ok) (> 290 breaks the form save function)
Expected behavior
Form should save
Screenshots
Your Environment
Include as many relevant details about the environment you experienced the problem in
- Icinga Web 2 version and modules (System - About): 2.12.6
- Web browser used: Chrome
- PHP version used (
php --version): 8.3 - Server operating system and version: Fedora 42 / Ubuntu 24.04
Additional context
The Button "Administrative Access" creates additional form elements which causes the form to crash earlier
If you set the counter to 500 It won't let you save anything at all.
If you don't use the Administrative access switch the thresholds are:
(<420 was still ok) (> 430 breaks the form save function completely)