Networking :: Routing All Traffic To Internet Through A Box?

Oct 6, 2010

I am sharing my DSL internet connection using a modem+wireless router (single device) to 5 systems. I want all my internet traffic to go through one of the linux boxes in my network.

The problem here is that wireless devices connect directly to the modem+wireless router.

Is such routing of traffic possible??

PS: I am not sure if i could convey my situation clearly...

View 2 Replies


ADVERTISEMENT

Ubuntu Networking :: Routing - Forward All Traffic To An Ip To Another Ip

Jul 25, 2010

I need to be able to do the following: Physical Router located at 192.168.40.1

On Ubuntu 10.04 Lucid machine:
eth0 with static ip 192.168.40.2
eth1 with static ip 192.168.40.3
eth2 with static ip 192.168.40.4

Associate a virtual address to eth1 with an entirely different network address such as 192.168.50.1 Do the same (virtual address) for eth2 -- e.g. 192.168.60.1 In the application:

register phone number A at 192.168.40.1 (The application will automatically use eth0 for this)
register phone number B at 192.168.50.1
register phone number C at 192.168.60.1

Somehow forward all traffic (including the register request) sent to 192.168.50.1 to 192.168.40.1 as if the register had been made directly to 192.168.40.1. In other words, the app "sends" registration and traffic to 192.168.50.1 but then Ubuntu forwards it to 192.168.40.1 (but the app does not know that). Similarly, forward all traffic sent to 192.168.60.1 to the router at 192.168.40.1.

Do the same for the reverse, forward all traffic that the router sends back to 192.168.40.3 (eth1) to 192.168.50.1 (within the Ubuntu machine) so that the app knows it is for phone B. Similarly forward all traffic that the router sends back to 192.168.40.4 (eth2) to 192.168.60.1 so that the app knows it is for phone C. Thus, the application believes that it is registering at 3 completely separate routers on 3 completely separate networks via 3 separate network interfaces but in fact is really registering all three to the same router (but does not know that). Similarly, the router believes that it is receiving 3 separate registrations because it receives each registration request and traffic from 3 separate interfaces and thus 3 separate mac addresses (i.e., of eth0, eth1, and eth2). Traffic sent to and from the router for each of the 3 phone numbers (via eth0, eth1, and eth2) are not mixed because the translation happens in both directions.

View 9 Replies View Related

Fedora Networking :: Advance Routing And Traffic Control

Feb 23, 2010

I'm currently reading through the Linux Advanced Routing and Traffic Control HOWTO from lartc.org, and I'm wondering whether anyone knows of a file where I could keep qos rules persistent across a reboot, similar to /etc/sysconfig/iptables for netfilter. Should I just write my own script, or does something already exist?
By the way, iproute-2.6.29-4.fc12.i686.

View 2 Replies View Related

Networking :: IPTables And Routing On Untangle Box - Traffic Not Returned

Aug 20, 2010

I have an Untangle Box - which for those that don't know is a modified Debian Lenny used as a router, proxy, filter and much more - It has three physical interfaces on it eht0 (incoming traffic), eth1 (Outgoing to LAN after traffic filtered), and eth2 (Called a DMZ NIC, as Untangle can be used as a router). There is also a tun0 interface setup by Untangle for VPN (Not using the Openvpn in Untangle because I need bridged a bridged VPN and this is not an option in Untangles offering), a br0.eth setup by untangle to bridge eth0 and eth1 for traffic flow through as it is inline from router to switch and not acting as the router itself, and a br0 interface that I have setup by bridge script bridging eth2 and tap0 to run OpenVPN as a bridged VPN.

The routes on the machine are as follow:
Code:
untangle:~# route
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.100.0 * 255.255.255.0 U 0 0 0 br.eth0
192.168.1.0 * 255.255.255.0 U 0 0 0 br0
192.0.2.0 * 255.255.255.0 U 0 0 0 dummy0
192.0.2.0 * 255.255.255.0 U 0 0 0 utun
untangle:~#

I don't see a default route listed here, however, I do have Internet connectivity on the Untangle box itself. I also know that by script to bridge the tap0 and eth2 interfaces adds a default route through the gateway on the network that eth2 is connected to. So the lack of a default route is somewhat puzzling to me, I do have the gateway set through the web based admin interface Untangle offers.

