- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- locking user account after 3 failed attempts
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-12-2005 02:49 AM
09-12-2005 02:49 AM
locking user account after 3 failed attempts
Got a question for you all.
We like to lock user accounts after
three failed attempts to logon.
To convert from a untrusted system to a trusted system is a big risk for our core business applications. So if there's another way ..
We're on hp-ux 11i.
Thanks
Gea
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-12-2005 02:56 AM
09-12-2005 02:56 AM
Re: locking user account after 3 failed attempts
lastb
That ouput includes user names.
You can do this.
lastb | sort -u > list
while read -r username
badtry=$(lastb | grep -i $username | wc -l)
if [ $badtry -ge 3 ]
then
# passwd -l $username
fi
done < list
Run it as often as you want via cron.
Trusted system is better, but an iteration of the above code will work.
SEP
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-12-2005 03:23 AM
09-12-2005 03:23 AM
Re: locking user account after 3 failed attempts
SEP has a good idea but on a trusted system this count starts over again if there is a successful login.
In other words, I have 2 failed attempts to login. I succeed on 3rd try. On trusted system this count starts over again.
To work with the lastb file, if there is a successful login within 3 unsuccessful attempts, do not lock the account. Look for 3 unsuccessful attempts in a row.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-13-2005 12:01 AM
09-13-2005 12:01 AM
Re: locking user account after 3 failed attempts
the command /usr/lbin/modprpw -l -k "account" can help you getting back your password after going to trusted (which is quit simple)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-26-2005 08:21 PM
10-26-2005 08:21 PM
Re: locking user account after 3 failed attempts
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-26-2005 08:34 PM
10-26-2005 08:34 PM