tru64-unix-managers (formerly alpha-osf-managers) (1994-2012)
 help / color / mirror / Atom feed
* SUMMARY: C2 and password lifetime expiring via CLI
@ 2002-04-15 22:50 John Losey
  0 siblings, 0 replies; only message in thread
From: John Losey @ 2002-04-15 22:50 UTC (permalink / raw)
  To: tru64-unix-managers

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: multipart/mixed; boundary="------_=_NextPart_001_01C1E4CF.F68159C0", Size: 5046 bytes --]

This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.

------_=_NextPart_001_01C1E4CF.F68159C0
Content-Type: text/plain;
	charset="iso-8859-1"

Many thanks for the quick replies...

I was reminded of the passwd_lifetime variable.  So for the tool, before it
calls 'passwd $USERNAME', it is now calling:
usermod -x passwd_lifetime=0 $USERNAME

Followed by "usermod -x passwd_lifetime=365" to reset it back to a 1 year
lifetime.

The subroutine looks something like this:
usermod -x passwd_lifetime=0 $USERNAME
passwd $USERNAME
usermod -x passwd_lifetime=365 -x administrative_lock_applied=0 $USERNAME

This got us around the errors:
Password not changed: password lifetime has passed.

John

-----Original Message-----
From: John Losey [mailto:JLosey@Solucient.com]
Sent: Monday, April 15, 2002 2:30 PM
To: Tru64 UNIX Managers Group (E-mail)
Subject: C2 and password lifetime expiring via CLI


We're running 4.0f with C2 enabled and some of our users have a password
lifetime of 1 year.  When the password lifetime expires, attempting to use
'passwd' to set the password will return with a message saying that "the
password lifetime has expired".  We've found that if we use 'dxaccounts' to
set a password for a user, we're then able to use 'passwd' for the user
again.
Is there a command line way to reset the password lifetime so that it isn't
expired so that we can use passwd on the accounts?
The only reason I'm asking is that we've written a wrapper script for our
Tech Support that allows them to change passwords for users and it uses
passwd to do this.  But for the users whose lifetime has expired, they have
to e-mail me and I set a bogus password with dxaccounts so that Tech Support
can use the tool that calls passwd.  I'd really like to be able to add a
menu option to their tool that would allow them to be able to do this on
their own.  But w/o knowing the CLI way of doing it, I can't script it.
Thanks, 
John 

------_=_NextPart_001_01C1E4CF.F68159C0
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV=3D"Content-Type" CONTENT=3D"text/html; =
charset=3Diso-8859-1">
<META NAME=3D"Generator" CONTENT=3D"MS Exchange Server version =
5.5.2653.12">
<TITLE>SUMMARY: C2 and password lifetime expiring via CLI</TITLE>
</HEAD>
<BODY>

<P><FONT SIZE=3D2>Many thanks for the quick replies...</FONT>
</P>

<P><FONT SIZE=3D2>I was reminded of the passwd_lifetime variable.&nbsp; =
So for the tool, before it calls 'passwd $USERNAME', it is now =
calling:</FONT></P>

<P><FONT SIZE=3D2>usermod -x passwd_lifetime=3D0 $USERNAME</FONT>
</P>

<P><FONT SIZE=3D2>Followed by &quot;usermod -x =
passwd_lifetime=3D365&quot; to reset it back to a 1 year =
lifetime.</FONT>
</P>

<P><FONT SIZE=3D2>The subroutine looks something like this:</FONT>
<BR><FONT SIZE=3D2>usermod -x passwd_lifetime=3D0 $USERNAME</FONT>
<BR><FONT SIZE=3D2>passwd $USERNAME</FONT>
<BR><FONT SIZE=3D2>usermod -x passwd_lifetime=3D365 -x =
administrative_lock_applied=3D0 $USERNAME</FONT>
</P>

<P><FONT SIZE=3D2>This got us around the errors:</FONT>
<BR><FONT SIZE=3D2>Password not changed: password lifetime has =
passed.</FONT>
</P>

<P><FONT SIZE=3D2>John</FONT>
</P>

<P><FONT SIZE=3D2>-----Original Message-----</FONT>
<BR><FONT SIZE=3D2>From: John Losey [<A =
HREF=3D"mailto:JLosey@Solucient.com">mailto:JLosey@Solucient.com</A>]</F=
ONT>
<BR><FONT SIZE=3D2>Sent: Monday, April 15, 2002 2:30 PM</FONT>
<BR><FONT SIZE=3D2>To: Tru64 UNIX Managers Group (E-mail)</FONT>
<BR><FONT SIZE=3D2>Subject: C2 and password lifetime expiring via =
CLI</FONT>
</P>
<BR>

<P><FONT SIZE=3D2>We're running 4.0f with C2 enabled and some of our =
users have a password lifetime of 1 year.&nbsp; When the password =
lifetime expires, attempting to use 'passwd' to set the password will =
return with a message saying that &quot;the password lifetime has =
expired&quot;.&nbsp; We've found that if we use 'dxaccounts' to set a =
password for a user, we're then able to use 'passwd' for the user =
again.</FONT></P>

<P><FONT SIZE=3D2>Is there a command line way to reset the password =
lifetime so that it isn't expired so that we can use passwd on the =
accounts?</FONT></P>

<P><FONT SIZE=3D2>The only reason I'm asking is that we've written a =
wrapper script for our Tech Support that allows them to change =
passwords for users and it uses passwd to do this.&nbsp; But for the =
users whose lifetime has expired, they have to e-mail me and I set a =
bogus password with dxaccounts so that Tech Support can use the tool =
that calls passwd.&nbsp; I'd really like to be able to add a menu =
option to their tool that would allow them to be able to do this on =
their own.&nbsp; But w/o knowing the CLI way of doing it, I can't =
script it.</FONT></P>

<P><FONT SIZE=3D2>Thanks, </FONT>
<BR><FONT SIZE=3D2>John </FONT>
</P>

</BODY>
</HTML>
------_=_NextPart_001_01C1E4CF.F68159C0--

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2002-04-15 22:50 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-04-15 22:50 SUMMARY: C2 and password lifetime expiring via CLI John Losey

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox