[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[K12OSN] parse from shell comand



How can I make a script that would parse a line in the passwd file to 
return the full name of a user instead of outputting the entire line?

purpose: I have logins logged and it sends the login name to a log and it 
uses the %U (logins via samba to a samba PDC) in the log.  To my knowlege, 
there is no way to make it return the full name so I want to take the %U 
and run it through grep or something so it takes the username, finds it in 
/etc/passwd and returns the full name to be entered into the log instead 
of the username.

Cornfussed, yet?

Thanks!

Doug Simpson
Technology Specialist
DeQueen Public Schools
DeQueen, AR 71832
simpsond leopards k12 ar us
Tux for President!


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]