Commit graph

3715 commits

Author SHA1 Message Date
Alexandre Aubin
2b51d247fb Propagate changes on app helpers + tests 2019-09-20 20:14:14 +02:00
Alexandre Aubin
ebf2fb9a14 Use relative urls by default for permissions while still supporting absolute urls ... 2019-09-20 20:13:51 +02:00
Alexandre Aubin
87050276b4 Finish to implement first visitor test + fixes following test ... 2019-09-19 19:26:41 +02:00
Alexandre Aubin
8d01a816f3 Typo fixes following tests 2019-09-18 18:39:05 +02:00
Alexandre Aubin
00795a7a01 Make migration re-run even more robust 2019-09-18 18:38:47 +02:00
Alexandre Aubin
64e388fa7d Implement helper function to test if we're able to access a webpage being logged in (or not) as user 2019-09-17 23:38:39 +02:00
Alexandre Aubin
821a3ac4ff Draft tests to check that permissions are actually propagated and effective on the SSO 2019-09-15 18:53:25 +02:00
Alexandre Aubin
b2a26a64a7 Naively migrate legacy and classical unprotected_uris = / that sets the app as public 2019-09-15 18:33:31 +02:00
Alexandre Aubin
c4743398e6 Deprecate (un)protected_uris and _regex settings + more explicit deprecation warning for app_add/remove/clearaccess 2019-09-15 18:17:46 +02:00
Alexandre Aubin
8abfd2a6e6 Naive implementation of protected/unprotected inplementation using the visitors group 2019-09-15 17:58:41 +02:00
Alexandre Aubin
95a8dfa71c Simplify part of app_ssowatconf 2019-09-15 16:59:44 +02:00
Alexandre Aubin
cc59501b55 Naive implementation of visitors group (without any relation to the ssowat conf yet) 2019-09-15 16:59:34 +02:00
Alexandre Aubin
9c383ef06a Make migration more robust to re-runs 2019-09-14 18:21:42 +02:00
Alexandre Aubin
094a2afe1a Simplify permission handling in app_map + add tests for it 2019-09-13 22:45:31 +02:00
Alexandre Aubin
3df6ce17b6 Properly handle all those errors >.> ... 2019-09-13 20:34:30 +02:00
Alexandre Aubin
63fa54171d Ugh we really need to make this raise an exception ... 2019-09-13 20:13:44 +02:00
Alexandre Aubin
732f898773 Small issue when deleting the user 2019-09-13 19:42:15 +02:00
Alexandre Aubin
b995b3254d Remove some unecessary messages when handling primary groups and all_users 2019-09-13 18:41:05 +02:00
Alexandre Aubin
ea8c0cae94 Deprecate legacy app access system 2019-09-13 18:34:26 +02:00
Alexandre Aubin
f950378c63 Do not display primary groups by default when running yunohost user group list 2019-09-13 17:39:21 +02:00
Alexandre Aubin
302e755f48 Assume we target the .main permission if it's not given explicitly 2019-09-13 16:50:46 +02:00
Alexandre Aubin
ccc7583ec4 Add backup/restore test for permission app, and fix a small related bug 2019-09-13 16:33:25 +02:00
Alexandre Aubin
ec5069b71c Propagate changes on backup tests + fixes bugs found in the process 2019-09-13 16:33:25 +02:00
Alexandre Aubin
bdad4ffd71 c.f. issue 1405 ... those 'if ldap.stuff()' are complete bullshit from the very beginning since they never return False : instead they trigger an exception which means the current error management is completely meaningless ... so this refactorize all the places if found those + add proper error messages 2019-09-13 16:33:03 +02:00
Alexandre Aubin
2e14834e6b Misc fixes following tests 2019-09-13 16:33:03 +02:00
Alexandre Aubin
b912cd0aec Propagate all changes to tests 2019-09-13 16:33:03 +02:00
Alexandre Aubin
fe8f7f2210 Update permission helper : have a single helper to manage urls, and a helper to add/remove groups to permission 2019-09-13 16:33:03 +02:00
Alexandre Aubin
68db93cd63 Fix an issue about groups not being properly cleaned and perms synced when deleting a user 2019-09-13 16:33:03 +02:00
Alexandre Aubin
f1f6513796 Small tweaks for user group tests 2019-09-13 16:33:03 +02:00
Alexandre Aubin
c0361430e2 Try to simplify + comment the code of check_LDAP_db_integrity 2019-09-13 16:33:03 +02:00
Alexandre Aubin
e40698ef20 Propagate changes on migration 2019-09-13 16:33:03 +02:00
Alexandre Aubin
bbfc62cf3e Backup/restore app permissions using yaml files which are much simpler to handle... 2019-09-13 16:32:32 +02:00
Alexandre Aubin
a92ff53077 Propagate changes to other parts of the code relying on groups and permissions 2019-09-13 16:32:32 +02:00
Alexandre Aubin
d5b2fb7a71 Misc fixes/improvements for i18n strings 2019-09-13 16:32:32 +02:00
Alexandre Aubin
38c43f4b9a Fix the whole operation logger / related to thing + propagate on the legacy addaccess 2019-09-13 16:31:03 +02:00
Alexandre Aubin
98b1c30330 Simplify app_ssowatconf code related to permissions 2019-09-13 16:31:03 +02:00
Alexandre Aubin
853c6a161a Simplify permission_sync_to_user ... force is never set to True so I dropped it... 2019-09-13 16:31:03 +02:00
Alexandre Aubin
574e9aea44 Simplify permission_create/urls/delete interface and code 2019-09-13 16:31:03 +02:00
Alexandre Aubin
3535cb655f Fix call of app add/remove access hooks 2019-09-13 16:31:03 +02:00
Alexandre Aubin
a1d3376613 Simplify permission_clear, now named permission_reset 2019-09-13 16:31:03 +02:00
Alexandre Aubin
e5676c4b30 Propagate change in permission_list to permission_update 2019-09-13 16:31:03 +02:00
Alexandre Aubin
45483f4116 --short and --full options for group_list and permission_list 2019-09-13 16:31:03 +02:00
Alexandre Aubin
41e6f1b81c Simplify permission_add/remove to just permission_update with --add and --remove, similar to what's done for groups 2019-09-13 16:31:03 +02:00
Alexandre Aubin
6276485665 Simplify permission_list ... it really sounds like we don't need all these options 2019-09-13 16:31:03 +02:00
Alexandre Aubin
112976f8ee Refuse to edit user primary groups 2019-09-13 16:31:02 +02:00
Alexandre Aubin
97c637f44c Fix group command descriptions in the actionmap 2019-09-13 16:31:02 +02:00
Alexandre Aubin
c5d0a27098 Simplify group info and group update interface and code 2019-09-13 16:31:02 +02:00
Alexandre Aubin
0f7b8c3515 Simplify group list interface and code 2019-09-13 16:31:02 +02:00
Alexandre Aubin
a6d68c76c4 permission_update -> permission_urls (+ tweak the helper name) so that it's more differentiable from user_permission_update 2019-09-13 16:31:02 +02:00
Alexandre Aubin
f60af2053f permission_add/remove becomes create/delete to be consistent with user and group create/delete. In the context of permissions, add/remove shall instead be related to adding/removing an existing permission for a user or group. 2019-09-13 16:31:02 +02:00