cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
2288
Views
0
Helpful
4
Replies

Different VLAN Natting

majed.balsharaf
Level 3
Level 3

Hi,

I need to configure NAT in my firewall. But I face one problem due to different vlan's.

example:

int g0/0  ( LAN of vlan 10)  ip nat inside ( what to configure)

int g0/1 (WAN) ip nat outside.

1 Accepted Solution

Accepted Solutions

Hi,

So I assume you are only trying to configure some network with GNS3 and we are not talking about an actual environment.

The first obvious problem with your firewall configuration is that your "inside" or "outside" interface dont have any IP address configured as the above configuration states "no ip address". They should have a configuration "ip address applied to them to actually be able to pass traffic.

I'm not quite sure what the "route inside ???" is supposed to mean? Do you have any routes configured for the "inside" interface at all?

If you are building some test network with the GNS3 software I would suggest you configure either of the 2 setups

  • Option 1: Configure a Trunk between the ASA and the Core switch and let the ASA handle all the routing between the Vlans
  • Option 2: Configure Vlan interfaces for each Vlan on the Core Switch and let the Core switch handle the routing between local Vlans.
    • Configure an additional Vlan/Vlan interface on the Core switch and attach one port on the Core Switch to that Vlan in access mode. Connect that port to the ASA "inside".
    • Configure "route inside" commands for all the networks behind the ASA. Use the IP address of the Vlan interface created above as the gateway IP address for the "route inside" commands.
    • Also configure a default route on the Core Switch pointing towards the ASA "inside" interface IP address

- Jouni

View solution in original post

4 Replies 4

Jouni Forss
VIP Alumni
VIP Alumni

Hi,

Can you please specify the following things

  • Whats the L3 gateway device for the Vlans?
  • What is the firewall type and software level?
  • You mention interfaces Gi0/0 and Gi0/1 and they are not mentioned in the picture?

Some options for you to consider are

  • Configure a trunk  between the Core Switch and Firewall and bring each Vlan there and configure NAT as usual
  • Configure a Link Network/Vlan between the Core Switch (provided that its L3 capable switch) and the firewall and route all traffic towards the firewall that aint local traffic and configure NAT as usual

I'm not quite sure how to answer as I dont know how the setup is. Where are for example the L3 gateways of the Vlans 11 - 13?

- Jouni

Thanks Jouni

My Core Switch is 4503 Switch.

And my Firewall is ASA 5520 firewall.

This is my configuration of ASA

ASA# sh run

: Saved

:

ASA Version 8.2(5)

!

hostname ASA

enable password 8/7Xp7PLnLKeBUEj encrypted

passwd 2KFQnbNIdI.2KYOU encrypted

names

!

interface GigabitEthernet0/0

nameif Inside

security-level 100

no ip address

!

interface GigabitEthernet0/1

nameif Outside

security-level 0

no ip address

!

interface GigabitEthernet0/2

shutdown

no nameif

no security-level

no ip address

!

interface GigabitEthernet0/3

shutdown

no nameif

no security-level

no ip address

!

interface Management0/0

nameif management

security-level 100

ip address 192.168.1.1 255.255.255.0

management-only

!

ftp mode passive

object-group service DM_INLINE_SERVICE_1

service-object tcp eq domain

service-object tcp eq www

service-object tcp eq https

service-object udp eq domain

access-list Inside_access_in extended permit object-group DM_INLINE_SERVICE_1 any any

access-list Inside_nat_outbound extended permit ip any any

pager lines 24

logging asdm informational

mtu Inside 1500

mtu Outside 1500

mtu management 1500

no failover

icmp unreachable rate-limit 1 burst-size 1

no asdm history enable

arp timeout 14400

global (Outside) 1 interface

nat (Inside) 1 access-list Inside_nat_outbound

access-group Inside_access_in in interface Inside

route Outside 0.0.0.0 0.0.0.0 84.235.34.201

route Inside  ???????????????????

timeout xlate 3:00:00

timeout conn 1:00:00 half-closed 0:10:00 udp 0:02:00 icmp 0:00:02

timeout sunrpc 0:10:00 h323 0:05:00 h225 1:00:00 mgcp 0:05:00 mgcp-pat 0:05:00

timeout sip 0:30:00 sip_media 0:02:00 sip-invite 0:03:00 sip-disconnect 0:02:00

timeout sip-provisional-media 0:02:00 uauth 0:05:00 absolute

timeout tcp-proxy-reassembly 0:01:00

timeout floating-conn 0:00:00

dynamic-access-policy-record DfltAccessPolicy

http server enable

http 192.168.1.0 255.255.255.0 management

no snmp-server location

no snmp-server contact

snmp-server enable traps snmp authentication linkup linkdown coldstart

crypto ipsec security-association lifetime seconds 28800

crypto ipsec security-association lifetime kilobytes 4608000

telnet timeout 5

ssh timeout 5

console timeout 0

dhcpd address 192.168.1.2-192.168.1.254 management

dhcpd enable management

!

threat-detection basic-threat

threat-detection statistics access-list

no threat-detection statistics tcp-intercept

webvpn

username cisco password 3USUcOPFUiMCO4Jk encrypted

!

class-map global-class

match any

class-map inspection_default

match default-inspection-traffic

!            

!

policy-map type inspect dns preset_dns_map

parameters

  message-length maximum client auto

  message-length maximum 512

policy-map global_policy

class inspection_default

  inspect dns preset_dns_map

  inspect ftp

  inspect h323 h225

  inspect h323 ras

  inspect rsh

  inspect rtsp

  inspect esmtp

  inspect sqlnet

  inspect skinny 

  inspect sunrpc

  inspect xdmcp

  inspect sip 

  inspect netbios

  inspect tftp

  inspect ip-options

!

service-policy global_policy global

prompt hostname context

no call-home reporting anonymous

Cryptochecksum:04523bf5686676c23bbf7da58f55a207

: end

ASA#

Hi,

So I assume you are only trying to configure some network with GNS3 and we are not talking about an actual environment.

The first obvious problem with your firewall configuration is that your "inside" or "outside" interface dont have any IP address configured as the above configuration states "no ip address". They should have a configuration "ip address applied to them to actually be able to pass traffic.

I'm not quite sure what the "route inside ???" is supposed to mean? Do you have any routes configured for the "inside" interface at all?

If you are building some test network with the GNS3 software I would suggest you configure either of the 2 setups

  • Option 1: Configure a Trunk between the ASA and the Core switch and let the ASA handle all the routing between the Vlans
  • Option 2: Configure Vlan interfaces for each Vlan on the Core Switch and let the Core switch handle the routing between local Vlans.
    • Configure an additional Vlan/Vlan interface on the Core switch and attach one port on the Core Switch to that Vlan in access mode. Connect that port to the ASA "inside".
    • Configure "route inside" commands for all the networks behind the ASA. Use the IP address of the Vlan interface created above as the gateway IP address for the "route inside" commands.
    • Also configure a default route on the Core Switch pointing towards the ASA "inside" interface IP address

- Jouni

Thanks for your help Jouni,

  But i got the answer,just I need to add my inside traffic ( all vlan's) and one outside IP.  So all the vlans can access internet now.

Review Cisco Networking for a $25 gift card