- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- change passwd using script
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
Discussions
Discussions
Forums
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
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
тАО12-17-2008 06:53 PM
тАО12-17-2008 06:53 PM
change passwd using script
I need to autogenerate complex passwords and change it for users, using a single shell script. not expect script.
can some pls share any script with me ?
thanks.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-17-2008 07:10 PM
тАО12-17-2008 07:10 PM
Re: change passwd using script
http://forums.itrc.hp.com/service/forums/questionanswer.do?threadId=1206959
http://forums.itrc.hp.com/service/forums/questionanswer.do?threadId=1282661
http://forums.itrc.hp.com/service/forums/questionanswer.do?threadId=1249875
http://forums.itrc.hp.com/service/forums/questionanswer.do?threadId=1025499
http://forums.itrc.hp.com/service/forums/questionanswer.do?threadId=813273
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-17-2008 07:11 PM
тАО12-17-2008 07:11 PM
Re: change passwd using script
What you're asking is not a generic, simple script, particularly if you're putting conditions on it such as no expect.
You can use perl with the Expect module to automate the password exchange or you could use /usr/sam/lbin/usermod.sam -p ${encrypted_passwd}.
I've written several scripts that use the perl Expect module; honestly never tried the usermod.sam but it should work.
The attached perl script will generate random passwords. You can keep at it until you find one you like...
$ ./gen_pwd
Password: 4dah9vuh
$ ./gen_pwd
Password: qud4tam5
Doug
------
Senior UNIX Admin
O'Leary Computers Inc
linkedin: http://www.linkedin.com/dkoleary
Resume: http://www.olearycomputers.com/resume.html
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-17-2008 07:28 PM
тАО12-17-2008 07:28 PM
Re: change passwd using script
perl will do, as its installed in all the servers, but Expect is not installed.
does expect module comes with Perl. if yes, perl script is ok for me. can u give me full script to generate and change passwd together ?
thanks.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-17-2008 09:15 PM
тАО12-17-2008 09:15 PM
Re: change passwd using script
If possible make you system trusted then when you or any user want to change the passwd he/she will get the choice to create auto generated passwd by system itself.
No need to right any script to change passwd.
Suraj