diff options
Diffstat (limited to 'protocol.capnp')
-rw-r--r-- | protocol.capnp | 20 |
1 files changed, 15 insertions, 5 deletions
diff --git a/protocol.capnp b/protocol.capnp index 64463e9..69f5db4 100644 --- a/protocol.capnp +++ b/protocol.capnp @@ -14,11 +14,21 @@ struct WgClientMsg { } } +# IPv4 address +struct WgIpv4Addr { + addr @0 :UInt32; # IPv4 address + cidr @1 :UInt8; # CIDR of IPv4 address +} + +# IPv6 address +struct WgIpv6Addr { + addr @0 :Data; # IPv6 address + cidr @1: UInt8; # CIDR of IPv6 address +} + # server response message struct WgServerSimpleMsg { - leasedIpv4 @0 :UInt32; # dynamic IPv4 leased to client - leasedIpv4Cidr @1 :UInt32; # CIDR of dynamic IPv4 leased to client - leaseTimeout @2 :UInt32; # activity timeout for the IP lease in seconds - route @3 :UInt32; # route for client - routeCidr @4 :UInt32; # CIDR of route for client + leasedIpv4 @0 :WgIpv4Addr; # dynamic IPv4 leased to client + leaseTimeout @1 :UInt32; # activity timeout for the IP lease in seconds + ipv4Routes @2 :List(WgIpv4Addr); # IPv4 routes for client } |