Racking my and ChatGPT’s brain and still can’t work out why my phone isn’t being detected by PiVPN
The PiVPN AllowedIPs for your phone should be that phone’s desired IP inside the tunnel. It should not be 0.0.0.0/0.
Don’t ever use ChatGPT. People stop actually using their brains. Just read the fucking manual. And read it until you understand it. LLM‘s are a curse and shouldn’t exist other than for entertainment maybe.
On the phone, listen port should be 51820, match with wg config.
Change the Address in the peer config from /24 to /32 otherwise routing to the network won’t work. Since you have 0.0.0.0 in your AllowedIPs this should work. If changing this add the Network with /24 there.
first, is your endpoint a public ip address/domain name resolving to a public ip address?
second, include a port in endpoint section of your config on your phone like this: subdomain.example.com:12345
Setup port forwarding for UDP for that port (eg. 12345 according to my example) on your router to the server
Can you ping your server/computer? In some cases the ISP would put you behind a NAT and in this case something like wire guard will not work because the NAT will drop the connection to port 51820 before reaching your server. Something like NO IP won’t help in this situation. You have to check if your server is really reachable from the Internet. ( ssh maybe)
I believe 0.0.0.0 allowed ip means allow all. Restart your wg service or device
I didn’t think I had a desired IP inside the tunnel?
I initially followed a YouTube tutorial, did everything correctly but then still had a non working result
I’ll have a go at this tomorrow. Approaching 11pm here now
Yes I’ve done all those. I’m using noip to track my public address. I’ve tried pinging my noip host name and it gives me my public address back.
Do you mean when connected to the vpn? I can’t ping anything, they’re all unreachable
mhm yeah, open 22 to the whole internet.You would know they are not behind CGNAT if you read other comments
It’s solved. Just changed flair now. I hadn’t set my ip correctly when port forwarding on my router.
Your second screenshot has AllowedIPs = 0.0.0.0/0
in the [Peer]
section. That should be set to AllowedIPs = 10.180.160.2/32
or /24.
Have you solved it? Can you indicate how?
I don’t mean to appear condescending but are you 100% sure it is a public IP address and not CGNAT (100.x.x.x)?
Well the port can be changed, and yes for testing purposes I would surely do that. Special when I am not sure what exactly the infrastructure of my ISP is. I was in a similar situation and later discovered that my local network was behind a NAT, I had to get an VPS and use a wire guard tunnel to solve the issue.
I’ve been following this network adventure of yours. I’m glad to hear you figured it out. I’m trying to get a wireguard tunnel which is reverse proxied from an Ubuntu cloud server to my phone and it’s driving me nuts. I got a successful handshake and the wireguard Android app has rx and tx data on both but I can’t ping or netcat. I read that ya can’t ping a machine that’s at the end of reverse proxy so I’m not trippin about that but the netcat doesn’t do shit. Plus, I’m so new at IT stuff I can visualize some of the traffic flow but I get hung up on DNS. I’m using a domain name and port number as the proxy machine’s IP address for the endpoint. I’m wondering since I’m mainly configuring this on ATT LTE network, how much of a problem CGNAT will be? I’ve got a bunch of questions. I think I’m gonna start a freakin discussion on this shit!! Yeah!!! Haha! Should the proxy server have 0.0.0.0 in the AllowedIPs and my phone’s AllowedIPs should be just the wireguard private IP/32?