The UNIX and Linux Forums
>
Top Forums
>
UNIX for Dummies Questions & Answers
Replace password field using ed/sed
User Name
Remember Me?
Password
Google UNIX.COM
Forums
Portal
Register
Forum Rules
FAQ
Contribute
Members List
Arcade
Search
Today's Posts
Mark Forums Read
Thread
:
Replace password field using ed/sed
View Single Post in UNIX Forums - Click on the Thread or Permalink to View Entire Thread -->
#
4
(
permalink
)
04-27-2007
ghostdog74
Registered User
Join Date: Sep 2006
Posts: 1,543
Code:
awk -F ":" 'BEGIN{OFS = ":"} /youruser/{$2="*LK*"}{ print}' /etc/passwd
please use at own risk.
Last edited by ghostdog74; 04-27-2007 at
10:42 PM
.
ghostdog74
View Public Profile
Find all posts by ghostdog74