SMTP host rejected one or more addresses.
These two messages indicate that the SMTP host has anti-spam measures installed and you are violating the rules
set up by the SMTP host's administrator. In most cases, the problem is caused by third-party relay, or
trying to send email from Domain A to Domain B using Domain C as a relay agent. This is similar to asking
Federal Express to deliver your UPS package. An email address that lives at the same domain as the SMTP host
is called a local address. An email address elsewhere is called a foreign address.
For example, if your SMTP host is mailhost.jetsons.com and you are trying to send email from firstname.lastname@example.org
to email@example.com, the SMTP host will probably reject the email because neither flintstones.com nor hobbiton.gov
are local to jetsons.com. Most SMTP hosts require that the email either be from someone local or to someone local, or both.
You can encounter this problem unexpectedly if you are allowing visitors to specify their own email addresses on
your form. If most of your visitors are local, the form will work for them; however, when someone stops by whose
email address is foreign, the server will not allow the email.
The best solution is to ensure that the recipient (the MAILTO address specified in your HTML form) is local to the
SMTP host. This way, no matter what email address the visitor enters as the EMAIL field (used for the MAIL FROM command when
Comments talks to the SMTP host), at least one of the addresses will be local, and the SMTP server will allow the email.
In some cases, this is insufficient because the SMTP host may maintain a "blacklist," or list of domains from which
it will not accept email at all. If the visitor specifies an address in a domain that is blacklisted, the SMTPHost
will reject the email even if the recipient is local. In these cases, you must change the HTML form so that the
visitor cannot specify the EMAIL field. For example, if your form current has
Your Email Address: <input type=text name=email>
you can change it to
Your Email Address: <input type=text name=visitoremail>
<input type=hidden name=email value="firstname.lastname@example.org">
This forces Comments to use email@example.com as the email address used for the MAIL FROM when talking to the
SMTP host, but still allows the visitor to give you an email address. The drawback to this method is that the
recipient will not be able to reply to the email and have it go to the visitor. Since the sender's address will always
be what you have specified in the hidden email field, a reply will always go to that address. The recipient will have to scan
the email to find what the visitor specified for the visitoremail field and manually reply to that address instead.
The last solution is to reconfigure the SMTP host to allow mail from anywhere to anywhere. This is not a good option
because it leaves the SMTP host open to hijackers for sending spam. Most SMTP host administrators will not allow
this, with very good reason. SMTP hosts that allow third-party relay quickly get added to blacklists around the world.
N.B. You may also encounter this problem if you are letting the visitor specify the EMAIL field, but the visitor supplies
an address like aaa or sdjfjdfj@sfjdjff (i.e., a nonsense address). Most SMTP hosts treat incomplete or
invalid email addresses as errors. The comments.log file will show the SMTP host's response in these cases.