mirror of
https://github.com/amnezia-vpn/amneziawg-tools.git
synced 2026-10-13 21:34:42 +00:00
[GH-ISSUE #55] h1 and h2 Broken #22
Labels
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
amnezia-vpn/amneziawg-tools#22
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @SWAGcreator-del on GitHub (Jun 21, 2026).
Original GitHub issue: https://github.com/amnezia-vpn/amneziawg-tools/issues/55
Title: H1 and H2 values are truncated after awg-quick up
Environment:
Config:
H1 = 424258794
H2 = 1552734037
H3 = 136716108
H4 = 329527368
Problem:
After running:
sudo awg-quick up wg0
the interface is created successfully, but VPN does not work.
Checking runtime values:
sudo awg show wg0 h1
returns:
1
and
sudo awg show wg0 h2
returns:
2
while H3 and H4 are loaded correctly.
As a result:
Workaround:
Running:
sudo awg set wg0 h1 424258794
sudo awg set wg0 h2 1552734037
immediately restores connectivity and handshake starts working.
This suggests that awg setconf (used by awg-quick) may incorrectly parse or apply H1/H2 values.
@SWAGcreator-del commented on GitHub (Jun 22, 2026):
I did some additional testing.
It looks like the actual values configured in wg0.conf do not matter for this issue.
For example, my configuration originally contained:
H1 = 424258794
H2 = 1552734037
I changed both values to completely different numbers, restarted the interface, and observed exactly the same behavior:
and returns 0, RX stays at 0, and only TX increases.
No matter what values are specified in the configuration file, after awg-quick up the runtime values become H1 = 1 and H2 = 2.
The only way to make the tunnel work is to manually apply the values afterwards:
After doing that, handshakes immediately start working.
This suggests that awg-quick or awg setconf is not simply reading the wrong values back from the kernel. Instead, H1 and H2 appear to be applied incorrectly during interface configuration and are always replaced with 1 and 2 regardless of the values present in the configuration file.
@ygurov commented on GitHub (Jun 22, 2026):
Hi @SWAGcreator-del
Please check this issue https://github.com/amnezia-vpn/amneziawg-tools/issues/51
Has been fixed in v1.0.20260618-2