LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 09-15-2003, 04:12 PM   #1
Linix
LQ Newbie
 
Registered: Aug 2003
Location: Wisconsin
Posts: 8

Rep: Reputation: 0
Searching username in a password file


How do i search for a username within a shadow password file? Many thanks in advance :-)
 
Old 09-15-2003, 04:38 PM   #2
MasterC
LQ Guru
 
Registered: Mar 2002
Location: Salt Lake City, UT - USA
Distribution: Gentoo ; LFS ; Kubuntu
Posts: 12,612

Rep: Reputation: 68
Not sure I follow, a quick glance over my /etc/shadow file definitely shows, in plain text, the usernames...

Cool
 
Old 09-15-2003, 05:01 PM   #3
Linix
LQ Newbie
 
Registered: Aug 2003
Location: Wisconsin
Posts: 8

Original Poster
Rep: Reputation: 0
Thanks for replying MasterC. Well the shadow file i'm dealing with has lots and lots of usernames. Ofcourse, I can go through each one of them and try to find the specific username but I figured that would be too much of a hassle. So I was wondering if there was any shortcut? I tried googling but nothing helpful came up.
 
Old 09-15-2003, 05:04 PM   #4
MasterC
LQ Guru
 
Registered: Mar 2002
Location: Salt Lake City, UT - USA
Distribution: Gentoo ; LFS ; Kubuntu
Posts: 12,612

Rep: Reputation: 68
Open up the file, in say, vim and type:
/username

This will search that file for 'username'.

HTH

Cool
 
Old 09-15-2003, 05:07 PM   #5
Linix
LQ Newbie
 
Registered: Aug 2003
Location: Wisconsin
Posts: 8

Original Poster
Rep: Reputation: 0
Thanks again MasterC. Would do :-)
 
Old 09-15-2003, 05:20 PM   #6
MasterC
LQ Guru
 
Registered: Mar 2002
Location: Salt Lake City, UT - USA
Distribution: Gentoo ; LFS ; Kubuntu
Posts: 12,612

Rep: Reputation: 68
Glad I could help

Cool
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
username and password no go bmd Linux - Newbie 7 04-06-2005 09:26 PM
username/password sailu_mvn Programming 5 12-21-2004 04:21 AM
UserName and Password luis8460 Red Hat 0 07-08-2004 05:45 AM
Username and Password dance2die Arch 3 09-01-2003 04:32 PM
File sharing: username and password setup dmg2206 Linux - Networking 2 03-04-2002 01:41 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 06:20 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration