micahmo / WgServerforWindows

Wg Server for Windows (WS4W) is a desktop application that allows running and managing a WireGuard server endpoint on Windows
MIT License
822 stars 79 forks source link

I have no internet or network conection and everything seems ok #98

Closed koliflores closed 1 year ago

koliflores commented 1 year ago

Hi good night. I would like to thanks every people make this project true! its a great job.

Buy i have a problem i can't resolve. I have Windows 10 PRO 22H2 and i have installed the WS4W 2.0.8.0 and follow the instructions... Every parts of the list are in green, NAT Routing included

I opened the udp (also TCP) port to the phisical LAN adapter

But when i connect from the phone to my computer i have no internet on the phone, I dont know what to do and i need some help please!!!

What should i do???

sorry about my english! A lot of thanks!

koliflores commented 1 year ago

image

micahmo commented 1 year ago

Hi @koliflores,

Can you view the server status while you connect your phone? Do you see a successful handshake?

Can you also send screenshots of your server and client configs (if you feel comfortable doing that)? Remember to blank out the keys and public addresses.

koliflores commented 1 year ago

hi, thanks for your answer, i'll show you everything you need, i'm so interested to use this vpn server.

I can't see the handshake or i don't know how to see, when i connect from my phone to the server, i have no internet, on the phone. I make a ping to mi client ip and it answers but when i make ping to the server, it doesn't respond, it doesn't work. all packets lost.

Here is my server config: image

And here is my client config: image

The field "Latest Handshake" is in blank

My ethernet adapter has 192.168.1.3 private ip (manually added) And the port on the router is opened image

This is an screenshot from my phone with connection started, i don't have internet and in the browsers appears DNS_PROBE_STARTED image

And this is the SERVER STATUS... when the phone has the connection active image

Sorry about this large post, but i'm very interested to have my own vpn server with WS4W Thaks a lot. I hope you could help me!! THANKS!!!!!

I also tried with 10.253.0.0 range of private IPs

And this is WG_SERVER adapter screenshot image

micahmo commented 1 year ago

Thanks for all the details! Nothing stands out to me as obviously wrong, so this may be hard to diagnose.

The fact that there's no mention of a handshake in the server status is interesting. It means the clients can't even make the initial connection to the server (nevermind getting internet access). Here's an example of what a good handshake would look like.

image

Here are a couple things to check. Run these commands in PowerShell and let me know the results.

Get-NetNat -Name wg_server_nat

Get-NetNatExternalAddress -NatName wg_server_nat

netstat -anob | select-string wireguard.exe -context 1,0
koliflores commented 1 year ago

Hi, good night thanks for your answer!!

image

image

image

I don't know what i'm doing!! I'm in your hands!!

micahmo commented 1 year ago

I am also not always sure what I'm doing. 😄

Can you open the WireGuard application and go to the Logs tab and then attempt to connect the client?

This is what a successful handshake looks like.

image

koliflores commented 1 year ago

HI, here it is

image

Mi Android phone is connected with 4g to the Wireguard config

micahmo commented 1 year ago

Hey @koliflores, I'm a bit stumped here as everything you have looks good!

With regards to the WireGuard logs, did you attempt to connect your client while watching the logs?

The only other thing I can think of is that your mobile or home ISP have blocked that port. Could you try another port?

P.S. Your last screenshot shows your full domain name. Not sure if you want to hide that.

koliflores commented 1 year ago

Hi @micahmo I don't have word to thanks for your answers!!! A lot of thanks!!!!

With your answer I made my own investigation and finally I think I know what's the problem!!!!

When you said me that everything was right I used an Android application called "fing" to see if the ports were opened!!!!

It was a surprise to see that all of my opened ports were closed!!!!

I was reading across the internet about my ISP and my router model and there was the problem... I think!!

I am under a service called CG-NAT That service provide me an public IP but shared with other clients and it has closed all ports!!!!

I called my ISP to remove me from this CG-NAT service and in 24 hours I'll be out and I'll have my own public IP.

Then I could open the ports I need to my computer and I hope the VPN server and other services will work fine!!!!

I'll tell you every step that happens!!!!!

A million of thanks!!!!!!!!!!!!

micahmo commented 1 year ago

Hey @koliflores, I'm so glad to hear this update. Yes, CGNAT can be very problematic when it comes to exposing your home services. I assumed based on your router screenshot that you had had luck opening ports before, but maybe not. Anyway, having a dedicated IP will definitely help. Let me know if you're able to get it working after that!

koliflores commented 1 year ago

Mission done!!!!!!! It was the problem!!!! I was under CG-NAT service and today morning I'm out of this service..... I've just checked the ports were open and it WORKED!!!!!!! I'm using wireguard VPN server thanks to your support

I'm really so happy !!!!!

Can I support or collaborate with your project with a donation?????? And if the answer is yes...... How????

A lot of thanks for all your support!!!

micahmo commented 1 year ago

Hey @koliflores, I'm so glad to hear that this is resolved. The next step will be to ensure that everything continues to work after a restart. 😊

If you wish to donate, there is a Buy Me a Coffee link on my GitHub profile, but please never feel obligated to, especially since I can't always promise support. I just work on this project as a hobby.