Mail

Abhishek Reddy's picture

He has: 3,348 posts

Joined: Jul 2001

This is less a PHP question and more of a mail question, but I hope that the PHP folk might have experience with this problem.

I've got a form on a website that mails out the contents to a preset email address. It's pretty simple, using mail(). And it seems to send mail just fine. Trouble is, sometimes the mail isn't received. From my testing, I know that hotmail, yahoo, nzoomail, and other free inbox providers receive the mail correctly. But it doesn't reach any other inboxes, such as my own inbox in my domain.

I can't figure out exactly what the problem is. My first instincts tell me it's probably a spam/filtering problem. If it is, how would I fix it? I can see from the headers why spam blockers might think it's a bit dodgy... what would I have to do to correct them? Is there possibly any other cause for the inconsistency? Solutions? Ideas?

Smiling

Busy's picture

He has: 6,151 posts

Joined: May 2001

One of the spam crowds blocks a lot of webhosts, puts the server in a blacklist and this list gets spread around. forgot who it is, but should be able to find out who. you can try email your webhost to try ask them to remove their server but all it takes is one complaint from someone about someone on your set of servers and your back on it.
Also AOL has real stupid spam filters set up at the moment

Abhishek Reddy's picture

He has: 3,348 posts

Joined: Jul 2001

Blacklist may be an idea. I'll check up on that. Smiling

The mailer sends a mail only to the client's one email address, so I'm looking to defeat every spam filter in the planet. Just this one. But I suspect if I figure out how to get past this one, I'll break through most others.

How do spam filters work, anyway? I know there are many levels of "defence", but I can't pick out which one is causing this to be blocked. As I mentioned previously, I think it's the mis- (or un-) configured headers -- there's a nobody@localhost and a nobody@[domain] in the from field. Do filters expect anonymous server-generated mails with apparently spoofed headers to be spam? Or am I missing the point altogether?

Busy's picture

He has: 6,151 posts

Joined: May 2001

it was spamcop, here is a quote from them

Quote: SpamCop now implements "pre-emptive" blocking of hosts. This is based on non-SUBE points (mail volume) alone, and is not related to complaints. If a host has no mail volume within the past 7 days except for a 1 day or less period where it does show volume, it will be listed. For example, a host which has no more than 24 hours history for sending mail will be listed under the assumption that it is most likely a new source of spam (since the great majority of new sources of email are sources of spam). After 24 hours, we hope that users will have had a chance to report spam from the new host - or not. If they do, then the other rules will list the host. If they don't (and the host keeps sending mail), then it will drop off the blacklist.

and I believe if you put your ip on the end of this link you should be able to see if your blocked or not www.spamcop.net/w3m?action=checkblock&ip=

might also find this useful too http://www.ecommercetimes.com/perl/story/32009.html

Abhishek Reddy's picture

He has: 3,348 posts

Joined: Jul 2001

Well, the server is not blacklisted (*phew*) but I'll check with the host if he might be on any other BLs. Smiling

druagord's picture

He has: 335 posts

Joined: May 2003

did you check sendmail logs (or whatever your mailserver is) logs are the best friend of any mailserver admin Smiling

Abhishek Reddy's picture

He has: 3,348 posts

Joined: Jul 2001

As it happens, I admin very little on that site and server (not even the actual live site), so not much I can do to get my hands on the logs. What should I be looking for in the logs? Smiling

Mark Hensler's picture

He has: 4,048 posts

Joined: Aug 2000

Any sign of bounced mail, or other indication as to why the email didn't go through.

Abhishek Reddy's picture

He has: 3,348 posts

Joined: Jul 2001

No sign, afaik. The local inbox doesn't collect it as trash or spam, so best guess is that a server along the way blocked it. Sad

druagord's picture

He has: 335 posts

Joined: May 2003

Usually the server write in the logs the reson it didn't send the message. I would be looking first did the message got all the way to the server then if it did the reason why it didn't go any further.

IF , ELSE , WHILE isn't that what life is all about

Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.