The iptables rules are as follow:
Code:
untangle:~# iptables --list-rules
-P INPUT ACCEPT
-P FORWARD ACCEPT
-P OUTPUT ACCEPT
-N alpaca-firewall .....

There was an addition output rule in the alpaca-nat-firewall rule that said DROP outgoing interface eth2, I removed that rule with no change. I can ping out from the Untangle server to the eth2 LAN, I can access resources in the eth2 subnet. But I cannot get any reply from the server from anything either in that subnet or not. If I run iftop I can see the incoming traffic form my ping but the Server sends out no reply. I think this is a firewall issue. I can access the server by connecting to the IP assigned to the eth0/br0.eth interface which is in my main LAN. I am also attaching a crude diagram of the previous setup and the new setup (Previous setup used a different server for my bridged VPN).

Is there a rule I can add to ensure that traffic coming in on an interface goes out the same interface? Do I have a rule blocking incoming traffic to eth2/br0? Do I have one blocking sending out on eth2/br0? Do I have a default rule that is killing the traffic on eth2/br0 and I need to add an accept rule for traffic coming in on eth2/br0? I tried adding an accept rule for traffic coming in on br0, but it didn't work. I tried an output rule, but that didn't work, but I may have been bungling these rules as I do not fully understand the syntax and function and body of an iptables rule. The exact original iptables information before I modified anything can be viewed at [URL].

View 4 Replies View Related

Networking :: Port Based Routing For Local Traffic?

May 24, 2009

I have problem with port based routing for local traffic. I can't use trick with iptables -t mangle, ip route table 1, ip rule fwmark table 1 because it works only with forwarded packets. I can't even use patch-o-matic because it's obsolete. And xtables-addons doesn't contain support for "-j ROUTE" yet.

View 2 Replies View Related

Networking :: Routing Incoming Traffic To NAT'ed VM On A Hired Dedicated Server?

May 21, 2010

I have set up a Virtual machine on a dedicated server from 1and1. I hoped to use a bridge to give the vm direct access to the internet but 1and1 do mac filtering and so the only option is to use NAT.

I used Virtual Machine Manager on my Ubuntu 10.04 machine at home to install Debain Lenny on the vm on the server using KVM and all went well. I put it on a virtual network 192.168.100.0 and i can access it from the host and i can access the internet from the guest using NAT that libvirt set-up.

I bought another ip address from 1and1 with the hope of forwarding packets to the new ip address 11.22.33.02 to the guest vm.

I have tried all sorts of routing rules using iptables without any success.

my virtual network is on virbr1 the guest ip is 192.168.100.50 my external network device is ip say 11.22.33.01 on eth0 with the secondary ip say 11.22.33.02 on eth0:1

Here are the latest rules i tried:

Quote:

iptables -t nat -A PREROUTING -d 11.22.33.02 -i eth0 -j DNAT --to-destination 192.168.100.50
iptables -t nat -A POSTROUTING -s 192.168.100.50 -o eth0 -j SNAT --to-source 11.22.33.02
iptables -A FORWARD -p tcp -i eth0 -o virbr1 -d 192.168.100.50 -m state --state NEW -j ACCEPT
iptables -A FORWARD -t filter -i eth0 -m state --state ESTABLISHED,RELATED -j ACCEPT

[Code].....

View 2 Replies View Related

Ubuntu Networking :: Vpnc Traffic Routing - IPSec Target Network?

Nov 16, 2010

I just got vpnc setup to work with my VPN at work and now I am trying to figure out how to limit the traffic that is routed through the VPN while I'm connected to it. I only want traffic going to the local domain to be routed through the VPN.This is what my vpnc config file looks like:

Code:
IPSec gateway publicdomain.example.com
IPSec ID XXXX

[code]....

View 2 Replies View Related

Ubuntu Networking :: Routing Internet From One Router To Another?

Feb 11, 2011

How can I find the IP of a router wirelessly so I can use the second router for a better signal? (A farther reaching wireless card is what im trying to make it do)

