Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 728944 - acct-user/cmd5checkpw-0 fails to update the user group
Summary: acct-user/cmd5checkpw-0 fails to update the user group
Status: UNCONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Rolf Eike Beer
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-06-20 20:36 UTC by Adam Purkrt
Modified: 2020-06-21 16:43 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Adam Purkrt 2020-06-20 20:36:23 UTC
When updating a system which has not been updated in seven months or so, I hit the following:

There was net-mail/cmd5checkpw-0.30-r1 installed in the system (since june 2018). It got updated today to net-mail/cmd5checkpw-0.30-r2. With this new version, dependency on acct-user/cmd5checkpw-0 came.

The package acct-user/cmd5checkpw-0 got installed, but emerge was complaining


 * Messages for package acct-user/cmd5checkpw-0:

 * Updating groups for user 'cmd5checkpw' ...
 *  - Groups: nofiles
 * There was an error when attempting to update the groups for cmd5checkpw
 * Please update it manually on your system (as root):
 *       usermod -g nofiles -G  "cmd5checkpw"
 * Updating comment for user 'cmd5checkpw' ...
 *  - Comment: User for cmd5checkpw


The command emerge wants me to run does not make sense:
usermod -g nofiles -G  "cmd5checkpw"

It seems it is the very command emerge executed (and failed).

The message comes from the end of gentoo/eclass/user.eclass
backtracking:
- the command that is run: (line 563) usermod "${opts[@]}" "${euser}"
- ${euser} is set correctly to "cmd5checkpw"
- ${opts[@]} is set incorrectly
- opts array is set on line 548: local opts=( -g "${defgroup}" -G "${exgroups}" )
- ${exgroups} was obviously empty


Not sure if this is an issue with the user.eclass or with the acct-user/cmd5checkpw-0 package
Comment 1 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2020-06-21 16:43:36 UTC
...but empty is correct:

  usermod -g nofiles -G '' "cmd5checkpw"

works just fine for me.  There is a known problem (bug #702102) of failing to add quoting in error output but the command itself should pass arguments correctly.  Don't you have anything more specific?  I suppose there should be the error output from usermod above that.