[Ntp] Antw: Re: Antw: Re: I-D Action: draft-ietf-ntp-port-randomization-00.txt

"Ulrich Windl" <Ulrich.Windl@rz.uni-regensburg.de> Thu, 14 November 2019 08:17 UTC

Return-Path: <Ulrich.Windl@rz.uni-regensburg.de>
X-Original-To: ntp@ietfa.amsl.com
Delivered-To: ntp@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 101D4120878 for <ntp@ietfa.amsl.com>; Thu, 14 Nov 2019 00:17:23 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.9
X-Spam-Level:
X-Spam-Status: No, score=-1.9 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 7EvIkO0uknv8 for <ntp@ietfa.amsl.com>; Thu, 14 Nov 2019 00:17:20 -0800 (PST)
Received: from mx2.uni-regensburg.de (mx2.uni-regensburg.de [IPv6:2001:638:a05:137:165:0:3:bdf8]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 4D5861200CC for <ntp@ietf.org>; Thu, 14 Nov 2019 00:17:12 -0800 (PST)
Received: from mx2.uni-regensburg.de (localhost [127.0.0.1]) by localhost (Postfix) with SMTP id 49D7D6000052 for <ntp@ietf.org>; Thu, 14 Nov 2019 09:17:07 +0100 (CET)
Received: from gwsmtp.uni-regensburg.de (gwsmtp1.uni-regensburg.de [132.199.5.51]) by mx2.uni-regensburg.de (Postfix) with ESMTP id 2FACE600004D for <ntp@ietf.org>; Thu, 14 Nov 2019 09:17:02 +0100 (CET)
Received: from uni-regensburg-smtp1-MTA by gwsmtp.uni-regensburg.de with Novell_GroupWise; Thu, 14 Nov 2019 09:17:02 +0100
Message-Id: <5DCD0D7C020000A100035321@gwsmtp.uni-regensburg.de>
X-Mailer: Novell GroupWise Internet Agent 18.2.0
Date: Thu, 14 Nov 2019 09:17:00 +0100
From: "Ulrich Windl" <Ulrich.Windl@rz.uni-regensburg.de>
To: "ntp@ietf.org" <ntp@ietf.org>,<mlichvar@redhat.com>
References: <157262391705.31923.311801865037196489@ietfa.amsl.com> <20191113112126.GA2634@localhost> <5DCBEDCC020000A1000352C1@gwsmtp.uni-regensburg.de> <20191113160055.GC2634@localhost>
In-Reply-To: <20191113160055.GC2634@localhost>
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Content-Disposition: inline
Archived-At: <https://mailarchive.ietf.org/arch/msg/ntp/UxboA2W7lYu7rEDvXp5Tz4HD5Vk>
Subject: [Ntp] Antw: Re: Antw: Re: I-D Action: draft-ietf-ntp-port-randomization-00.txt
X-BeenThere: ntp@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: <ntp.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/ntp>, <mailto:ntp-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/ntp/>
List-Post: <mailto:ntp@ietf.org>
List-Help: <mailto:ntp-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/ntp>, <mailto:ntp-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 14 Nov 2019 08:17:23 -0000

>>> Miroslav Lichvar <mlichvar@redhat.com>; schrieb am 13.11.2019 um 17:00 in
Nachricht <20191113160055.GC2634@localhost>:
> On Wed, Nov 13, 2019 at 12:49:32PM +0100, Ulrich Windl wrote:
>> >>> Miroslav Lichvar <mlichvar@redhat.com>; schrieb am 13.11.2019 um 12:21
in
>> > ‑ It seems to be the current practice. From the implementations
>> >   that I'm familiar with and that use a random source port, each one
>> >   opens a new socket for each request, at least by default. On my
>> >   public servers I see that most clients do change their port over
>> >   time.
>> 
>> >From remote you cannot know whether it's the same instance of the same 
> client
>> sending the requests.
> 
> Yes, there could be multiple clients (e.g. behind NAT), but I think we
> can make a good guess whether any of them use a stable port by
> counting how many requests are there per port. When I analyze 24-hour
> captures from public servers in few different countries, for most
> addresses there seem to be only one request per port. I'm ignoring
> addresses that send only requests from some popular fixed ports like
> 123, 1024, 1490.

So your result is more or less biased: What if that fixed popular ports are
99% of all requests? Then you are csaling up the remaining 1% to support your
view. That's not serious argumenting.

> 
>> My guess is that the client does not specify the source port, so for each
>> socket a free (not "random") port will be chosen. The implementation 
> rationale
>> most likely is that "it's easier", not because "it's better".
> 
> I'm not sure if it's really easier. The port assigned by the system
> should be random. Do you have an example of a widely used
> implementation keeping a socket open which is not also used for
> different servers?

I mean this: If the client specified a specific port, the client has to make
sure that the port isn't in use. If you specify 0 as port, the system picks a
free one for you. Thats easier.

> 
>> I think I said it before: The server SHOULD still work if the client
changes
>> the port number (leaving it open to the server to assume that it's a 
> different
>> client then), but I would NOT require the client to vary the source port
>> number.
> 
> It's not meant to be a requirement, just a recommendation.
> 
> -- 
> Miroslav Lichvar
> 
> _______________________________________________
> ntp mailing list
> ntp@ietf.org 
> https://www.ietf.org/mailman/listinfo/ntp