Can't add groups, modifying existing removes table permissions

Please report bugs and any annoyances here. Kindly include all possible details: steps to reproduce, expected result, actual result, screenshots, ... etc.
Post Reply
sgrzy01
Posts: 11
Joined: 2016-07-25 20:04

Can't add groups, modifying existing removes table permissions

Post by sgrzy01 » 2021-05-03 17:38

First off:
- Appgini 5.95, upgraded from 5.94
- Ubuntu 20.04
- MariaDB 10.3.25
- php 7.4.3
Also using AppginiHelper from Bizzworx

Have not had the need to chagne users/groups for a while while doing other work on app. Beginning to roll out app to other users which required setting up some new groups. I tried adding a new group, it said successful, but group not added. Noticed that a description of an exsiting group had "&nbsp" in the field, edited group to remove it, saved, said successful but it reset table rights for the group to NO for all tables and removed entries from membership_grouppermissions.

Pulled edited group back up, tried reset table premission that all said NO now to what they shoud be, saved, successful, all set back to NO.

At this point I could access the app with the admin user but all tables showed zero records, could not log in a a normal user, said that the user had no rights to any tables.

So... panic ensues...

- Data is there... and have confirmed I can add records to the the table using the credentials I use with the app.. ie: I can manually add a group via phpmyadmin with app user.
- Behavor is the same in Vivaldi/ Chrome/ Firefox
- App is server based, pulled data and code to my local machine (21.04, maria 10.5.9, php 7.416) same results
- Pulled AppginiHelper from app, same results
- I restored functionality by pulling membership_grouppermissions from a backup and replacing the exisitng table.
- Added group manaully, then tried to use admin interface to set table rights, said successful, pulled back up, all set to NO, no records written to membership_grouppermissions.
- If I edit an existing group, says successful, all rights set to NO and records removed from membership_grouppermissions.
- used browser dev tools to see if any consle errors, none..
- regen'd the application, same results.
- Removed config.php and reran through setup, same results

So.. I'm at a lose on why I can add users, and otherwise work normally with the application, but not add or modify groups, and have any atempt to modify a group, destroy existing rights...

I'm hoping I'm doing something stupid or mising something obvious....

any help/ suggestions?

Thanks!.

pfrumkin
Veteran Member
Posts: 119
Joined: 2020-02-18 17:58
Location: Albuquerque, New Mexico USA

Re: Can't add groups, modifying existing removes table permissions

Post by pfrumkin » 2021-05-03 18:24

Hi,

Have you tried downgrade back to 5.94, see if the upgrade is indeed the cause?

~Paul

sgrzy01
Posts: 11
Joined: 2016-07-25 20:04

Re: Can't add groups, modifying existing removes table permissions

Post by sgrzy01 » 2021-05-04 15:29

Unfortunately don't have a copy… Can someone supply a link to 5.94?

Don't see anywhere on the site to download old versions...

Thanks.

pböttcher
AppGini Super Hero
AppGini Super Hero
Posts: 1249
Joined: 2018-04-01 10:12

Re: Can't add groups, modifying existing removes table permissions

Post by pböttcher » 2021-05-05 06:04

Hi,

can you backup you memebership table all together, delete them afterwards, remove the config.php and rerun the setup. This shall bring back your tables. Now you should be able to recreate your membership tables from the backups one by one (hope you dont have hundreds of groups).
You should recreate your groups with the same id as you had already, this way you can reimport the membership tables for userrecords, etc directly

!! Warning this may have a deep impact on your access permission if you mix up id's, so be very careful about what you do. I do not take any responsability !!

sgrzy01
Posts: 11
Joined: 2016-07-25 20:04

Re: Can't add groups, modifying existing removes table permissions

Post by sgrzy01 » 2021-05-05 17:54

Nice!

That did it! I dropped all the membership tables, reran setup, was then able to re-import my users and re-create the groups and the access tables.

Still don't know what the root issue was, but at least have a fix now.

Thank you for the guidance!

pböttcher
AppGini Super Hero
AppGini Super Hero
Posts: 1249
Joined: 2018-04-01 10:12

Re: Can't add groups, modifying existing removes table permissions

Post by pböttcher » 2021-05-05 18:51

Hi,

as it is very difficult to run any analysis remote, I'm glad that this brought you up and running again.

Post Reply