Link to home
Start Free TrialLog in
Avatar of demallic
demallic

asked on

Sharing Network Connection in VMware

Hi guys,

I have some trouble setting up a shared network connection in VMware for man in the middle. This is pretty straight forward when I do it without VMware as I can simply use Laptop A as mitm but I need to get this working on VMware.

Here's my setup:
Laptop A has a Linux distro (Backtrack) setup in VMware.
Laptop A is connected the network on its NIC.
Laptop B is connected to Laptop A via USB port with a "USB to Ethernet" adapter.

I need the Backtrack VM on Laptop A to act as man in the middle between Laptop B and the network that Laptop A is connected to. I tried configuring a bridge, NAT, and host only connection on VMware, and then shared the internet from Laptop A NIC to the VM NIC interface. Anyone tried sharing network between an onboard NIC and a USB NIC interface, and have it work on VMware? What's the proper way to do this?

Thanks all and happy new year!
Avatar of Abhilash
Abhilash

Hi demallic,

If MITM is what you want to achieve immaterial of where you want to do it, you could do it using three Virtual machines using  VMware workstation.

If its a must that you need to do this with the setup you are talking about. It kind of gets tricky because of the networking in workstation.

Host only is out of question here as it is used only when you have a internal communication between the virtual machines. But in your case you need to talk to the network outside.

When you use NAT there is no separate IP shown for your VM on the external network.
Instead, a separate private network is set up on the host computer. this too is out of question as you need the VM to have a IP to test pinging and other things while performing the MITM.

Now lets get to Bridged. Bridged networking connects a virtual machine to a network using the host computer’s Ethernet adapter. If your host computer is on an Ethernet network ,this is often the easiest way to give your virtual machine access to that network. If you use bridged networking, your vm is a full participant in the network. It has access to other machines on the network and can be contacted by other machines on the network as if it were a physical computer on the network.

You need to try getting it work with Bridged.
But my suggestion would be to either go with three VM's and try it
Or try it with three physical machines. The mixing of both gets it complicated.
Avatar of demallic

ASKER

Thanks Abhilashhb! Unfortunately, I have to use the mixed setup with physical machine and a VM.

When I tried the Bridged network setup the VM was able to get DHCP fine but I'm not sure how to setup MITM without affecting the entire network.

So here's what I have for Bridged network:
VM bridged to Laptop A's Network on ethernet interface.
Laptop B gets shared network from Laptop A.
VM man in the middle as Laptop A to get all the traffic.

This doesn't work as Laptop B isn't getting the IP correctly... does Laptop A need to configure DHCP or manually assign static IP to Laptop B?

Thanks again!
As far as all the three(Laptop A, the VM and the laptop B) fall in the same subnet and are able  to ping each other it should be fine. That way the VM can act as MITM.
The problem is that Laptop B isn't getting DHCP and it can't talk to the network. Also it's kind of risky to MITM in our network, I'd like to setup a private subnet for the VM and Laptop B.
Assign a Static IP for the Laptop B in the DHCP range of VM. That would put all three of them in their own private subnet.
But Laptop B is getting DHCP from our production network via the Bridged Connection. Anyway to have it bridged and still assign a static IP?
ASKER CERTIFIED SOLUTION
Avatar of Abhilash
Abhilash

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial