- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: Change all users password (trusted system)
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
тАО08-28-2003 12:58 AM
тАО08-28-2003 12:58 AM
How can i change all the users password from a list of users in a trusted system.
Have you a script who can do it.
Best regards,
Mansour.
Solved! Go to Solution.
- Tags:
- Password
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-28-2003 01:19 AM
тАО08-28-2003 01:19 AM
Re: Change all users password (trusted system)
# /usr/lbin/tsconvert -r
# /usr/lbin/tsconvert
All passwords will expire for all accounts and then all users will be asked to change their passwords. Either that or you would have to write an expect script to do it.
Is this what your after ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-28-2003 01:25 AM
тАО08-28-2003 01:25 AM
SolutionYou can easily write a script to do it on all users, eg;
for i in $(cat
- )
do
modprpw .... $i
done
where
- is a file with a list of all your usernames to change.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-28-2003 05:06 AM
тАО08-28-2003 05:06 AM
Re: Change all users password (trusted system)
i think that the modprpw cde could help me.
Best regards,
Mansour.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-28-2003 05:54 AM
тАО08-28-2003 05:54 AM
Re: Change all users password (trusted system)
Can you give the option of modprpw to change a password in a trusted system or can you help to do the script with a file (username:passwd)
Thanks,
Mansour.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-28-2003 06:04 AM
тАО08-28-2003 06:04 AM
Re: Change all users password (trusted system)
It can run the modprpw command pretty easily.
Attached
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
тАО08-28-2003 07:19 AM
тАО08-28-2003 07:19 AM
Re: Change all users password (trusted system)
for i in `cat new_ids`
do
echo "--- Processing: "$i
export USERID=$i
init_pwd.exp
done
contents of init_pwd.exp
set timeout 10
spawn passwd "$env(USERID)"
expect "*sword:"
send "rogers1a\r"
expect "*sword:"
send "rogers1a\r"
expect "#"
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-04-2003 01:03 AM
тАО09-04-2003 01:03 AM
Re: Change all users password (trusted system)
Here is what i want and i've got.
Thanks for all your solutions, it's work.
#! /bin/ksh
cat /rpt1/userfile | while read line
do
first=$(echo $line|awk -F: '{print substr($1,1,1)}')
S1=/tcb/files/auth/
S2=$(echo $line|awk -F: '{print $1}')
S3=$(echo $line|awk -F: '{print $2}')
S4=$(grep u_pwd $S1$first/$S2 | awk -F: '{print substr($2,7,2)}')
/usr/sam/lbin/usermod.sam -p `echo "$S3$S4" | /usr/lbin/makekey` $S2
done
- Tags:
- makekey
- usermod.sam