Skip to main content

Outbound smtp blocked by 506e

More
16 years 6 months ago #26059 by cortezone
Hi,

I have a setup with an internal mail server accessible from outside. I'm able to receive mails on the server from outside but not able to send to the outside. I've turned off fixup smtp but that doesn't help. When I try telnet to port 25 I get teardown and tcp reset-0 in the log with 0 bytes in 0:00 secs. This clearly shows the packets aren't going anywhere beyond my outside interface.

Here's the config.

PIX Version 6.3(5)
interface ethernet0 10full
interface ethernet1 auto
nameif ethernet0 outside security0
nameif ethernet1 inside security100
enable password lallalallalal encrypted
passwd putupuptapu encrypted
hostname pixfirewall
domain-name ciscopix.com
fixup protocol dns maximum-length 512
fixup protocol ftp 21
fixup protocol h323 h225 1720
fixup protocol h323 ras 1718-1719
fixup protocol http 80
fixup protocol rsh 514
fixup protocol rtsp 554
fixup protocol sip 5060
fixup protocol sip udp 5060
fixup protocol skinny 2000
fixup protocol sqlnet 1521
fixup protocol tftp 69
names
name 192.168.1.254 VOICE_SERVER
name 10.1.2.10 MAIL_SERVER
object-group icmp-type icmp-grp
description ICMP Types allow into the FW
icmp-object echo-reply
icmp-object unreachable
icmp-object time-exceeded
object-group service media_tcp_ports tcp
port-object eq 32950
port-object eq www
port-object eq https
port-object range 5060 5063
port-object eq 554
port-object eq 1755
port-object eq smtp
object-group service media_udp_ports udp
port-object range 5060 5063
port-object range 10000 50000
object-group icmp-type ICMP-INBOUND
description Allowable inbound ICMP traffic
icmp-object echo-reply
icmp-object unreachable
icmp-object time-exceeded
object-group service PUBLIC-SERVER-TCP tcp
description Allowable inbound TCP traffic
port-object range ftp-data ftp
port-object eq smtp
port-object eq www
port-object range nntp nntp
port-object range pop3 pop3
port-object eq imap4
port-object range sqlnet 1526
port-object range 995 995
port-object eq ldaps
port-object eq pop3
port-object range imap4 imap4
port-object range 993 993
port-object eq https
port-object eq ldap
port-object eq sqlnet
port-object range 7777 7778
port-object eq 1810
port-object range 5222 5223
port-object range 1025 1026
port-object range 7340 7341
port-object range 7350 7351
port-object eq 7360
port-object eq 7370
port-object eq 5269
port-object eq 1027
port-object eq 3478
port-object eq 8250
port-object eq 6004
port-object eq 6102
port-object eq 6201
port-object eq 5730
port-object eq 9000
port-object eq 9300
port-object eq 9301
port-object eq 9302
access-list from-inside permit icmp 192.168.1.0 255.255.255.0 any
access-list from-inside permit ip 192.168.1.0 255.255.255.0 any
access-list from-inside permit tcp any any eq nntp
access-list from-inside permit tcp any any eq https
access-list from-inside permit tcp any host 55.30.17.158
access-list from-inside permit tcp host MAIL_SERVER any eq smtp log
access-list from-inside permit tcp any host 55.30.17.157
access-list INBOUND permit icmp any host 55.30.17.158 object-group ICMP-INBOUND
access-list INBOUND permit tcp any host 55.30.17.158 object-group PUBLIC-SERVER-TCP log
access-list INBOUND permit udp any host 55.30.17.158 object-group media_udp_ports
access-list INBOUND permit icmp any any

