Last thing we need to set up is maximum MSS for TCP packets, which is 40 bytes smaller than the MTU of WireGuard, by default Wireguard uses 1420 bytes MTU. So we need to set an MSS maximum of 1380. (Without this you may have issues loading websites or slow speeds). Goto Firewall: Settings: Normalization 1. Click Add 2. Interface select "WAN_PIAWG" 3. Enter Description of "Maximum MSS for PIA WireGuard Tunnel" 4. Max MSS to "1380" 5. Save (you will notice it'll now list this as OPT rather than the interface name, don't worry it's still correct, just edit it to verify you made the right selection)
Hey brother,I'm trying to get your script running and I'm stuck at instruction #5.I had copied the file over, ran chmod, restarted the service, and then ran debug but I got a bunch of errors and I thought it was because I didn't have the formatting correct on the file (edited it in wordpad) -- I deleted the PIAWireguard.py and got a proper file editor Notepad++, and have re-edited the file and uploaded it, ran chmod, and restarted the configd -- when I run debug, now I just get this error,'command not found'.thank you for providing this script -- I really hope I get it working soon =)
New to OPNsense but had no problem following along the guide and script and got the gateway online But then, the final step, Step 13 ... fail ... any clues on how to route all LAN traffic over the new wireguard gateway? Googling just ends up with a spattering of pages that don't match the current version 21.1.1
https://github.com/FingerlessGlov3s/OPNsensePIAWireguardAny question just ask and any issues make an issue on Github.
**Looks around slowly and raises hand sheepishly after several months of inactivity in thread...**I used this script to set up a PIA WG tunnel . Worked great Now I am hoping to set up multiple WG tunnels.How would I go about this? The idea is a tunnel for US & UK in addition to my existing tunnel.If I run the primary script again, will it break the existing connection? Do I need to go right back and create a new API for example, or can I start further along in the process?
opnsenseWGName = 'PIAUS'opnsenseWGPort = "51816"piaRegionId = "us_silicon_valley"
[piaWireGuardUS]command:/conf/PIAWireguard_US.pyparameters: %s %stype:script_outputmessage:Running PIA WireGuard US Script : /conf/PIAWireguard_US.py %s %sdescription:PIA WireGuard US
configd restart
/conf/PIAWireguard_US.py debug