
9th June 2006, 06:16
|
|
Junior Member
|
|
Join Date: Mar 2006
Posts: 8
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Running SMTP on multiple ports (postfix)
Hello all;
As with most large ISP's, my ISP filters port 25 (SMTP). As a web hosting provider, I felt that my customers should be able to use my email server to send email, as well as receive it. It's kind of a value added feature
So, here's how I did it:
Open /etc/postfix/master.cf and add the following line:
Code:
587 inet n - n - - smtpd
This is for postfix only. Restart postfix and your done. This doesn't really have anything to do with ISPConfig, however maybe it should be an option...?
EDIT: I forgot to tell you, SMTP will listen on ports 25 and 587
Last edited by eKg; 12th June 2006 at 07:04.
|

31st July 2006, 17:10
|
|
Member
|
|
Join Date: Dec 2005
Posts: 52
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
This is a great solution but when i try to send an email using 587 port, no auth is required and the server become an open relay.
Any idea?
|

1st August 2006, 14:02
|
|
Super Moderator
|
|
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 31,853
Thanks: 781
Thanked 1,558 Times in 1,477 Posts
|
|
|

2nd August 2006, 18:52
|
|
Member
|
|
Join Date: Dec 2005
Posts: 52
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Yes, i tried to send a email from my network.
Running telnet localhost 587 this is the output:
debian:/etc/postfix# telnet localhost 587
Trying 127.0.0.1...
Connected to localhost.localdomain.
Escape character is '^]'.
220 debian.domain.tld ESMTP Postfix (Debian/GNU)
ehlo localhost
250-debian.domain.tld
250-PIPELINING
250-SIZE 10240000
250-VRFY
250-ETRN
250-STARTTLS
250-AUTH LOGIN PLAIN
250-AUTH=LOGIN PLAIN
250 8BITMIME
quit
221 Bye
Connection closed by foreign host.
|

3rd August 2006, 09:21
|
|
Member
|
|
Join Date: Dec 2005
Posts: 52
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
I tried to use this tip from a remote pc with an outside ip but it doesn't work.
When I send an email, i can't authenticate me using port 587.
|

3rd August 2006, 16:59
|
|
Super Moderator
|
|
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 31,853
Thanks: 781
Thanked 1,558 Times in 1,477 Posts
|
|
Quote:
|
Originally Posted by alex916
Running telnet localhost 587 this is the output:
debian:/etc/postfix# telnet localhost 587
Trying 127.0.0.1...
Connected to localhost.localdomain.
Escape character is '^]'.
220 debian.domain.tld ESMTP Postfix (Debian/GNU)
ehlo localhost
250-debian.domain.tld
250-PIPELINING
250-SIZE 10240000
250-VRFY
250-ETRN
250-STARTTLS
250-AUTH LOGIN PLAIN
250-AUTH=LOGIN PLAIN
250 8BITMIME
quit
221 Bye
Connection closed by foreign host.
|
Looks fine.
Quote:
I tried to use this tip from a remote pc with an outside ip but it doesn't work.
When I send an email, i can't authenticate me using port 587.
|
What's the exact error message? What's in the mail log? Did you enable "Server requires authentication." in your email client?
|

3rd August 2006, 18:05
|
|
Member
|
|
Join Date: Dec 2005
Posts: 52
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Looking mail.log, when i use port 587, i have this error:
Aug 3 16:14:58 debian postfix/smtpd[3759]: connect from unknown[192.168.0.4]
Aug 3 16:14:58 debian postfix/smtpd[3759]: warning: SASL authentication failure: cannot connect to saslauthd server: No such file or directory
Aug 3 16:14:58 debian postfix/smtpd[3759]: warning: unknown[192.168.0.4]: SASL LOGIN authentication failed
Aug 3 16:14:58 debian postfix/smtpd[3759]: lost connection after AUTH from unknown[192.168.0.4]
Aug 3 16:14:58 debian postfix/smtpd[3759]: disconnect from unknown[192.168.0.4]
Thanks Falko
|

4th August 2006, 13:50
|
|
Super Moderator
|
|
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 31,853
Thanks: 781
Thanked 1,558 Times in 1,477 Posts
|
|
Is saslauthd running? What's the output of
Code:
ps aux|grep saslauthd
?
What's in /etc/postfix/master.cf?
|

