Sponsored Content
Full Discussion: L2 nat
Special Forums IP Networking L2 nat Post 302262770 by Lazydog on Friday 28th of November 2008 03:48:46 PM
Old 11-28-2008
Sorry, try this;

Code:
iptables -A PREROUTE -i <IFACE> -m  mac --mac-source <MAC> -j SNAT <IP>

 

10 More Discussions You Might Find Interesting

1. IP Networking

FreeBSD - NAT

Hi All! I have a Pentium 100 (32 MBRAM) with FreeBSD 4.4 installed on it and I am using it as a gateway. When I am downloading (or uploading) stuff simultaneously I see that natd is using up to 100% of the cpu capacity, hence the internet connection becomes blocked. My guess is I will have... (1 Reply)
Discussion started by: Ivo
1 Replies

2. BSD

proxy or NAT

how do i configure proxy in freeBSD or NAT so that when i set it up as a server can connect other to my new gateway (0 Replies)
Discussion started by: AkinOkin
0 Replies

3. IP Networking

NAT question

i have a firewall with two interfaces eth0 and eth1, eth0 is connected to an external network, and eth0 is connected to a private lan. im using this command for NAT iptables -A POSTROUTING -t nat -s 192.168.0.0/24 -o eth0 -j SNAT --to-source 223.0.0.3 my questions are : 1) how can i... (4 Replies)
Discussion started by: ratamahatta
4 Replies

4. IP Networking

NAT address

Hi Could anybody tell me the solaris command to display the NAT address Thanks in advance (5 Replies)
Discussion started by: axes
5 Replies

5. Solaris

Zones - NAT'ing

Hi gurus. Not such a problem, more of a proof of concept. Ive got two zones :- database-1 and database-dr-1 on two different servers. Both zones have different ip addresses. I want to copy the whole zone database-1 over to database-dr-1, which is simple enough, but I want to install... (0 Replies)
Discussion started by: sbk1972
0 Replies

6. Shell Programming and Scripting

NAT detection

hellou, can anybody help me with nat detection in real time ? i prefer some detection script because i try some nat detection program's for example p0f or i'm using tcpdump, but i would get contain of specific packet. Some ideas? (1 Reply)
Discussion started by: TheTechnic
1 Replies

7. Solaris

NAT IPFilter

Hi everybody, I'm running on Solaris 10 X86 (update 1009). I would like to make NAT's rule. I explain you. On Solaris, I configure the principal interface e1000g0 with IP : 192.168.0.33 I created the first logical interface like that : ifconfig e1000g0 addif 192.168.0.40 netmask... (0 Replies)
Discussion started by: aureliensm
0 Replies

8. Infrastructure Monitoring

Snmp and NAT

Hello, I am facing this scenario: three or more remote LAN (peripheral offices), with the same devices (printers, NAS) in each of them. Those LANs have the same network addresses, i.e.192.168.1.* (are connected to WAN via NAT). I need to collect snmp traps from a central server (public IP).... (4 Replies)
Discussion started by: neutrino
4 Replies

9. Cybersecurity

iptables in a NAT scenario

Hi, I am learning IPTables have this question. My server is behind a firewall that does a PAT & NAT to the LAN address. Internet IP: 68.1.1.23 Port: 10022 Server LAN IP: 10.1.1.23 port: 22 Allowed Internet IPs: 131.1.1.23, 132.1.1.23 I want to allow a set of IPs are to be able to... (1 Reply)
Discussion started by: capri_guy84
1 Replies

10. Solaris

OpenVPN and NAT

Hi. I am attempting to set up an OpenVPN server on my Solaris 11 box by following all the Linux guides. Thus far I have a working VPN that I can connect to and ssh onto my VPN server over which is great but not what I require long term. I would like to route all VPN client requests for addresses... (0 Replies)
Discussion started by: nickb1976
0 Replies
NAT action in tc(8)						       Linux						       NAT action in tc(8)

NAME
nat - stateless native address translation action SYNOPSIS
tc ... action nat DIRECTION OLD NEW DIRECTION := { ingress | egress } OLD := IPV4_ADDR_SPEC NEW := IPV4_ADDR_SPEC IPV4_ADDR_SPEC := { default | any | all | in_addr[/{prefix|netmask}] DESCRIPTION
The nat action allows to perform NAT without the overhead of conntrack, which is desirable if the number of flows or addresses to perform NAT on is large. This action is best used in combination with the u32 filter to allow for efficient lookups of a large number of stateless NAT rules in constant time. OPTIONS
ingress Translate destination addresses, i.e. perform DNAT. egress Translate source addresses, i.e. perform SNAT. OLD Specifies addresses which should be translated. NEW Specifies addresses which OLD should be translated into. NOTES
The accepted address format in OLD and NEW is quite flexible. It may either consist of one of the keywords default, any or all, represent- ing the all-zero IP address or a combination of IP address and netmask or prefix length separated by a slash (/) sign. In any case, the mask (or prefix length) value of OLD is used for NEW as well so that a one-to-one mapping of addresses is assured. Address translation is done using a combination of binary operations. First, the original (source or destination) address is matched against the value of OLD. If the original address fits, the new address is created by taking the leading bits from NEW (defined by the netmask of OLD) and taking the remaining bits from the original address. There is rudimental support for upper layer protocols, namely TCP, UDP and ICMP. While for the first two only checksum recalculation is performed, the action also takes care of embedded IP headers in ICMP packets by translating the respective address therein, too. SEE ALSO
tc(8) iproute2 12 Jan 2015 NAT action in tc(8)
All times are GMT -4. The time now is 11:20 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy