[FS#988] Procd does not respect a user's groups when using parameter user

LEDE Bugs lede-bugs at lists.infradead.org
Thu Nov 9 01:59:52 PST 2017


The following task has a new comment added:

FS#988 - Procd does not respect a user's groups when using parameter user
User who did this - Yousong Zhou (yousong)

----------
Hi, please check relevant entries in /etc/passwd and /etc/group to see if user "foo" has the right primary group id set there.  If you are using /lib/functions.sh to add group and users, it's very likely that it generated wrong id in the user/group database.

The following snippet should confirm that.


. /lib/functions.sh
# old, buggy way
# group_add_next bar; gid=$?
gid=$(group_add_next bar)
user_add foo "" "$gid"

. /lib/functions/procd.sh
service_triggers() { true; }
procd_open_service foo foo
procd_open_instance bz
procd_set_param user foo
procd_set_param command '/bin/sh' '-c' 'logger $(id)'
procd_close_instance
procd_close_service

----------

More information can be found at the following URL:
https://bugs.lede-project.org/index.php?do=details&task_id=988#comment3810



More information about the lede-bugs mailing list