[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

RE: useradd lsb-compatibility



There is a difficulty with this command.  There has been a
decision to accomodate the behavior of some implementations
that automatically make a group when you add a user.  (To
my mind the group should never be made unless you ask for
it explicitly, but that decision is made).

It is known that this will cause a problem given a particular
scenario:  create user, add another user to the group that
is created as a side effect, remove user.  Because the
group is non-empty, it cannot now be removed.  Create the
user again - as you notice, it will fail, and in an unfortunate
and unexpected way.

It's hard to think that there's a good way to describe this
behavior in the standard, other than to say that the behavior
is undefined in this situation (as it will not be a problem
for implementations that do NOT create groups automatically,
and those are also conforming implementations).  Thus there
was a recent decision to say something about this in the
test suite - I believe that this may fail, but will be
listed as an exception.



-----Original Message-----
From: Yaroslav Popovitch [mailto:yp@sot.com]
Sent: Friday, November 23, 2001 12:44 PM
To: lsb-test@lists.linuxbase.org
Subject: useradd lsb-compatibility




Hi! I have some trouble with useradd command from shadow-utils package.
It seems,that it not fully lsb-compatible.

I had problems with adding user with the same name as existing group.
I fixed it by removing check from sources.I do not feel that is 100%
correct. 
PS. I saw that somewhere exists special lsb - patch for shadow-utils.

After that I remade lsb test for lsb.usergroups and got such errors:

************************************************************************
        /tset/LSB.usersgroups/commands/misc/T.misc 72   Failed

                Test Information:
        useradd -m -k : add a user with specified home dir. 14-1
        useradd -m -k FAILED: home dir is not created correctly.
        WARNING: un-able to remove an added test user and/or his/her
home_dir.    


************************************************************************
        /tset/LSB.usersgroups/commands/passwd/T.passwd 1        Failed

                Test Information:
        passwd -g : change the password of the named group 14-1
        Expected specified group's password to change.
        group passwd did not change.


************************************************************************  

PPS
	Where can I find lsb-compatible sources?

THX,YP

Mr. Yaroslav Popovitch yp@bestlinux.net - tel. +372 6419975
SOT Finnish Software Engineering Ltd.   - fax  +372 6419975
Kreutzwaldi 7-4, 10124  TALLINN         - http://www.sot.com/
ESTONIA                                 - http://bestlinux.net/



-- 
To UNSUBSCRIBE, email to lsb-test-request@lists.linuxbase.org
with subject of "unsubscribe". Trouble? Email listmaster@lists.linuxbase.org



Reply to: