mirror of
https://github.com/kernelkit/infix.git
synced 2026-08-05 23:23:02 +02:00
Almost full support for WireGuard
admin@server:/> show interface wg0
name : wg0
type : wireguard
index : 10
mtu : 1420
operational status : up
ipv4 addresses : 10.0.0.1/24 (static)
ipv6 addresses : fd00::1/64 (static)
peers : 2
Peer 1:
public key : ROaZyvJc5DzA2XUAAeTj2YlwDsy2w0lr3t+rWj2imAk=
status : UP
endpoint : 192.168.10.2:51821
latest handshake : 2025-12-09T22:51:38+00:00
transfer tx : 1412 bytes
transfer rx : 1324 bytes
Peer 2:
public key : Om9CPLYdK3l93GauKrq5WXo/gbcD+1CeqFpobRLLkB4=
status : UP
endpoint : 2001:db8:3c4d:20::2:51822
latest handshake : 2025-12-09T22:51:38+00:00
transfer tx : 1812 bytes
transfer rx : 428 bytes
in-octets : 1752
out-octets : 3224
admin@server:/>
46 lines
1.5 KiB
Plaintext
46 lines
1.5 KiB
Plaintext
=== WireGuard Point-to-Point
|
|
|
|
ifdef::topdoc[:imagesdir: {topdoc}../../test/case/interfaces/wireguard_p2p]
|
|
|
|
==== Description
|
|
|
|
Set up a WireGuard tunnel between two DUTs with a host connected to the first
|
|
DUT. Enable IP forwarding on first DUT's interface to host and the WireGuard
|
|
tunnel interface to the second DUT. On host, add route to IP network of second
|
|
DUT and verify connectivity with the second DUT through the WireGuard tunnel.
|
|
|
|
This test verifies:
|
|
|
|
- WireGuard tunnel establishment between two peers
|
|
- Key management via ietf-keystore with X25519 keypairs
|
|
- IPv4 and IPv6 connectivity through the encrypted tunnel
|
|
- Proper routing through the WireGuard tunnel
|
|
|
|
Topology:
|
|
....
|
|
192.168.50.0/24
|
|
host:data ---- left:data left:link ---- right:link
|
|
192.168.10.2/24 192.168.10.1 192.168.50.1 192.168.50.2
|
|
\\ /
|
|
\\ /
|
|
\\ WireGuard
|
|
\\ Tunnel /
|
|
\\ /
|
|
left:wg0 right:wg0
|
|
10.0.0.1/32 10.0.0.2/32
|
|
|
|
....
|
|
|
|
==== Topology
|
|
|
|
image::topology.svg[WireGuard Point-to-Point topology, align=center, scaledwidth=75%]
|
|
|
|
==== Sequence
|
|
|
|
. Set up topology and attach to target DUTs
|
|
. Configure WireGuard tunnel on DUTs
|
|
. Verify IPv4 connectivity with ping 10.0.0.2 from host:data
|
|
. Verify IPv6 connectivity with ping fd00::2 from host:data
|
|
|
|
|