also how can I find the subnetmask this way?

View 4 Replies View Related

Debian Configuration :: Routing - Forward All Traffic To An Ip To Another Ip?

Jul 25, 2010

I need to be able to do the following: Physical Router located at 192.168.40.1 On Ubuntu 10.04 Lucid machine:

eth0 with static ip 192.168.40.2
eth1 with static ip 192.168.40.3
eth2 with static ip 192.168.40.4

Associate a virtual address to eth1 with an entirely different network address such as 192.168.50.1 Do the same (virtual address) for eth2 -- e.g. 192.168.60.1 In the application:

register phone number A at 192.168.40.1 (The application will automatically use eth0 for this)
register phone number B at 192.168.50.1
register phone number C at 192.168.60.1

Somehow forward all traffic (including the register request) sent to 192.168.50.1 to 192.168.40.1 as if the register had been made directly to 192.168.40.1. In other words, the app "sends" registration and traffic to 192.168.50.1 but then Ubuntu forwards it to 192.168.40.1 (but the app does not know that). Similarly, forward all traffic sent to 192.168.60.1 to the router at 192.168.40.1.

Do the same for the reverse, forward all traffic that the router sends back to 192.168.40.3 (eth1) to 192.168.50.1 (within the Ubuntu machine) so that the app knows it is for phone B. Similarly forward all traffic that the router sends back to 192.168.40.4 (eth2) to 192.168.60.1 so that the app knows it is for phone C. Thus, the application believes that it is registering at 3 completely separate routers on 3 completely separate networks via 3 separate network interfaces but in fact is really registering all three to the same router (but does not know that). Similarly, the router believes that it is receiving 3 separate registrations because it receives each registration request and traffic from 3 separate interfaces and thus 3 separate mac addresses (i.e., of eth0, eth1, and eth2). Traffic sent to and from the router for each of the 3 phone numbers (via eth0, eth1, and eth2) are not mixed because the translation happens in both directions.

View 10 Replies View Related

Networking :: Bridging Or Routing Between 2 Segments With 2 Internet Providers

Mar 23, 2010

My roommate has a slow ADSL provider, and i have a much faster cable connection. He has his own residential gateway, and as do i. The goal i am trying to accomplish is to share 2 printers (1 behind each residential gateway) and also files between computers on the different LAN segments, but not share ISPs or DHCP servers.

Thus far, i have configured my residential gateway's DHCP server to have control of the 192.168.1.0/24 network and his gateway's DHCP server controls the 192.168.0.0/24 network. We've got a Slackware 13.0 Linux box connected on the 192.168.0.0/24 network which currently just serves a web page and accepts e-mail for a domain. My knowledge of networking fails me here as I'm not sure what piece of equipment i would need to buy to solve this puzzle (bridge or router). I know iproute2 can do wonderful things on Linux, and i figure it would be easier to just shove a NIC or 2 in the Linux box and make it do what i need instead of buying more networking equipment.

View 1 Replies View Related

Ubuntu :: Internet Traffic Flow Monitor - Track Traffic Of Each Device

Apr 27, 2010

We have something on our network that is reaking havoc with our content filter. I am trying to track it down, but so far I have been unsuccessful. We have approximately 500 devices in 100+ different locations spread across 9 states. Looking at each computer is not really feasible.

I need a machine that can sit in between our network and our internet connection and graphically monitor in real time and logs how much traffic each device is sending and receiving. It would need to sit inline so it has to have two nics and be able to pass traffic. The machine also needs to be transparent. Reconfiguration of our routers or workstations is not an option.

I have used ethereal and wireshark before. Ethereal may be a viable option, but wireshark seems to provide lots of information, but no practical way to make use of it. how to set up the box to be a transparent device on the network that will allow internet bound traffic to flow (freely)?

View 3 Replies View Related

CentOS 5 Networking :: Routing 2 Internal Nets Through Separate NICs To Internet?

Nov 9, 2009

I have configured CentOS 5.4 as a router/firewall (iptables) as such, and it is working fine:

eth0 - Public IP/Intenet, DHCP
eth1 - 192.168.0.0 internal "net1"
eth2 -10.0.0.0 internal "net2"

