(forw) Bug#317012: [Pkg-shadow-devel] Processed: Bug#316089: chage fails if plain passwd in use

Alexander Gattin arg@online.com.ua
Wed, 06 Jul 2005 16:39:30 +0300


Hi!

On Wed, 6 Jul 2005 06:32:09 +0200 Christian Perrier 
<bubulle@debian.org> wrote:
> Marc, for your information..... Do you agree with 
> Alexander's suggestion below?
> 
> ----- Forwarded message from Alexander Gattin
...
> I propose to use `useradd -O PASS_MAX_DAYS=99999`
> instead and from my side going to update useradd's
> manpage (see bug #304934).

We should consider the following things:
1. depending on -O will require versioned "depends:"
2. depending on "special" chage exitcode will result in
    the same
3. there are actually 3rd way out:
    you just should check whether /etc/shadow exists,
    and if no, chage will surely fail, because pwd ageing
    information is contained in shadow only, not in 
passwd.

    This also means that you should not worry about pwd
    ageing when adding a user on non-shadow system ;)

-- 
WBR,
xrgtn