<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Password expiry in a trusted system in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/password-expiry-in-a-trusted-system/m-p/3403744#M201343</link>
    <description>Hello all,&lt;BR /&gt;&lt;BR /&gt;We have nearly 60 HP UX (Trusted 11.x) systems and according to the policy the password expires after 60 days.&lt;BR /&gt;&lt;BR /&gt;Now my aim is to automate the notifying users when the passwords are near to expiry.&lt;BR /&gt;&lt;BR /&gt;Any thoughts on this...Like a script.&lt;BR /&gt;&lt;BR /&gt;Thanks in advance,&lt;BR /&gt;Amruth</description>
    <pubDate>Tue, 19 Oct 2004 19:01:10 GMT</pubDate>
    <dc:creator>Amruth</dc:creator>
    <dc:date>2004-10-19T19:01:10Z</dc:date>
    <item>
      <title>Password expiry in a trusted system</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/password-expiry-in-a-trusted-system/m-p/3403744#M201343</link>
      <description>Hello all,&lt;BR /&gt;&lt;BR /&gt;We have nearly 60 HP UX (Trusted 11.x) systems and according to the policy the password expires after 60 days.&lt;BR /&gt;&lt;BR /&gt;Now my aim is to automate the notifying users when the passwords are near to expiry.&lt;BR /&gt;&lt;BR /&gt;Any thoughts on this...Like a script.&lt;BR /&gt;&lt;BR /&gt;Thanks in advance,&lt;BR /&gt;Amruth</description>
      <pubDate>Tue, 19 Oct 2004 19:01:10 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/password-expiry-in-a-trusted-system/m-p/3403744#M201343</guid>
      <dc:creator>Amruth</dc:creator>
      <dc:date>2004-10-19T19:01:10Z</dc:date>
    </item>
    <item>
      <title>Re: Password expiry in a trusted system</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/password-expiry-in-a-trusted-system/m-p/3403745#M201344</link>
      <description>Hi Amruth,&lt;BR /&gt;&lt;BR /&gt;You can configure the systems with expiry warning time so a message will be displayed beyond that time for the users. However, there is no way a user will know if he/she doesn't logon to the system. &lt;BR /&gt;&lt;BR /&gt;I started implementing it but haven't done yet due to our site policies.&lt;BR /&gt;&lt;BR /&gt;My idea was to&lt;BR /&gt;&lt;BR /&gt;1. Create a file say /etc/expirytab every day night at 12:00 AM. It's a comma seperated file with user, date of the last password change, date of expiry and days left before password expiry.&lt;BR /&gt;&lt;BR /&gt;2. Run a script 'script2' that will send mails to users based on the 'days left before password expiry in /etc/expirytab file.&lt;BR /&gt;&lt;BR /&gt;As you can see writing the script for 2 is very easy. So, I leave it to you.&lt;BR /&gt;&lt;BR /&gt;For getting the expiry information, here is the script. You may need to add some checks like if the user file is not there etc., etc. otherwise 'awk' will hang.&lt;BR /&gt;&lt;BR /&gt;#!/usr/bin/ksh&lt;BR /&gt;&lt;BR /&gt;EXPIRE=60&lt;BR /&gt;NOW=$(/usr/contrib/bin/perl -e 'printf "%d\n",time()')&lt;BR /&gt;&lt;BR /&gt;if [ ! -d /tcb ]&lt;BR /&gt;then&lt;BR /&gt;echo "Only on trusted systems"&lt;BR /&gt;exit 1&lt;BR /&gt;fi&lt;BR /&gt;&lt;BR /&gt;rm -f /etc/expiry.tab&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;for USER in $(logins|awk '{print $1}')&lt;BR /&gt;do&lt;BR /&gt;FIRST=`echo $USER|cut -c1`&lt;BR /&gt;USERFILE="/tcb/files/auth/${FIRST}/${USER}"&lt;BR /&gt;THEN=$(awk '/u_succhg/ {FS="u_succhg";print $2}' $USERFILE | awk '{FS=":";print $1}'|sed '&lt;BR /&gt;s/#//')&lt;BR /&gt;WHEN_CHANGED=$(echo 0d${THEN}=Y | adb)&lt;BR /&gt;&lt;BR /&gt;(( EXPIRES_ON_DATE = $THEN + ( $EXPIRE * 86400 ) ))&lt;BR /&gt;(( EXPIRES_IN_DAYS = ( $EXPIRES_ON_DATE - $NOW ) / 86400 ))&lt;BR /&gt;&lt;BR /&gt;EXPIRES_ON_DATE=$(echo 0d${EXPIRES_ON_DATE}=Y |adb)&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;echo "$USER,$WHEN_CHANGED,$EXPIRES_ON_DATE,$EXPIRES_IN_DAYS" &amp;gt;&amp;gt; /etc/expirytab&lt;BR /&gt;done&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;-Sri</description>
      <pubDate>Tue, 19 Oct 2004 19:14:30 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/password-expiry-in-a-trusted-system/m-p/3403745#M201344</guid>
      <dc:creator>Sridhar Bhaskarla</dc:creator>
      <dc:date>2004-10-19T19:14:30Z</dc:date>
    </item>
    <item>
      <title>Re: Password expiry in a trusted system</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/password-expiry-in-a-trusted-system/m-p/3403746#M201345</link>
      <description>Sorry.. I couldn't help you.</description>
      <pubDate>Tue, 19 Oct 2004 19:27:00 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/password-expiry-in-a-trusted-system/m-p/3403746#M201345</guid>
      <dc:creator>Sridhar Bhaskarla</dc:creator>
      <dc:date>2004-10-19T19:27:00Z</dc:date>
    </item>
    <item>
      <title>Re: Password expiry in a trusted system</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/password-expiry-in-a-trusted-system/m-p/3403747#M201346</link>
      <description>Sri,&lt;BR /&gt;&lt;BR /&gt;THanks for your quick answer.&lt;BR /&gt;&lt;BR /&gt;My first problem is to find out when the password of a user will expire.&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;AM&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 19 Oct 2004 19:29:15 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/password-expiry-in-a-trusted-system/m-p/3403747#M201346</guid>
      <dc:creator>Amruth</dc:creator>
      <dc:date>2004-10-19T19:29:15Z</dc:date>
    </item>
    <item>
      <title>Re: Password expiry in a trusted system</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/password-expiry-in-a-trusted-system/m-p/3403748#M201347</link>
      <description>When you run the script, it will create a file /etc/expirytab with all those details. Run the script every night to update it. Once you have all the details, you can do anything you want.&lt;BR /&gt;&lt;BR /&gt;-Sri&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 19 Oct 2004 19:36:48 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/password-expiry-in-a-trusted-system/m-p/3403748#M201347</guid>
      <dc:creator>Sridhar Bhaskarla</dc:creator>
      <dc:date>2004-10-19T19:36:48Z</dc:date>
    </item>
    <item>
      <title>Re: Password expiry in a trusted system</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/password-expiry-in-a-trusted-system/m-p/3403749#M201348</link>
      <description>Sri,&lt;BR /&gt;&lt;BR /&gt;I am gonna check this out and will get back to you...&lt;BR /&gt;&lt;BR /&gt;Thanks a lot..&lt;BR /&gt;&lt;BR /&gt;AM</description>
      <pubDate>Tue, 19 Oct 2004 20:03:26 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/password-expiry-in-a-trusted-system/m-p/3403749#M201348</guid>
      <dc:creator>Amruth</dc:creator>
      <dc:date>2004-10-19T20:03:26Z</dc:date>
    </item>
  </channel>
</rss>

