A question about "NAT".

This is for discussing general topics about how to use VirtualBox.
Locked
hack3rcon
Posts: 204
Joined: 28. Feb 2016, 10:44

A question about "NAT".

Post by hack3rcon »

Hello.
I installed VirtualBox on Linux host and installed a Windows 7 as VM. In Windows VM I used "PsTools" for run "CMD.EXE" on a remote Windows client. I set my windows VM network as "NAT" and its IP is "10.0.2.15", But on Windows client "Event Log" my IP is my Linux IP and not "10.0.2.15". Why?


Thank you.
Attachments
Screenshot-5.png
Screenshot-5.png (17.37 KiB) Viewed 3058 times
Capture.PNG
Capture.PNG (12.99 KiB) Viewed 3058 times
mpack
Site Moderator
Posts: 39134
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: A question about "NAT".

Post by mpack »

Your question makes no sense to me - on multiple levels.

Level 1: you don't set the IP address to be used by NAT. It has a DHCP server, it doesn't need your help to choose IP addresses. Please show a screenshot of where you configured the NAT IP DHCP function.

Level 2: your own screenshot shows that 10.0.2.15 is indeed the IP address of the Win7 PC.
BillG
Volunteer
Posts: 5102
Joined: 19. Sep 2009, 04:44
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Windows 10,7 and earlier
Location: Sydney, Australia

Re: A question about "NAT".

Post by BillG »

You would be in serious trouble if your host and guest had the same IP!

If you try to access the vm from outside, you will see the IP of the host. That has nothing to do with VirtualBox. That is how NAT works. The "private" address is never used on the "public" network. All traffic on the public network uses the NAT server's public IP.

NAT was developed to allow a number of machines on a private LAN to share a single IPv4 public IP. That is why the terminology talks about "public" and "private" interfaces. NAT will work fine if both sides are private networks, it is just historical.
Bill
hack3rcon
Posts: 204
Joined: 28. Feb 2016, 10:44

Re: A question about "NAT".

Post by hack3rcon »

mpack wrote:Your question makes no sense to me - on multiple levels.

Level 1: you don't set the IP address to be used by NAT. It has a DHCP server, it doesn't need your help to choose IP addresses. Please show a screenshot of where you configured the NAT IP DHCP function.

Level 2: your own screenshot shows that 10.0.2.15 is indeed the IP address of the Win7 PC.
I never set any IP and I know "NAT" is DHCP.
My Linux host IP is 192.168.1.1 and I want to know why when I browse a remote PC share then the Windows Event Log show my host IP(192.168.1.1) not 10.0.2.15
hack3rcon
Posts: 204
Joined: 28. Feb 2016, 10:44

Re: A question about "NAT".

Post by hack3rcon »

BillG wrote:You would be in serious trouble if your host and guest had the same IP!

If you try to access the vm from outside, you will see the IP of the host. That has nothing to do with VirtualBox. That is how NAT works. The "private" address is never used on the "public" network. All traffic on the public network uses the NAT server's public IP.

NAT was developed to allow a number of machines on a private LAN to share a single IPv4 public IP. That is why the terminology talks about "public" and "private" interfaces. NAT will work fine if both sides are private networks, it is just historical.
Host and Guest not have any same IP.
Thus it is natural?
socratis
Site Moderator
Posts: 27329
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: A question about "NAT".

Post by socratis »

hack3rcon wrote:My Linux host IP is 192.168.1.1 and I want to know why when I browse a remote PC share then the Windows Event Log show my host IP(192.168.1.1) not 10.0.2.15
Because that's the IP that you access the remote PC share with. The 10.0.2.15 only has a meaning as long as it's used within your host/guest. That's how all the NAT networks work. Try reading the related Wikipedia article (https://en.wikipedia.org/wiki/Network_a ... ranslation).

For example, you most probably have a network router at your location, which enables multiple computers in the 192.168.1.x range to access the internet. That's NAT at work. For me, your IP is the one that your router has on the WAN side (your "exit" address). For your message for example, I don't see 192.168.1.1, I see 212.129.36.xx.

But I would expect that you'd know details like these since you came from "hide.hackbbs.org"... ;)
Do NOT send me Personal Messages (PMs) for troubleshooting, they are simply deleted.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
hack3rcon
Posts: 204
Joined: 28. Feb 2016, 10:44

Re: A question about "NAT".

Post by hack3rcon »

I'm surprised because you don't know that you must not reveal my IP and you don't know that when you reveal my domain then Ping command can reveal the IP address and 212.129.36.xx is useless!!!!!
Please remove this [%&#*] and keep my privacy. Don't forget hackers learning always.
mpack
Site Moderator
Posts: 39134
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: A question about "NAT".

Post by mpack »

You reported a moderators post to the moderators??? Your report is nonsense - and please do not raise any more nonsensical reports.

IP and MAC addresses on virtual networks are as virtual as the networks they are on. There is no way they can be used to identify you. In any case Socratis merely quoted your own post, so the revelations were your own. How on earth could it be otherwise?

You have a habit of making these ridiculous statements and then going off on a tangent when your nonsense is addressed seriously... To the point where we have suspected that the apparant idiocy is faked, and you might be a troll. Do not do that again either. Stick to the point, and I suggest you do not try to instruct others until you have reached a minimum level of competence yourself. If I see any more evidence of trolling then I will take action to stop it.
socratis
Site Moderator
Posts: 27329
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: A question about "NAT".

Post by socratis »

hack3rcon wrote:Don't forget hackers learning always.
So do admins...
I think we're done covering the A-B-C basics here. For more information, please use your favorite search engine...
Do NOT send me Personal Messages (PMs) for troubleshooting, they are simply deleted.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
Locked