4th August 2006, 14:19
|
|
Member
|
|
Join Date: Dec 2005
Posts: 52
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Code:
debian:~# ps aux|grep saslauthd
root 1805 0.0 0.6 6556 1580 ? Ss Jul20 0:00 /usr/sbin/saslauthd -m /var/spool/postfix/var/run/saslauthd -a pam
root 1806 0.0 0.7 6664 1928 ? S Jul20 0:00 /usr/sbin/saslauthd -m /var/spool/postfix/var/run/saslauthd -a pam
root 1807 0.0 0.7 6664 1928 ? S Jul20 0:00 /usr/sbin/saslauthd -m /var/spool/postfix/var/run/saslauthd -a pam
root 1808 0.0 0.7 6664 1928 ? S Jul20 0:00 /usr/sbin/saslauthd -m /var/spool/postfix/var/run/saslauthd -a pam
root 1809 0.0 0.6 6556 1580 ? S Jul20 0:00 /usr/sbin/saslauthd -m /var/spool/postfix/var/run/saslauthd -a pam
root 22604 0.0 0.3 2048 780 pts/0 S+ 12:26 0:00 grep saslauthd
And Master.cf
Code:
#=========================================================
# service type private unpriv chroot wakeup maxproc command + args
# (yes) (yes) (yes) (never) (100)
#========================================================
smtp inet n - - - - smtpd
#submission inet n - - - - smtpd
# -o smtpd_etrn_restrictions=reject
#628 inet n - - - - qmqpd
pickup fifo n - - 60 1 pickup
cleanup unix n - - - 0 cleanup
qmgr fifo n - - 300 1 qmgr
#qmgr fifo n - - 300 1 oqmgr
rewrite unix - - - - - trivial-rewrite
bounce unix - - - - 0 bounce
defer unix - - - - 0 bounce
trace unix - - - - 0 bounce
verify unix - - - - 1 verify
flush unix n - - 1000? 0 flush
proxymap unix - - n - - proxymap
smtp unix - - - - - smtp
relay unix - - - - - smtp
# -o smtp_helo_timeout=5 -o smtp_connect_timeout=5
showq unix n - - - - showq
error unix - - - - - error
local unix - n n - - local
virtual unix - n n - - virtual
lmtp unix - - n - - lmtp
anvil unix - - n - 1 anvil
#
# Interfaces to non-Postfix software. Be sure to examine the manual
# pages of the non-Postfix software to find out what options it wants.
#
# maildrop. See the Postfix MAILDROP_README file for details.
#
maildrop unix - n n - - pipe
flags=DRhu user=vmail argv=/usr/local/bin/maildrop -d ${recipient}
uucp unix - n n - - pipe
flags=Fqhu user=uucp argv=uux -r -n -z -a$sender - $nexthop!rmail ($recipient)
ifmail unix - n n - - pipe
flags=F user=ftn argv=/usr/lib/ifmail/ifmail -r $nexthop ($recipient)
bsmtp unix - n n - - pipe
flags=Fq. user=bsmtp argv=/usr/lib/bsmtp/bsmtp -d -t$nexthop -f$sender $recipient
scalemail-backend unix - n n - 2 pipe
flags=R user=scalemail argv=/usr/lib/scalemail/bin/scalemail-store ${nexthop} ${user} ${extension}
# only used by postfix-tls
#tlsmgr fifo - - n 300 1 tlsmgr
#smtps inet n - n - - smtpd -o smtpd_tls_wrappermode=yes -o smtpd_sasl_auth_enable=yes
#587 inet n - n - - smtpd -o smtpd_enforce_tls=yes -o smtpd_sasl_auth_enable=yes
587 inet n - n - - smtpd
The problem occurs only when i try to use like smtp port 587.
Using 25 it's all ok.
|

5th August 2006, 17:42
|
|
Super Moderator
|
|
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 31,853
Thanks: 781
Thanked 1,558 Times in 1,477 Posts
|
|
Change this line:
Code:
587 inet n - n - - smtpd
to
Code:
587 inet n - - - - smtpd
in /etc/postfix/master.cf and restart Postfix.
|
|
The Following User Says Thank You to falko For This Useful Post:
|
tensor (14th January 2008)
|
| Thread Tools |
|
|
| Display Modes |
Linear Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT +2. The time now is 15:48.
|
Recent comments
2 hours 11 min ago
7 hours 59 min ago
9 hours 51 min ago
11 hours 35 min ago
15 hours 26 min ago
21 hours 11 min ago
21 hours 22 min ago
1 day 1 hour ago
1 day 7 hours ago
1 day 12 hours ago