binhex / arch-privoxyvpn

Docker build script for Arch Linux base with Privoxy and OpenVPN
GNU General Public License v3.0
113 stars 25 forks source link

support for wireguard through wireguard-go or userspace #28

Open carmatana opened 1 year ago

carmatana commented 1 year ago

I understand that some synologys devices, mine included, their kernel is too old to support wireguard.

however thera are other vpn containers that are supporting wireguard using wireguard-go or something called userspace.

I am running:

https://github.com/thrnz/docker-wireguard-pia

without problems

I share the logs of this container in case they help:

Fetching next-gen PIA server list
Verified OK
Verified server list
Registering public key with PIA endpoint; id: ca_toronto, cn: toronto403, ip: 66.115.142.75
Generating /etc/wireguard/wg0.conf
Using PIA DNS servers: 10.0.0.243,10.0.0.242
Port forwarding is available at this location
[#] ip link add wg0 type wireguard
RTNETLINK answers: Not supported
[!] Missing WireGuard kernel module. Falling back to slow userspace implementation.
[#] wireguard-go wg0
┌──────────────────────────────────────────────────────┐
│                                                      │
│   Running wireguard-go is not required because this  │
│   kernel has first class support for WireGuard. For  │
│   information on installing the kernel module,       │
│   please visit:                                      │
│         https://www.wireguard.com/install/           │
│                                                      │
Successfully generated /etc/wireguard/wg0.conf
Thu Jun 15 19:05:27 UTC 2023: Bringing up WireGuard interface wg0
└──────────────────────────────────────────────────────┘
[#] wg setconf wg0 /dev/fd/63
[#] ip -4 address add 10.9.247.226 dev wg0
[#] ip link set mtu 1420 up dev wg0
[#] resolvconf -a wg0 -m 0 -x
[#] wg set wg0 fwmark 51820
[#] ip -4 route add 0.0.0.0/0 dev wg0 table 51820
[#] ip -4 rule add not fwmark 51820 table 51820
[#] ip -4 rule add table main suppress_prefixlength 0
[#] iptables-restore -n
iptables-restore v1.8.9 (legacy): iptables-restore: unable to initialize table 'raw'
Error occurred at line: 1
Try `iptables-restore -h' or 'iptables-restore --help' for more information.
interface: wg0
  public key: bHhrvRXGdHb5DqFdORDLbteEWV4uLdW+MfTKtkizVk0=
  private key: (hidden)
  listening port: 48824
  fwmark: 0xca6c
peer: 5kF+lR9H2iuIuADjZ27OP//AK/ULli5fgWhQrSZqM2k=
  endpoint: 66.115.142.75:1337
  allowed ips: 0.0.0.0/0
Thu Jun 15 19:05:29 UTC 2023: WireGuard successfully started
Thu Jun 15 19:05:29 UTC 2023: Allowing network access to 172.17.0.2/16 on eth0
Thu Jun 15 19:05:29 UTC 2023: Allowing network access to  on sit0
iptables v1.8.9 (legacy): host/network `' not found
Try `iptables -h' or 'iptables --help' for more information.
iptables v1.8.9 (legacy): host/network `' not found
Try `iptables -h' or 'iptables --help' for more information.
Device "syno_ovs_bonds" does not exist.
Thu Jun 15 19:05:29 UTC 2023: Allowing network access to  on syno_ovs_bonds
iptables v1.8.9 (legacy): host/network `' not found
Try `iptables -h' or 'iptables --help' for more information.
iptables v1.8.9 (legacy): host/network `' not found
Try `iptables -h' or 'iptables --help' for more information.
Thu Jun 15 19:05:29 UTC 2023: Firewall enabled: Blocking non-WireGuard traffic
Thu Jun 15 19:05:29 UTC 2023: Allowing network access to 192.168.1.0/24 on eth0
Thu Jun 15 19:05:29 UTC 2023: Adding route to 192.168.1.0/24

it will be nice if your container would do the same.

Thanks for the attention