I want to add a fourth NIC, eth3, which will be assigned its own Public IP/Internet address (thru DHCP; my ISP provides two). The purpose it to route all net1's internet-bound traffic through eth0, and all of net2's internet traffic to eth3. This allows me to use one router/firewall machine instead of two separate ones. I anticipate that without some specific routing instructions, the default route will be eth0 for all net1 and net2 internet traffic (eth3 will be ignored).

I thought of using just one NIC (eth0) but create an alias (eth0:0), but IPtables (and possible DHCP) can't differentiate between the two (besides, nics are inexpensive). Is there a way to do this through routing commands, or even use iptables prerouting/forward functions (or is using iptables problematic)?

View 1 Replies View Related

Fedora Networking :: Internet Traffic Monitor ?

Mar 9, 2009

Is there a nice easy to use tool that displays (in KB/s) the internet traffic from every IP on a network?

Currently I'm using iptraf, but it's very hard to understand at times.

A little info on my network:

I'm using SNAT for internet sharing.

View 4 Replies View Related

Networking :: Forwarding All Internet Traffic Through Proxy

Jul 19, 2011

My PC is part of a LAN so while configuring eth0, we specify the Gateway to access all other resources in the network. The PC successfully access Internet through a proxy server configured in Mozilla(manual proxy config) but the update option or the Synaptic Pkg mngr are not able to access internet anyway. I have tried the option "Apply System Wide" in "Network Proxy" but no progress so far.

I also tried to forward all request coming for udp/tcp on port 80 to the proxyserver on a specific port, but with no success. Also I can't ping any website from terminal, reiterating the fact that I can access internet in firefox through the proxy on a specific port.

View 2 Replies View Related

Networking :: Route Internet Traffic Over Second IP Address?

Mar 4, 2010

My ISP has given me 3 IP addresses to use for the internet (76.148.200.3, 76.148.200.4 and 76.148.200.5).

If I do a "wget whatismyip.com" or netcat into another server, I am appearing as 76.148.200.3.How do I change my route (command line) in linux to route internet traffic through 76.148.200.5?

Code:
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).
# The loopback network interface
auto lo
code....

View 9 Replies View Related

Networking :: Route Internet Traffic Over Tun0?

Mar 28, 2010

I have eth0 and tun0. tun0 is a VPN tunnel going over eth0. Everything on the other end is setup and working fine, when I type Code: traceroute 4.2.2.1 I see my the ping is going over 192.168.2.99 (eth0). When I then type Code: route add -net 4.2.2.1 netmask 255.255.255.255 dev tun0 traceroute 4.2.2.1 I see ping is going over 10.8.0.1 (tun0) instead of eth0, so that is working

What does not work however is when I do Code: route add -net 0.0.0.0 netmask 0.0.0.0 dev tun0 traceroute 4.2.2.1 I get no ping! I believe the problem is because all traffic is routing over tun0, which means even the VPN tun0 needs to go through eth0, it can no longer do this. Is there a way around this where I can route everything except for 114.77.31.26 (which is my VPN gateway for tun0)?

View 18 Replies View Related

Networking :: How To Implement Internet Traffic Quota

Mar 30, 2010

I'd like to allocate a certain quota to my local user for their internet navigation.

View 8 Replies View Related

Networking :: Insert Routing Data Into The Routing Table Doesn't Work?

Apr 6, 2010

I have a firewall, this consists of three NIC's:

Code: eth0[192.168.0.2] eth1[192.168.1.2] and eth2[10.10.165.2]

I am trying to ping eth0 from eth2, but I am not able to succesfully get a response from pinging the device, I am using:

Code: ping 192.168.0.2 -I eth2

I have tried to insert routing data into the routing table, but it still doesn't work

View 2 Replies View Related

Fedora Networking :: Monitor Broadband Internet Traffic Only ?

Aug 23, 2009

I have a 2 machine LAN with both machines having an ethernet card and a wireless card. There is a Netgear router, both eth and WiFi, allowing both machines to access the internet.

On my Linux machine I am looking for some software that allows me to keep track of my broadband usage on that machine, excluding traffic between the two machines.

