Sanke Yaswanth on 25 Jan 2024 10:06:01
For a dataset with RLS implemented and when we add user as a workspace member, the RLS doesn't work which is expected and the user should be given Viewer role but when we add user as a member by mistake and when we change the access to viewer, still RLS doesn't work.
If we wait for couple of days, the RLS will be implemented correctly and resolves the issue by itself without any changes.
Is this an expected behavior or please provide any further insights on this.
- Comments (1)
RE: Row level security issue.
To give more information on the issue:Recap : A user who is given MEMBER rôle in a workspace, will retain this rôle even after changing it to VIEWER. reproducing the bug : 1)Implement RLS and add a user to this RLS policy. 2) Add user to the workspace as MEMBER and save : this is the easy mistake, because the default dropdownbox choice is MEMBER 3)Change rôle from MEMBER to VIEWER. 4) Impersonate the user on RLS, now the RLS filter is failing. Solution : Remove the user from workspace. Wait several days(not sure how many). Add user as VIEWER. and behold, RLS is functioniong.