mirror of
https://github.com/amnezia-vpn/amneziawg-linux-kernel-module.git
synced 2026-12-03 19:22:43 +07:00
[PR #270] fix: record handshake completion when sending handshake response #271
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-linux-kernel-module#271
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?
📋 Pull Request Information
Original PR: https://github.com/amnezia-vpn/amneziawg-linux-kernel-module/pull/270
Author: @mvkvl
Created: 10/14/2026
Status: 🔄 Open
Base:
master← Head:pr1-handshake📝 Commits (1)
054f3d3fix: record handshake completion when sending handshake response📊 Changes
1 file changed (+1 additions, -0 deletions)
View changed files
📝
src/send.c(+1 -0)📄 Description
Title
fix: record handshake completion when sending handshake response
Body
Problem
The responder never called
wg_timers_handshake_complete()after beginninga session in
wg_packet_send_handshake_response(). As a result,walltime_last_handshakewas only stamped later viawg_noise_received_with_keypair()on the initiator's first data packet.When no data packet followed (idle peers, userspace peers with constant
rekeys), the timestamp froze and kernel supervision saw a stale
last_handshake, masking peer death.Fix
Call
wg_timers_handshake_complete()right after session derivation inwg_packet_send_handshake_response(), mirroring the initiator path inwg_packet_consume_handshake().Impact
One-line change in
src/send.c. No behavioural change for active peers;only the handshake timestamp is recorded earlier for idle/responder-only
sessions.
Testing
master(4569c4c) on Debian 13 (kernel 6.12.x).last_handshakenowupdates immediately after handshake response, without requiring a
subsequent data packet.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.