There are numerous such programmes for this in XP, which use Winpcap and a GUI frontend. The "other" machine on my LAN is XP and uses just such a program.

View 4 Replies View Related

Ubuntu Networking :: Control Internet Traffic Without Router?

Jul 27, 2010

I have a desktop, a laptop, & a wireless router. The router, unfortunately, doesn't support dd-wrt, tomato, etc firmware, but I would still like to prioritize voip/web browsing over bulk Internet traffic. I hope I can offload the router's missing QoS to my desktop.

Is it possible to have the laptop's connection go from the wall to the router to the desktop, where the desktop could perform the QoS of tomato, then continue on to the laptop? I'm a bit of a noob to networking (subnets?) but do well enough following good instructions.

As for the program that would do the QoS... Don't some Linux machines basically work as super-powered routers for businesses? So there must be some package but couldn't find one. The closest I got was wondershaper but it only shapes traffic for the computer on which it's installed; it might form part of the solution but falls short on its own. other devices should be able to access the Internet normally if the desktop is turned off, & work with other devices like a (jailbroken) iPod Touch.

View 1 Replies View Related

Ubuntu Networking :: Second NIC (Wireless) Not Taking Any Internet Traffic

Feb 8, 2011

I have the standard wired LAN NIC and a wireless NIC installed. What my problem is, the wireless NIC will not take any internet traffic. The LAN connection gets it's internet from my LAPTOP with a Clear 4G module. I have a very strong wireless connection, but when I remove the LAPTOP from the network, I get nothing on my Ubuntu computer here, even though I have a solid connection. What is needed in the config to let the wireless run in the "back up" internet connection mode?

View 9 Replies View Related

Networking :: Can OpenVPN Be Used To Hide Or Encrypt Internet Traffic?

Aug 31, 2010

I have some questions about openVPN. I am wanting to hide my downloading through transmission and I'd like to know if I can use openVPN for this? Also do I need access to a server? I don't understand how it all works.

View 5 Replies View Related

Networking :: Iptable Command To Allow Traffic To Internet But Not Subnet?

Jun 3, 2010

My internet gateway is 192.168.1.1 with a 255.255.255.0 subnet mask. I have a router connected to it running ddwrt with an ip 192.168.2.1/24 creating a second subnet behind it. I have a tenant moving in that will be wirelessly connecting to the ddwrt router, so to the 192.168.2.0/24 subnet. What I am looking for is a rule that will pass internet traffic to and from this client, but restrict him access from the 192.168.1.0/24 subnet otherwise. The ddwrt router is connected to the 192.168.1.1 gateway through its wan port, btw. For example, the client would get an ip address of 192.168.2.100 wirelessly from the ddwrt router. I want him to be able to surf the internet through the 192.168.1.1 gateway, but not to have any other access to the 192.168.1.0/24 subnet (ideally not have access to ANYTHING besides the internet).

View 4 Replies View Related

Ubuntu Networking :: System Monitor Doesn't Show Internet Traffic?

Mar 8, 2011

Ubuntu system monitor applet doesn't show internet traffic although my wireless is working just fine. I use a conky to monitor bandwidth through vnstat and had no problem till I upgraded to maverick.

**ifconfig
wlan0 Link encap:Ethernet HWaddr 00:24:d2:c4:3e:da
inet adr:192.168.0.100 Bcast:192.168.0.255 Masque:255.255.255.0
adr inet6: fe80::224:d2ff:fec4:3eda/64 Scope:Lien
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1

[Code]...

View 1 Replies View Related

Networking :: IPtables: Route Outgoing Traffic From Internal Host To Only Go A Internet Interface?

Nov 21, 2010

My Ubuntu Box has 3 interfaces. eth0 (Internal 192.168.1.0/24)eth1 (External ISP DHCP)eth2 (External ISP Static IP)I need the outgoing traffic to internet for 1 of the internal pc (192.168.1.10) to only go only go through eth2

View 4 Replies View Related

Networking :: Routing To Internet Through One Network And To Local Ips In Another Network?

Mar 31, 2009