pager lines 25
logging on
logging timestamp
logging standby
logging monitor debugging
logging trap debugging
logging host inside 10.1.2.193
mtu outside 1500
mtu inside 1500
ip address outside 55.30.17.158 255.255.255.252
ip address inside 192.168.1.1 255.255.255.0
ip audit info action alarm
ip audit attack action alarm
ip local pool client_VPN 192.168.2.1-192.168.2.254
pdm location VOICE_SERVER 255.255.255.255 inside
pdm location 10.1.2.193 255.255.255.255 inside
pdm location MAIL_SERVER 255.255.255.255 inside
pdm logging informational 100
pdm history enable
arp timeout 14400
global (outside) 1 interface
nat (inside) 1 0.0.0.0 0.0.0.0 0 0
static (inside,outside) tcp interface smtp MAIL_SERVER smtp netmask 255.255.255.255 0 0
static (inside,outside) tcp interface https MAIL_SERVER https netmask 255.255.255.255 0 0
static (inside,outside) tcp interface pop3 MAIL_SERVER pop3 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface imap4 MAIL_SERVER imap4 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 7777 MAIL_SERVER 7777 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 7778 MAIL_SERVER 7778 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface ldap MAIL_SERVER ldap netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 993 MAIL_SERVER 993 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 995 MAIL_SERVER 995 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 5222 MAIL_SERVER 5222 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 5223 MAIL_SERVER 5223 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 1026 MAIL_SERVER 1026 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 1025 MAIL_SERVER 1025 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 1027 MAIL_SERVER 1027 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 7340 MAIL_SERVER 7340 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 7341 MAIL_SERVER 7341 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 7350 MAIL_SERVER 7350 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 7351 MAIL_SERVER 7351 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 7370 MAIL_SERVER 7370 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 5269 MAIL_SERVER 5269 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 7360 MAIL_SERVER 7360 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 3478 MAIL_SERVER 3478 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 4443 MAIL_SERVER 4443 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 4444 MAIL_SERVER 4444 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 8250 MAIL_SERVER 8250 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 6004 MAIL_SERVER 6004 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 6102 MAIL_SERVER 6102 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 6201 MAIL_SERVER 6201 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 5730 MAIL_SERVER 5730 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 9000 MAIL_SERVER 9000 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 9300 MAIL_SERVER 9300 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 9301 MAIL_SERVER 9301 netmask 255.255.255.255 0 0
static (inside,outside) tcp interface 9302 MAIL_SERVER 9302 netmask 255.255.255.255 0 0
access-group INBOUND in interface outside
route outside 0.0.0.0 0.0.0.0 55.30.17.157 1
route inside 10.1.2.0 255.255.255.0 10.1.2.1 1
timeout xlate 0:05:00
timeout conn 1:00:00 half-closed 0:10:00 udp 0:02:00 rpc 0:10:00 h225 1:00:00
timeout h323 0:05:00 mgcp 0:05:00 sip 0:30:00 sip_media 0:02:00
timeout sip-disconnect 0:02:00 sip-invite 0:03:00
timeout uauth 0:05:00 absolute
aaa-server TACACS+ protocol tacacs+
aaa-server TACACS+ max-failed-attempts 3
aaa-server TACACS+ deadtime 10
aaa-server RADIUS protocol radius
aaa-server RADIUS max-failed-attempts 3
aaa-server RADIUS deadtime 10
aaa-server LOCAL protocol local
http server enable
http 192.168.1.0 255.255.255.0 inside
http 10.1.2.0 255.255.255.0 inside
no snmp-server location
no snmp-server contact
snmp-server community public
no snmp-server enable traps
floodguard enable
sysopt connection permit-ipsec
crypto ipsec transform-set example_set esp-des esp-md5-hmac
crypto dynamic-map dyn_example_map 10 set transform-set example_set
crypto map example_map 10 ipsec-isakmp dynamic dyn_example_map
crypto map example_map interface outside
isakmp enable outside
isakmp identity address
isakmp policy 10 authentication pre-share
isakmp policy 10 encryption des
isakmp policy 10 hash md5
isakmp policy 10 group 2
isakmp policy 10 lifetime 86400
vpngroup example_group address-pool client_VPN
vpngroup example_group dns-server 192.168.1.40
vpngroup example_group default-domain lobotika.local
vpngroup example_group idle-time 1800
vpngroup example_group password ********
telnet 0.0.0.0 0.0.0.0 inside
telnet timeout 5
ssh 0.0.0.0 0.0.0.0 inside
ssh timeout 5
console timeout 0
vpdn enable outside
dhcpd lease 3600
dhcpd ping_timeout 750
username anniswap0 password cockadoodle encrypted privilege 15
terminal width 80
Cryptochecksum:503782c92b1230bd649286ed5b5e784e

and here's a typical teardown message:

May 12 09:29:17 192.168.1.1 May 11 2008 23:31:05: %PIX-6-302013: Built outbound TCP connection 128264 for outside:64.95.129.201/25 (64.95.129.201/25) to inside:10.1.2.185/63113 (217.30.17.158/25766)
May 12 09:29:17 192.168.1.1 May 11 2008 23:31:05: %PIX-6-302014: Teardown TCP connection 128264 for outside:64.95.129.201/25 to inside:10.1.2.185/63113 duration 0:00:00 bytes 0 TCP Reset-O

Be greateful if someone will take a look and tell me what I'm doing wrong.

TIA
More
16 years 6 months ago #26060 by ikon
im confused

Your outside interface is 55.30.17.158
your inside interface is 192.168.1.1

you mail server is 10.1.2.10, where is the 10.1.2.x network you dont have a dmz configured so does local traffic even need to pass through the pix to access the mail server or do you have other routers or firewalls to access the 10.1.2.x network?
More
16 years 6 months ago #26063 by cortezone

im confused

Your outside interface is 55.30.17.158
your inside interface is 192.168.1.1

you mail server is 10.1.2.10, where is the 10.1.2.x network you dont have a dmz configured so does local traffic even need to pass through the pix to access the mail server or do you have other routers or firewalls to access the 10.1.2.x network?


Ikon, don't be confused. I do have a router connected to the inside interface which is connected to two networks. The mail server is on the 10.1.2.0 network and received emails alright from outside but is unable to send. In fact all hosts on both the 192.168.1.0 and 10.1.2.0 networks are unable to send smtp packets through the fw. Tried telnet from both networks and get timed out.
More
16 years 6 months ago #26085 by ikon
Ok cool

Firstly put back your Fixup smtp, without it you have no SMTP guard, the pix has built in Signatures for know SMTP vulnerabilities.


access-list from-inside permit tcp host MAIL_SERVER any eq smtp log (this line allows all SMTP connections OUT from the mail server)

(you need this) line access-list from-inside permit tcp any host MAIL_SERVER eq smtp log

( this will allow all SMTP traffic from any on inside to the mail server.


hope this helps
Time to create page: 0.127 seconds