LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Enterprise Linux Forums > Linux - Enterprise
User Name
Password
Linux - Enterprise This forum is for all items relating to using Linux in the Enterprise.

Notices


Reply
  Search this Thread
Old 12-04-2006, 02:18 PM   #1
carlosinfl
Senior Member
 
Registered: May 2004
Location: Orlando, FL
Distribution: Arch
Posts: 2,905

Rep: Reputation: 77
How To Forward Mail & Account Question?


I am on out RHEL4 mail server and I wanted to forward someones mail from their account to mine. I have not disabled their account but I have set a strong password only I know. Should I do anything else to their account for security?

I was also told that if I change to their home directory and create a file called ".forward", in that text file, I need to add my email address only so it will then forward all this users mail to the email address in the text file.

Is this correct or not?
 
Old 12-04-2006, 02:25 PM   #2
msound
Member
 
Registered: Jun 2003
Location: SoCal
Distribution: CentOS
Posts: 465

Rep: Reputation: 30
i would just edit the aliases file to have
there-email@yourdomain.com just act as an alias for your mail name.
 
Old 12-04-2006, 02:25 PM   #3
fordeck
Member
 
Registered: Oct 2006
Location: Utah
Posts: 520

Rep: Reputation: 61
Do you know what mail server your using (i.e. sendmail, postfix, qmail etc.)?
 
Old 12-04-2006, 02:32 PM   #4
carlosinfl
Senior Member
 
Registered: May 2004
Location: Orlando, FL
Distribution: Arch
Posts: 2,905

Original Poster
Rep: Reputation: 77
Quote:
Originally Posted by msound
i would just edit the aliases file to have
there-email@yourdomain.com just act as an alias for your mail name.
Where is the "alias" file you said I have to edit?

Quote:
Do you know what mail server your using (i.e. sendmail, postfix, qmail etc.)?
Postfix mail server and dovcott.

Last edited by carlosinfl; 12-04-2006 at 02:33 PM.
 
Old 12-04-2006, 02:37 PM   #5
fordeck
Member
 
Registered: Oct 2006
Location: Utah
Posts: 520

Rep: Reputation: 61
You can find the aliases file at /etc/aliases and you can see more about the syntax used by issuing the command "man aliases". The .forward file in the users home directory should work as well. Just test to make sure.


Edit...: I forgot to mention if you use the /etc/aliases file, after editing it you need to run the command "newaliases" to rebuild the aliaes.db file in order for it to work.

Last edited by fordeck; 12-04-2006 at 02:41 PM.
 
Old 12-04-2006, 03:05 PM   #6
carlosinfl
Senior Member
 
Registered: May 2004
Location: Orlando, FL
Distribution: Arch
Posts: 2,905

Original Poster
Rep: Reputation: 77
Thank you! I will just use the .forward text file if that does pretty much the same job. So do you recommend any other things I check on his account to keep it active for mail but so he can't login or do anything malicious?

I removed all ssh access to our mail server from outside of the LAN. I removed this user from the sudo/wheel group. I then reset his password to something strong only I know.
 
Old 12-04-2006, 04:00 PM   #7
fordeck
Member
 
Registered: Oct 2006
Location: Utah
Posts: 520

Rep: Reputation: 61
Depending on what type of sudo access this user's had. You may want to change all admin type passwords, check the /etc/aliases file to make sure he did not forward his mail to an outside address and keep an eye on your logs for failed login attemps.

By the way that's one advantage to using the aliases file, in that the user doesn't need to have an account on the machine. Say for example on your web site you may have the email address webmaster@your_domain.com. webmaster doesn't have an email account but by using the /etc/aliases file you can forward any incoming mail addressed to webmaster@your_domain.com to a valid users email account.

Regards,
Fordeck
 
  


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 make Sendmail forward all incoming mail to localhost port 26 (Domino mail) speedgelb Linux - Software 3 09-27-2013 10:18 AM
Postfix: Need to deliver all local mail to 1 account, then forward OneBinary Linux - Software 3 01-05-2006 04:49 PM
sendmail: not possible to pipe mail to programs using ~/.forward && /etc/mail/aliases fhd Linux - Networking 1 01-09-2005 06:05 PM
cant see .forward file in home directory >> mail forward/copy steve_babbage Linux - Newbie 0 03-02-2004 06:25 AM

LinuxQuestions.org > Forums > Enterprise Linux Forums > Linux - Enterprise

All times are GMT -5. The time now is 02:32 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
Open Source Consulting | Domain Registration