spam to "non-existant" addresses on a server

Fight back! So don't expect to find lame "fake login screens" or similar stuff here.
Post Reply
User avatar
bad_brain
Site Owner
Site Owner
Posts: 11636
Joined: 06 Apr 2005, 16:00
19
Location: In your eye floaters.
Contact:

spam to "non-existant" addresses on a server

Post by bad_brain »

some days ago I got a little suprise in the morning when I had 6000 bounced emails in my inbox, all to webmaster@suck-o.com. first I was a little confused because I have never set up that address, but then I found the solution very quick in /etc/aliases
in this file the aliases are set, for example if you want to forward all internal mails to root to your email account:

Code: Select all

root: my@address.com
this example is very useful because you will be informed about errors and problems in the system.
but in my case this entry lead to the problem:

Code: Select all

webmaster: root
so: webmaster mails are forwarded to root and the 1st entry forwards the root ones to my email address.

so make sure to remove unneeded entries in /etc/aliases.

but there is also a 2nd option to forward mails, by using a file named .forward , it is placed in the user's home directory, for the root-user it would be /root/.forward
in this file you simply enter the email address you want the mails for the user want to be forwarded to. so in case you find no entry in /etc/aliases check .forward , make sure to use the -a switch for the ls command because the . makes it a hidden file.

:wink:

Post Reply