How to configure DPDK application working as L3 device to filter traffic between external network and LAN - nat

Please suggest ideas to configure NAT for DPDK application working as L3 device to filter traffic between external network and LAN.

Related

Networking with devices in local network

I have a local home network (my router) I have a raspberry pi setup as a web server. I do not want the web server to be access from devices outside my home network. I only want local devices to connect to the web server. I belief I am able to do this like (raspberrypi.local). Do I have to port forward on the router for local devices to connect to the pi or is port forwarding used for external devices outside the network
Port forwarding is used to access internal network ports from outside.

How to use the RJ45 tool in the CORE network emulator?

I have recently installed the CORE Network Emulator, and have already read the relevant parts of the the docs. CORE promises to be able to connect the virtual networks you create in it with physical once. However, I am having trouble connecting my virtual network to the physical one, which the RJ45 tool promises to do. From what I have read, in the CORE NetEm you can assign a network interface to the RJ45 tool, which then bridges your physical device to the network.
I have tried creating a basic topology, with one virtual host, a router, and then my computer with the RJ45 tool and I am trying to see if I can reach my computer from the host or vice versa with a ping command, but all I get is "network is unreachable."
Unfortunately, the CORE docs don't go into detail in how to use this tool and I wasn't able to find any other sources on the internet which have to do anything with it.
Here you can find the documenation: http://coreemu.github.io/core/usage.html#connecting-with-physical-networks
Does anyone have any experience with CORE and can help me out with this?
Many thanks!
The CORE RJ45 tool creates a Linux bridge between a virtual interface and a physical one.
Example: if you have node n1 linked to an RJ45 node assigned to eth0, after pressing "Start", on the underlying host you'll have a bridge with the n1:eth0 veth0 pair device and your host's eth0 device enslaved.
You'll need to configure routing between your virtual and physical networks. In the above example, suppose n1:eth0 is 10.0.0.1/24. When you plug a physical device into eth0, that device needs a route back to 10.0.0.1. That device may be on the same subnet, for example if it has the address 10.0.0.2/24. If your physical device has an address on a different subnet, you'll need to manually add a route to reach the 10.0.0.0/24 network, via the connecting interface.
I had the same problem. My CORE version is v.5.3.0 (20190615) on Ubuntu 18.04 LTS w/ Linux 5.0.0-37 generic on x86_64. Have OSPF v2, v3, Zegra, and IPForward correctly configured at r1, so that vpc1 can send and receive data successfully.
The RJ45 port of a built-in physical interface on the CORE host was mapped to a virtual endpoint for connecting the 2nd real computer, rpc 192.168.10.10/24 with a virtual switch sw1. Another virtual PC, vpc1 192.168.10.20/24 and a router r1 with 192.168.10.1/24 and 10.0.10.1/24 two interfaces.
Can ping from rpc to vpc1 and to r1 at 192.168.10.1 but not 10.0.10.1 or beyond. However, using the two-node tool or virtual terminal of vpc1, I can also traceroute and ping r1 and beyond.
The reason why the traffic of the real remote PC rpc could not be routed by r1 from 192.168.10.1 to 10.0.10.1 and back was because its WiFi was left on with the gateway configured to a FiOS router. You cannot have two gateways. Once the WiFi got turned off, the traceroute and ping can reach r1 and beyond.
This could also be the root cause of your problem.

VM guest not accessible from Host (with running VPN Client)

I have configured my guest VM as described here: https://askubuntu.com/a/293817/503589
Unfortunately I cannot connect to the guest via IP or "localhost", if the Cisco AnyConnect VPN Client is connected on the host (Windows 7).
It works as long as I am not connected with the Cisco VPN AnyConnect Client on the host.
My requirements are the following:
the host should be able to access the guest with it's static IP, whether I am connected to host VPN or not.
I am working remote (WLAN) or in the office (LAN). In the office it's working, because I have no Cisco VPN Client connected.
guest can access the internet
I can move my laptop from network to network (e.g. from home to office to coffeeshop) without worrying about securing or reconfiguring the vm
What I also already tried and what didn't work:
NAT
Bridged
The Cisco VPN client is likely configured for full tunneling. Meaning all traffic is routed through the VPN interface. This is why you are unable to reach other hosts on your LAN.
You might be able to request a split-tunneled profile from your Network team, but it may go against company policy.

How to setup DD-WRT between two routers with NAT

I have two networks.
Network A has both wired and wireless clients and is connected to the internet. DHCP ENABLED (10.0.0.1 with subnet 255.255.255.0)
Network B has both wired and wireless clients and is NOT connected to internet. DHCP ENABLED (192.168.1.1 with subnet 255.255.255.0) This means the WAN port of this network is not connected.
I need to connect the WAN port of Network 2 WIRELESSLY to Network A such that Network B shows up as nothing but a client in Network A. Since BOTH networks have wireless clients it's to assume that WPA is used for security.
Can anyone tell me how to set this up using DD-WRT.
Thanks
you should connect your network B device to network A device and add a static route to route client on router B reach to internet , and config router B DHCP to get the user the new gateway which is the router A ip address.

Communicate to a web application via application that is running on a PC that is connected to internet via Wifi

This is my application setup.
I have written an application (in Qt ) which will run on a linux computer (Ubuntu). The application accepts requests from web app and sends them to a serial device that is connected to the computer. Also application will send back the response to web app as well. This linux computer is connected to internet via wifi router.
Now my question is, Is there a way (other than port forwarding in wifi router) that I can achieve this functionality. Using port forwarding I can ask the router to forward the requests coming for a particular port to my computer at a particular port and my application would be listening for that. But for that I would have to configure the router and I don't want to do that. Is there a way I can do that automatically?
Thanks,
DPatel
Your issue is traversing non-routable NAT addresses.
UPNP is an option: http://en.wikipedia.org/wiki/Universal_Plug_and_Play
It will automatically configure port forwarding.
There is a library out there called STUNT for this as well:
http://nutss.gforge.cis.cornell.edu/stunt.php

Resources