[PR #4655] AmneziaWG support #26007

Open
opened 2026-08-05 07:06:45 -04:00 by saavagebueno · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/netbirdio/netbird/pull/4655
Author: @spikeyspik
Created: 10/16/2025
Status: 🔄 Open

Base: mainHead: main


📝 Commits (7)

  • 31b344f update to amneziawg
  • 4fc47ab update devcontainer.json Golang version
  • 36dec3d amneziawg management service support
  • 71919f0 amneziawg client support
  • 6e9f4cf fix: fixes after proper testing
  • 6aade8b fixes for mobile platforms + attempt to solve complexity
  • 32e0211 remove unused constant

📊 Changes

55 files changed (+1356 additions, -643 deletions)

View changed files

📝 .devcontainer/Dockerfile (+2 -2)
📝 .devcontainer/devcontainer.json (+2 -2)
📝 client/embed/embed.go (+1 -1)
📝 client/firewall/iface.go (+1 -1)
📝 client/firewall/uspfilter/common/iface.go (+1 -1)
📝 client/firewall/uspfilter/filter_filter_test.go (+1 -1)
📝 client/firewall/uspfilter/filter_test.go (+1 -1)
📝 client/firewall/uspfilter/forwarder/endpoint.go (+1 -1)
📝 client/iface/bind/control.go (+1 -1)
📝 client/iface/bind/endpoint.go (+1 -1)
📝 client/iface/bind/ice_bind.go (+1 -1)
📝 client/iface/bind/relay_bind.go (+1 -1)
client/iface/configurer/amnezia_config.go (+21 -0)
📝 client/iface/configurer/uapi.go (+1 -1)
📝 client/iface/configurer/uapi_windows.go (+1 -1)
📝 client/iface/configurer/usp.go (+65 -10)
📝 client/iface/device.go (+2 -2)
📝 client/iface/device/device_android.go (+14 -12)
📝 client/iface/device/device_darwin.go (+13 -11)
📝 client/iface/device/device_filter.go (+1 -1)

...and 35 more files

📄 Description

Describe your changes

Replaced standard Wireguard implementation with AmneziaWG.
It's backward compatible with standard implementation if none of settings are set so it shouldn't break outdated clients.

I used management as a place to setup settings and pass it to every peer.
There are some issues with kernel wireguard implementation so I still looking forward for better solution if there is any.

In order to merge this we also need to:

  1. Create repository https://github.com/spikeyspik/amneziawg-go
  2. Create repository https://github.com/spikeyspik/amneziawg-windows
  3. Refactor changes to use new repositories as dependency
    These repositories contain same fixes as yours, but based on amneziawg implementation instead of standard.

1096

Stack

Checklist

  • Is it a bug fix
  • Is a typo/documentation fix
  • Is a feature enhancement
  • It is a refactor
  • Created tests that fail without the change (if possible)

By submitting this pull request, you confirm that you have read and agree to the terms of the Contributor License Agreement.

Documentation

Select exactly one:

  • I added/updated documentation for this change
  • Documentation is not needed for this change (explain why)

Docs PR URL (required if "docs added" is checked)

454


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/netbirdio/netbird/pull/4655 **Author:** [@spikeyspik](https://github.com/spikeyspik) **Created:** 10/16/2025 **Status:** 🔄 Open **Base:** `main` ← **Head:** `main` --- ### 📝 Commits (7) - [`31b344f`](https://github.com/netbirdio/netbird/commit/31b344f19c05d683b465a4561d9a024dd19f97da) update to amneziawg - [`4fc47ab`](https://github.com/netbirdio/netbird/commit/4fc47abef5215e424fae55b9f1ef5f54bd52a1fd) update devcontainer.json Golang version - [`36dec3d`](https://github.com/netbirdio/netbird/commit/36dec3d5cc98132ab2fa2940bea9ab4c385220d7) amneziawg management service support - [`71919f0`](https://github.com/netbirdio/netbird/commit/71919f0bc54b6024210e10f91452b07c0f5e0aac) amneziawg client support - [`6e9f4cf`](https://github.com/netbirdio/netbird/commit/6e9f4cf654e788d9221dcccdcfeb534a273a237a) fix: fixes after proper testing - [`6aade8b`](https://github.com/netbirdio/netbird/commit/6aade8bf749a1311e5ceb1a30bd975da5bc2c577) fixes for mobile platforms + attempt to solve complexity - [`32e0211`](https://github.com/netbirdio/netbird/commit/32e021187612f3743d6993455ac910855fa773a7) remove unused constant ### 📊 Changes **55 files changed** (+1356 additions, -643 deletions) <details> <summary>View changed files</summary> 📝 `.devcontainer/Dockerfile` (+2 -2) 📝 `.devcontainer/devcontainer.json` (+2 -2) 📝 `client/embed/embed.go` (+1 -1) 📝 `client/firewall/iface.go` (+1 -1) 📝 `client/firewall/uspfilter/common/iface.go` (+1 -1) 📝 `client/firewall/uspfilter/filter_filter_test.go` (+1 -1) 📝 `client/firewall/uspfilter/filter_test.go` (+1 -1) 📝 `client/firewall/uspfilter/forwarder/endpoint.go` (+1 -1) 📝 `client/iface/bind/control.go` (+1 -1) 📝 `client/iface/bind/endpoint.go` (+1 -1) 📝 `client/iface/bind/ice_bind.go` (+1 -1) 📝 `client/iface/bind/relay_bind.go` (+1 -1) ➕ `client/iface/configurer/amnezia_config.go` (+21 -0) 📝 `client/iface/configurer/uapi.go` (+1 -1) 📝 `client/iface/configurer/uapi_windows.go` (+1 -1) 📝 `client/iface/configurer/usp.go` (+65 -10) 📝 `client/iface/device.go` (+2 -2) 📝 `client/iface/device/device_android.go` (+14 -12) 📝 `client/iface/device/device_darwin.go` (+13 -11) 📝 `client/iface/device/device_filter.go` (+1 -1) _...and 35 more files_ </details> ### 📄 Description ## Describe your changes Replaced standard Wireguard implementation with AmneziaWG. It's backward compatible with standard implementation if none of settings are set so it shouldn't break outdated clients. I used management as a place to setup settings and pass it to every peer. There are some issues with kernel wireguard implementation so I still looking forward for better solution if there is any. In order to merge this we also need to: 1. Create repository https://github.com/spikeyspik/amneziawg-go 2. Create repository https://github.com/spikeyspik/amneziawg-windows 3. Refactor changes to use new repositories as dependency These repositories contain same fixes as yours, but based on amneziawg implementation instead of standard. [1096](https://github.com/netbirdio/netbird/issues/1096) ## Stack <!-- branch-stack --> ### Checklist - [ ] Is it a bug fix - [ ] Is a typo/documentation fix - [x] Is a feature enhancement - [ ] It is a refactor - [ ] Created tests that fail without the change (if possible) > By submitting this pull request, you confirm that you have read and agree to the terms of the [Contributor License Agreement](https://github.com/netbirdio/netbird/blob/main/CONTRIBUTOR_LICENSE_AGREEMENT.md). ## Documentation Select exactly one: - [x] I added/updated documentation for this change - [ ] Documentation is **not needed** for this change (explain why) ### Docs PR URL (required if "docs added" is checked) [454](https://github.com/netbirdio/docs/pull/454) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
saavagebueno added the pull-request label 2026-08-05 07:06:45 -04:00
Sign in to join this conversation.
No Label pull-request
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: DYNR/netbird#26007