diff --git a/usermngr/Makefile b/usermngr/Makefile index 6a9284718..ed2816771 100644 --- a/usermngr/Makefile +++ b/usermngr/Makefile @@ -5,7 +5,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=usermngr -PKG_VERSION:=1.3.3 +PKG_VERSION:=1.3.4 LOCAL_DEV:=0 ifneq ($(LOCAL_DEV),1) diff --git a/usermngr/files/etc/config/users b/usermngr/files/etc/config/users index 20eda1d5e..849fdbc76 100644 --- a/usermngr/files/etc/config/users +++ b/usermngr/files/etc/config/users @@ -5,3 +5,13 @@ config user 'admin' config user 'user' option enabled '1' option remote_access '1' + +config role 'full_access' + option enabled '1' + option role_id '1' + option name 'full_access' + +config role 'untrusted' + option enabled '1' + option role_id '2' + option name 'Untrusted' diff --git a/usermngr/files/etc/uci-defaults/91-sync-shells b/usermngr/files/etc/uci-defaults/91-sync-shells index af3fc03c1..cc5c3f958 100644 --- a/usermngr/files/etc/uci-defaults/91-sync-shells +++ b/usermngr/files/etc/uci-defaults/91-sync-shells @@ -10,10 +10,10 @@ add_system_shells() { # Add the shell in UCI if not exists sec=$(uci -q show users | grep -E "^users\.@shell\[[0-9]+\]\.name=\'$shell_name\'$") if [ -z "${sec}" ]; then - sec=$(uci -q add users shell) + sec="shell_${shell_name}" + uci -q set users."${sec}"=shell uci -q set users."${sec}".name="${shell_name}" uci -q set users."${sec}.enabled=1" - uci commit users fi done } @@ -60,4 +60,3 @@ remove_shell() { config_load users add_system_shells config_foreach remove_shell shell -uci commit users