I have two networks. One of them is wired, the other is wireless. The wired has an internet connection and a few other computers connected to it. The wireless network has a few hosts connected to it too, but it has no internet connection. What I've been trying, fruitlessly, to do, is make all connections that are bound to the internet, or my wired network, be routed that way, and all the connections to the hosts of the wireless network go that way.

Here's the setup..

Wired:

192.168.1.0/24 Gateway = 192.168.1.1

Route internet through here

Wireless

192.168.2.0/24 Gateway = 192.168.2.1

If my computer sends a packet to the internet, it should be routed through 192.168.1.1 If I send a packet to one of the local hosts of the wireless network, it should be routed through 192.168.2.1. Here's the routing table I've set up(This is one of many configurations I've tried)

Code:

$ ip route show
192.168.2.1 dev wlan0 scope link
192.168.2.0/24 via 192.168.2.1 dev wlan0 src 192.168.2.4

[code]....

With this, and everything else, I get destination host unreachable when pinging. The strange thing is that, if I unplug my eth cable, reboot and connect to the wireless network, everything is fine and I can access the router and the others. I'm trying to improve my networking skills, as I've had this of setting up a small linux box as a router for quite some time, for the fun of it, but I need to get routing under control before I go ruin my network.

View 6 Replies View Related

CentOS 5 Networking :: Configure Firewall - Allow And Forward All Traffic On Eth0 And Block All Traffic On Eth1 Except Ssh Ping

Sep 29, 2010

I need to set up my centOS computer as a firewall in my home network. Ive got 2 interfaces, eth0 and eth1. I want to allow and forward all traffic on eth0 and block all traffic on eth1 except ssh, ping(icmp) and DNS. How do I do this? Ive tried some editing in /etc/sysconfig/iptables but no luck.

View 1 Replies View Related

Networking :: Server To Block All Traffic But US Only Traffic?

Mar 15, 2011

I wanted to tell my server to block all traffic but US only traffic. So i followed this guide:[URL].. Now I know, it's the best way to help prevent hackers/crackers (doesn't matter to me what they are called. I just have to stop them). My server only deals with US clients anyways so might as well just start right there for my server's security before getting into the brute force and injection preventions. So I got it all done compiled everything moved to the proper directory. I then started to setup my iptables. Like so

Code: iptables -F INPUT
iptables -F OUTPUT
iptables -I INPUT 1 -s *.*.*.* -p tcp --dport 22 -j ACCEPT
iptables -I INPUT 2 -s *.*.*.* -p tcp -j ACCEPT

[Code]...

After seeing that i went digging in the code and figured it was something todo with memory allocation.

View 1 Replies View Related

Server :: PPTP Traffic - Gre Traffic Is Being Generated During The Browsing / Reduce Traffic

Sep 27, 2009

Recently I notice that when I'm connected to an vpn server (pptpd) and I'm using it as a default gateway my download and upload speed decreases almost to the half of the usual speed. I made a test using iptables in order to count how much GRE packets are generated (except the real traffic itself) in that way:

Code:
iptables -I INPUT -p gre -j ACCEPT
iptables -I OUTPUT -p gre -j ACCEPT

iptables -I FORWARD -s 172.16.10.101 -j ACCEPT
iptables -I FORWARD -d 172.16.10.101 -j ACCEPT
The first 2 rules match all GRE packets between the pptpd server and client, and the next rules - the traffic between the server and the client.

When I turn the counters to zero and begin to generate traffic (to browse, to download etc.) I see that the GRE packets are even more than these in the FORWARD chain.

So, my question is first of all is my test correct and is it true that so much gre traffic is being generated during the browsing (it becames clear that the traffic is double than if the pptpd wasn't used as a gateway) and if yes - can that traffic be reduced?

View 3 Replies View Related

OpenSUSE Network :: Routing To The Internet By A Laptop With UMTS Connection?

Jun 7, 2011

I'm going to an area with no wired internet connection so I would gather information on if it is possible and how to make working the following configuration for an home network:

a wireless access point connected to a laptop (an old one with a centrino Duo) with a usb stick for UMTS connection to the internet it is possible to use the laptop for routing to the internet the requests (http, ftp, mail etc..) of the PC connected to the home LAN which software have I to install on the laptop?

View 9 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved