From 272f35f3fb35c30d3fcdb523dc38b87a78064520 Mon Sep 17 00:00:00 2001 From: jwijenbergh Date: Wed, 7 Feb 2024 14:51:34 +0100 Subject: API: Include regular wireguard profile even when prefer TCP is true Otherwise breaks servers that only have wireguard support and we pass prefer tcp --- internal/api/api.go | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'internal/api') diff --git a/internal/api/api.go b/internal/api/api.go index c9f0408..a9ea0c0 100644 --- a/internal/api/api.go +++ b/internal/api/api.go @@ -246,9 +246,7 @@ func (a *API) Connect(ctx context.Context, prof profiles.Profile, protos []proto // Set the public key pubkey := wgKey.PublicKey() uv.Set("public_key", pubkey.String()) - if !pTCP { - hdrs.Add("accept", "application/x-wireguard-profile") - } + hdrs.Add("accept", "application/x-wireguard-profile") hdrs.Add("accept", "application/x-wireguard+tcp-profile") case protocol.OpenVPN: hdrs.Add("accept", "application/x-openvpn-profile") -- cgit v1.2.3