LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 10-20-2005, 09:09 AM   #1
syrotkin
LQ Newbie
 
Registered: Oct 2005
Posts: 2

Rep: Reputation: 0
find out email address from username


hello,

I am trying to generate a mailing list using the /etc/passwd file, going through the list of users, and appending @foo or @bar to the usernames. The problem is that I don't know how to find out what string I need to append because the users may have their email addresses on different servers.
Maybe there is a command that lets you find out a user's email address if you know their username (finger does not do that, it just gives the person's name)

thank you
 
Old 10-20-2005, 01:21 PM   #2
fouldsy
Senior Member
 
Registered: Jan 2002
Location: St Louis, MO
Distribution: Ubuntu
Posts: 1,284

Rep: Reputation: 47
You could script it so it grabs the hostname of the server connected to and appends this to the end of the usernames found in whatever location the login data is stored depending on authentication method. Don't know anything that holds the whole e-mail address for individual users like a global mail address book for local systems. A quick script would do it though.
 
Old 10-20-2005, 04:32 PM   #3
syrotkin
LQ Newbie
 
Registered: Oct 2005
Posts: 2

Original Poster
Rep: Reputation: 0
mm yeah, the problem is I don't know the name of the server it is connected to. Let's say I am searching in the /etc/passwd file of the server aaa, and the users listed in the file have their email addresses @bbb or @ccc, and I don't know which of the two it is.
 
  


Reply



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
How to find an IP address from the MAC address of a remote machine ? jitz Linux - General 3 01-03-2006 07:55 AM
( C++ ) - How to find username? igor@44 Linux - General 7 08-03-2005 02:11 PM
Creating A Second Email Address For Email Account On Sendmail treedstang Linux - Software 1 04-27-2004 10:31 PM
command prompt - username@mac address? ryedunn Linux - Newbie 5 03-16-2004 07:55 AM
sending an email to a email address after a perl operation meluser Programming 9 04-07-2003 01:26 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 07:49 PM.

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
Open Source Consulting | Domain Registration