cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
437
Views
0
Helpful
2
Replies

NAT of Source AND destination address

drajnauth
Level 1
Level 1

Typically with NAT you are changing either and inside or outside address to another address.

Is if possible to change both inside and outside addresses within the same router?

That is rewrite both source and destination addresses within the same router. Both source and destination addresses to be changed are fixed and are not local to any interface on the router. The final (egress) addresses could be made local one of the router interface or maybe even a loopback interfaces.

Does anyone have or know of a sample configuration?

Many thanks.

2 Replies 2

t.baranski
Level 4
Level 4

Easier than you'd think:

int f0/0

ip nat inside

int f0/1

ip nat outside

ip nat inside source static a.a.a.a b.b.b.b

ip nat outside source static c.c.c.c d.d.d.d

This changes the source address of traffic from a.a.a.a coming into f0/0 to b.b.b.b, and the destination (if it goes out f0/1) from c.c.c.c to d.d.d.d.

Hello,

Is this also possible using the following commands:

ip nat inside source list acl-101 pool pool-101

ip nat outside source list acl-102 pool pool-102

!

ip access-list extended acl-101

permit ip host a.a.a.a host d.d.d.d

!

ip access-list extended acl-102

permit ip host y.y.y.y host d.d.d.d

!

ip nat pool pool-101 b.b.b.b b.b.b.b netmask 255.255.255.0

ip nat pool pool-101 c.c.c.c netmask 255.255.255.0

Thanks for any reponse.

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: