Need to Open SMTP port and redirect it to Exchange server Cisco PIX 501

Posted on 2006-10-29
Last Modified: 2013-11-16
I need to open port 25 on my pix 501 and forward it to my internal exchange server with ip  I tried doing that by looking at some posts but am not sure if I did it right because when I do telnet 25, I get an error “ could not open connection to the host on port 24.  Please note that I have replaced my public ip with for security reasons :-).  Please let me know if the port 25 is open and is being forward to my exchange server and if telent is the way to test it. Thank you for you help.

Building configuration...
: Saved
PIX Version 6.3(5)
interface ethernet0 auto
interface ethernet1 100full
nameif ethernet0 outside security0
nameif ethernet1 inside security100
enable password cdS8OVu02pgL9w/8 encrypted
passwd cdS8OVu02pgL9w/8 encrypted
hostname pixfirewall
domain-name royalfitness.local
clock timezone EAST -6
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
no fixup protocol smtp 25
fixup protocol sqlnet 1521
fixup protocol tftp 69
access-list inside_outbound_nat0_acl permit ip any
access-list inside_outbound_nat0_acl permit ip
access-list outside_cryptomap_dyn_20 permit ip any
access-list splitacl permit ip
access-list inbound_acl permit tcp any host eq 3389
access-list outside_in permit tcp any host eq smtp
access-list outside-in permit tcp any host eq smtp
pager lines 24
mtu outside 1500
mtu inside 1500
ip address outside
ip address inside
ip audit info action alarm
ip audit attack action alarm
ip local pool VPNPool
pdm location inside
pdm location inside
pdm location inside
pdm location outside
pdm location outside
pdm location inside
pdm location outside
pdm location inside
pdm location inside
pdm location inside
pdm logging informational 100
pdm history enable
arp timeout 14400
global (outside) 1 interface
nat (inside) 0 access-list inside_outbound_nat0_acl
nat (inside) 1 0 0
static (inside,outside) tcp 3389 3389 netmask 0 0
static (inside,outside) tcp smtp smtp netmask 0 0
access-group outside_in in interface outside
route outside 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 outside
http inside
http 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 ESP-3DES-MD5 esp-3des esp-md5-hmac
crypto dynamic-map outside_dyn_map 20 set transform-set ESP-3DES-MD5
crypto map outside_map 65535 ipsec-isakmp dynamic outside_dyn_map
crypto map outside_map client configuration address respond
crypto map outside_map client authentication LOCAL
crypto map outside_map interface outside
isakmp enable outside
isakmp identity address
isakmp keepalive 10
isakmp nat-traversal 20
isakmp policy 1 authentication pre-share
isakmp policy 1 encryption 3des
isakmp policy 1 hash sha
isakmp policy 1 group 2
isakmp policy 1 lifetime 86400
isakmp policy 20 authentication pre-share
isakmp policy 20 encryption 3des
isakmp policy 20 hash md5
isakmp policy 20 group 2
isakmp policy 20 lifetime 86400
vpngroup saavpn address-pool VPNPool
vpngroup saavpn dns-server
vpngroup saavpn wins-server
vpngroup saavpn split-tunnel splitacl
vpngroup saavpn idle-time 1800
vpngroup saavpn password ********
vpngroup royal idle-time 1800
vpngroup royal password ********
telnet outside
telnet outside
telnet inside
telnet inside
telnet timeout 5
ssh outside
ssh timeout 5
console timeout 0
dhcpd address inside
dhcpd dns
dhcpd wins
dhcpd lease 3600
dhcpd ping_timeout 750
dhcpd auto_config outside
dhcpd enable inside
username vpnadmin password 30mrCM7hnW6aPDmz encrypted privilege 15
terminal width 80
: end

Question by:netcomp
  • 3
  • 2
LVL 79

Accepted Solution

lrmoore earned 350 total points
Comment Utility
Given what you have:

>no fixup protocol smtp 25
> access-list outside_in permit tcp any host eq smtp
>access-group outside_in in interface outside
>static (inside,outside) tcp smtp smtp netmask 0 0

There is no reason why it won't work...

Check the default gateway of the server....

You could use "interface" as below:

>static (inside,outside) tcp interface smtp smtp netmask 0 0
> access-list outside_in permit tcp any interface outside eq smtp
>access-group outside_in in interface outside

LVL 20

Assisted Solution

calvinetter earned 150 total points
Comment Utility
 Agree w/ lrmoore that the config looks good, but after you added the "static (inside,outside)" entry, did you also run the following?
 clear xlate
 clear local

>when I do telnet 25, I get an error...
  If you tried this from the inside, this is expected: PIX won't allow you to directly access your public IP from behind the PIX.  If you tried this from an external location outside the PIX, then something is amiss.

  Just to avoid confusion, I'd remove the almost-identically named ACL...
no access-list outside-in permit tcp any host eq smtp


Author Comment

Comment Utility
Thanks for all of your help. I wanted to ask one last thing. If I  just wanted to rediract another port to the same server(port  443) using the same access list, is that possible. If so can you give me the commands. Is there a limit to the opening ports on one access list. Thank again for all of your help.
Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

LVL 79

Expert Comment

Comment Utility
Sure, just keep adding access-list commands with the port #

> access-list outside_in permit tcp any host eq www
> access-list outside_in permit tcp any host eq https
> access-list outside_in permit tcp any host eq pop3
As long as you also have the statics to match
static (inside,outside) tcp www www netmask
static (inside,outside) tcp https https netmask
static (inside,outside) tcp pop3 pop3 netmask

Only real limit is how many lines of config you can hold..couple of hundred maybe.. then you want to look at alternatives..

Author Comment

Comment Utility
I noticed that you have “www” or “hhtps”  instead of port number. I assume that the pix knows for instance that www is port 80. If so , I was just wandring why did we have to do “no fixup protocol smtp 25” for the smtp port. Thanks , this would be my last questions  :-) . Thank you again,
LVL 79

Expert Comment

Comment Utility
no reason , just alternatives

Featured Post

Highfive Gives IT Their Time Back

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Wikipedia defines 'Script Kiddies' in this informal way: "In hacker culture, a script kiddie, occasionally script bunny, skiddie, script kitty, script-running juvenile (SRJ), or similar, is a derogatory term used to describe those who use scripts or…
If you are like regular user of computer nowadays, a good bet that your home computer is on right now, all exposed to world of Internet to be exploited by somebody you do not know and you never will. Internet security issues has been getting worse d…
This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor ( If you're looking for how to monitor bandwidth using netflow or packet s…
This video shows how to remove a single email address from the Outlook 2010 Auto Suggestion memory. NOTE: For Outlook 2016 and 2013 perform the exact same steps. Open a new email: Click the New email button in Outlook. Start typing the address: …

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now