[vexim] Mail Failure Generated When Adding Relay Domain
Harald Reitbauer - Earth Internet Service
harald at earth.co.zw
Thu Apr 17 12:58:17 PDT 2008
Dear Gordon!
I admire your help to people and would like to be as good as you to help as much as you do, unfortunatle I have started lat with learning on Linux Unix systems.
However I have started a small ISP business and we changed from a old FreeBSD to a newer version of it.
After installing the newer version (I use vexim to log in and out people) I am not able to make a difference in email and Internet accounts, yet I can enable and disable it in Vexim. Any idea where I might have to look.
Thanks for help,
HR
-----Original Message-----
From: vexim-bounces at silverwraith.com [mailto:vexim-bounces at silverwraith.com] On Behalf Of Gordon Dickens
Sent: Donnerstag, 17. April 2008 20:23
To: vexim at silverwraith.com
Subject: Re: [vexim] Mail Failure Generated When Adding Relay Domain
On 4/13/2008 8:15 AM, Gordon Dickens wrote:
> Every time that I add a relay domain in Vexim then Vexim generates a
> welcome email that always fails because the welcome email's addressee
> ( rcpt to: ) has a blank local part such as: @relaydomain.com. Is this
> a known bug in Vexim or have I mis-configured Vexim?
Hello Everybody,
I figured out the problem with the welcome message being erroneously
generated for relay domains. I don't know what version of Vexim that
ya'll are running but this is definitely a bug in the version that I am
running which is Vexim 2.2.1. The bug is in the siteaddsubmit.php
module. I have fixed the php code and I will offer my fix below for the
benefit of others that may have already experienced this bug or that may
encounter this in the future.
I hope that you find this helpful. I also recommend that Avleen
consider including this fix in any future Vexim 2.x releases.
FYI,
Gordon
Here is the fix:
Near the bottom of the siteaddsubmit.php module you will find the
following code:
} else {
header ("Location: site.php?added={$_POST['domain']}" .
"&type={$_POST['type']}");
$_SESSION['domain'] = $_POST['domain'];
mail("{$_POST['localpart']}@{$_POST['domain']}",
"Welcome Domain Admin!",
"$welcome_newdomain",
"From: {$_POST['localpart']}@{$_POST['domain']}\r\n");
die;
}
} else {
header ("Location: site.php?failaddeddomerr={$_POST['domain']}");
die;
}
} else if ($_POST['type'] == "alias") {
The code that needs modifying from the above is:
} else {
header ("Location: site.php?added={$_POST['domain']}" .
"&type={$_POST['type']}");
$_SESSION['domain'] = $_POST['domain'];
mail("{$_POST['localpart']}@{$_POST['domain']}",
"Welcome Domain Admin!",
"$welcome_newdomain",
"From: {$_POST['localpart']}@{$_POST['domain']}\r\n");
die;
You can simply comment this code out to stop the erroneous welcome
message for relay domains as follows:
/*
} else {
header ("Location: site.php?added={$_POST['domain']}" .
"&type={$_POST['type']}");
$_SESSION['domain'] = $_POST['domain'];
mail("{$_POST['localpart']}@{$_POST['domain']}",
"Welcome Domain Admin!",
"$welcome_newdomain",
"From: {$_POST['localpart']}@{$_POST['domain']}\r\n");
die;
*/
Alternatively, you can put something like this in to notify the
postmaster at the domain for which you are relaying:
/* GLD fix: For bug in relay welcome message to blank local part. email
to: postmaster@ <relay-to-domain> */
/* mail("{$_POST['localpart']}@{$_POST['domain']}", GLD removed
this */
mail("postmaster@{$_POST['domain']}",
"Welcome Domain Admin!",
"$welcome_newdomain");
/* "From: {$_POST['localpart']}@{$_POST['domain']}\r\n");
GLD removed this */
/* GLD fix: email from: apache@<relay from domain> */
die;
}
} else {
header ("Location: site.php?failaddeddomerr={$_POST['domain']}");
die;
}
_______________________________________________
Vexim mailing list
Vexim at silverwraith.com
http://silverwraith.com/mailman/listinfo/vexim
Internal Virus Database is out-of-date.
Checked by AVG Free Edition.
Version: 7.5.516 / Virus Database: 269.22.8/1362 - Release Date: 06.04.2008 11:12
Internal Virus Database is out-of-date.
Checked by AVG Free Edition.
Version: 7.5.516 / Virus Database: 269.22.8/1362 - Release Date: 06.04.2008 11:12
More information about the Vexim
mailing list