From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-0.7 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, HTML_MESSAGE,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7F480C3A5A7 for ; Wed, 28 Aug 2019 06:06:47 +0000 (UTC) Received: from krantz.zx2c4.com (krantz.zx2c4.com [192.95.5.69]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id B2D4D22CF5 for ; Wed, 28 Aug 2019 06:06:46 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org B2D4D22CF5 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=friedels.name Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=wireguard-bounces@lists.zx2c4.com Received: from krantz.zx2c4.com (localhost [IPv6:::1]) by krantz.zx2c4.com (ZX2C4 Mail Server) with ESMTP id 983a2b4f; Wed, 28 Aug 2019 06:06:29 +0000 (UTC) Received: from krantz.zx2c4.com (localhost [127.0.0.1]) by krantz.zx2c4.com (ZX2C4 Mail Server) with ESMTP id d79bb295 for ; Wed, 28 Aug 2019 06:06:27 +0000 (UTC) Received: from smtprelay04.ispgateway.de (smtprelay04.ispgateway.de [80.67.29.8]) by krantz.zx2c4.com (ZX2C4 Mail Server) with ESMTP id 3023940b for ; Wed, 28 Aug 2019 06:06:26 +0000 (UTC) Received: from [92.76.198.6] (helo=[192.168.177.20]) by smtprelay04.ispgateway.de with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.92) (envelope-from ) id 1i2r68-0000Ih-OY; Wed, 28 Aug 2019 08:06:24 +0200 From: "Hendrik Friedel" To: =?utf-8?q?Ivan=20Lab=c3=a1th?= Subject: Re[2]: Keep-alive does not keep the connection alive Date: Wed, 28 Aug 2019 06:06:23 +0000 Message-Id: In-Reply-To: <20190826180244.GB5022@matrix-dream.net> References: <20190826180244.GB5022@matrix-dream.net> User-Agent: eM_Client/7.2.34062.0 Mime-Version: 1.0 X-Df-Sender: aGVuZHJpa0BmcmllZGVscy5uYW1l Cc: wireguard@lists.zx2c4.com X-BeenThere: wireguard@lists.zx2c4.com X-Mailman-Version: 2.1.15 Precedence: list Reply-To: Hendrik Friedel List-Id: Development discussion of WireGuard List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: multipart/mixed; boundary="===============7906691946176649242==" Errors-To: wireguard-bounces@lists.zx2c4.com Sender: "WireGuard" --===============7906691946176649242== Content-Type: multipart/alternative; boundary="------=_MB1D78D5C9-C7FA-494A-B79A-3A9B1015338D" --------=_MB1D78D5C9-C7FA-494A-B79A-3A9B1015338D Content-Type: text/plain; format=flowed; charset=utf-8 Content-Transfer-Encoding: quoted-printable Hello, yes, the Sever has a dynamic IP. >On the client, is the server peer ip correct? Which entry are you refering to? I assume Endpoint =3D Dyn.IP:51820 Yes, but otherwise, the connection would not even be established, right? For reference, here the complete client config: [Interface] Address =3D 10.192.122.3/32 PrivateKey =3D xx=3D [Peer] PublicKey =3D yy=3D Endpoint =3D Dyn.IP:51820 AllowedIPs =3D 0.0.0.0/0 PersistentKeepalive =3D 25 Regards, Hendrik ------ Originalnachricht ------ Von: "Ivan Lab=C3=A1th" An: "Hendrik Friedel" Cc: "Vasili Pupkin" ; wireguard@lists.zx2c4.com Gesendet: 26.08.2019 20:02:44 Betreff: Re: Keep-alive does not keep the connection alive >Hello, > >I notice you are using dynamic ips for server. >On the client, is the server peer ip correct? > >Regards, >Ivan > >On Sun, Aug 25, 2019 at 06:44:53PM +0000, Hendrik Friedel wrote: >> Hello, >> >> thanks for your reply. >> It is linux (Kernel 5.x) in both cases. >> >> Regards, >> Hendrik >> >> ------ Originalnachricht ------ >> Von: "Vasili Pupkin" >> An: "Hendrik Friedel" >> Cc: wireguard@lists.zx2c4.com >> Gesendet: 25.08.2019 17:59:59 >> Betreff: Re: Keep-alive does not keep the connection alive >> >> >What OS is running on client side? I have this issue on Win7 client, >> >can explain it further, it has nothing to do with keepalives though, >> >it is a bug in tun adapter implementation >> > >> >On Sun, Aug 25, 2019 at 6:38 PM Hendrik Friedel wrote: >> >> I have a setup in which the Server IP is known, whereas the Client= IP is changing. Thus, I rely on the Client to connect to the Server. I want = the Client to keep the connection alive all the time though, so that the S= erver can also initiate a connection to the Server when needed. Both, clien= t and server are behind a NAT/Router. >> >> I would think, that the "PersistentKeepalive =3D 25" on the Client= would ckeep the connection open. The connection works fine while used. But= after a while, I cannot connect from the Server to the client anymore. >> >> I would assume that a ping from the Client to the IP of the endpoin= t would help to re-alive the connection - but it does not. >> >> >> >> Only after a wg-quick down and up all is fine again. >> >> >> >> Below some more information. >> >> >> >> Can you help me to find, what I am doing wrong? >> >> _______________________________________________ >> WireGuard mailing list >> WireGuard@lists.zx2c4.com >> https://lists.zx2c4.com/mailman/listinfo/wireguard --------=_MB1D78D5C9-C7FA-494A-B79A-3A9B1015338D Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: quoted-printable
Hello,

