Got a WSL2 Kali-linux machine on my windows.
For some reason WSL2 has issues with network adapters. It only shows a specific network adapter with an address of 172.xxx.xxx.xxx.
The problem is I can't interact directly with other IPs assigned to me. For example - listen on a specific address.
I do cyber security so one scenario where it implicates my work is:
- got a vpn local address assigned to me, say 10.7.3.120 (configured through my windows host)
- I run code on a remote machine that suppose to connect back to me
Now, I need to put an an hardcoded IP address in the code:
- if I hardcode 172.1.11.11 my wsl will be able to bind incoming connection but the remote machine won't know how to reach me
- if I hardcode 10.7.3.120 the remote machine will able to reach me but wsl won't let me bind because it doesn't recognizes that address
I hope this scenario will be able explain the problem correctly.
Thanks.
ping 8.8.8.8? Some VPN's operate in a full tunnel mode that will essentially "kill" any other VM adapters' networking (such as WSL2). Need to know if that is the case, since it may change how we approach it. – NotTheDr01ds Feb 02 '21 at 23:54