Data security rule granted for all roles is dropped if layer settings are saved again
Description
I run up to this issue first with version 2.19.2. I tried to replicate the behavior with stable version 2.20.2 and was successful doing so. I used windows binary installer.
Steps to reproduce the issue:
Install Geoserver 2.20.2
Create a workspace
Create a Postgis store (in my case localhost as well; haven’t tested other stores)
Publish a layer from the store
Create a data security rule with the following: the workspace you created, the layer you created, access mode set to any of read/write/admin and 'access granted to every role' ticked
Go back to the layer settings and change anything (or just save again)
Go back to data security window and check if the rule is still listed (should be gone)
UPDATE 24.03.2022: It seems that, at least for read rights, using grant access to any role option in data dialog is not replicated properly to security tab in edit layer dialog. Security settings in edit layer dialog won’t show any sign of the above mentioned rule and if a user saves the layer settings the data rule made in New data access rule dialog is lost.
Please let me know if I can clarify in any way.
UPDATE 13.4.2022:
This concerns all different access types, not just read as I wrote in my original post.
I run up to this issue first with version 2.19.2. I tried to replicate the behavior with stable version 2.20.2 and was successful doing so. I used windows binary installer.
Steps to reproduce the issue:
Install Geoserver 2.20.2
Create a workspace
Create a Postgis store (in my case localhost as well; haven’t tested other stores)
Publish a layer from the store
Create a data security rule with the following: the workspace you created, the layer you created, access mode set to any of read/write/admin and 'access granted to every role' ticked
Go back to the layer settings and change anything (or just save again)
Go back to data security window and check if the rule is still listed (should be gone)
UPDATE 24.03.2022:
It seems that, at least for read rights, using grant access to any role option in data dialog is not replicated properly to security tab in edit layer dialog. Security settings in edit layer dialog won’t show any sign of the above mentioned rule and if a user saves the layer settings the data rule made in New data access rule dialog is lost.
Please let me know if I can clarify in any way.
UPDATE 13.4.2022:
This concerns all different access types, not just read as I wrote in my original post.