yes, the Sever has a dyn= amic IP.

>On the client, is the server peer i= p correct?
Which entry are you refering to?
I assume= =C2=A0
Endpoint =3D Dyn.IP:51820=C2=A0

Yes, but otherwise, the connection would not even be established, right?

For reference, here the complete client config:
[Interface= ]
Address =3D 10.192.122.3/32
PrivateKey =3D xx=3D

[Peer]
PublicKey =3D yy=3D
Endpo= int =3D Dyn.IP:51820
AllowedIPs =3D 0.0.0.0/0
Persisten= tKeepalive =3D 25

Regards,
Hendrik



------ Originalnachricht ------
Von: "Ivan Lab=C3=A1th" <labawi-wg@matrix-dream.net>
An: "Hendrik Friedel" <hendrik@friedels.name>
Cc: "Vasili Pupkin" <diggest@gmail.com>; wireguard@lists.zx2c4.c= om
Gesendet: 26.08.2019 20:02:44
Betreff: Re: Keep-alive does not keep the connection alive
<= br />
Hello,
=C2=A0
I notice you are using dynamic ips for server.
On the client, is the server peer ip correct?
=C2=A0
Regards,
Ivan
=C2=A0
On Sun, Aug 25, 2019 at 06:44:53PM +0000, Hendrik = Friedel wrote:
Hello,
=C2=A0
thanks for your reply.
It is linux (Kernel 5.x) in both cases.
=C2=A0
Regards,
Hendrik
=C2=A0
------ Originalnachricht ------
Von: "Vasili Pupkin" <diggest@gmail.com>
An: "Hendrik Friedel" <hendrik@friedels.name&= gt;
Cc: wireguard@lists.zx2c4.com
Gesendet: 25.08.2019 17:59:59
Betreff: Re: Keep-alive does not keep the connec= tion alive
=C2=A0
>What OS is running on client side? I have th= is issue on Win7 client,
>can explain it further, it has nothing to do = with keepalives though,
>it is a bug in tun adapter implementation
>
>On Sun, Aug 25, 2019 at 6:38 PM Hendrik Frie= del <hendrik@friedels.name> wrote:
>> I have a setup in which the Server IP= is known, whereas the Client IP is changing. Thus, I rely on the Client to= connect to the Server. I want the Client to keep the connection alive all t= he time though, so that the Server can also initiate a connection to the Se= rver when needed. Both, client and server are behind a NAT/Router.
>> I would think, that the "PersistentKee= palive =3D 25" on the Client would ckeep the connection open. The connectio= n works fine while used. But after a while, I cannot connect from the Serve= r to the client anymore.
>> I would assume that a ping from the Cl= ient to the IP of the endpoint would help to re-alive the connection - but= it does not.
>>
>> Only after a wg-quick down and up all= is fine again.
>>
>> Below some more information.
>>
>> Can you help me to find, what I am doi= ng wrong?
=C2=A0
_______________________________________________<= /div>
WireGuard mailing list
WireGuard@lists.zx2c4.com
https://lists.zx2c4.com/mailman/listinfo/wiregua= rd
--------=_MB1D78D5C9-C7FA-494A-B79A-3A9B1015338D-- --===============7906691946176649242== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ WireGuard mailing list WireGuard@lists.zx2c4.com https://lists.zx2c4.com/mailman/listinfo/wireguard --===============7906691946176649242==--