Re: [iccrg] [tcpm] Fwd: New Version Notification for draft-yang-tcpm-ets-00.txt

Kevin Yang <yyd@google.com> Fri, 11 December 2020 22:08 UTC

Return-Path: <yyd@google.com>
X-Original-To: iccrg@ietfa.amsl.com
Delivered-To: iccrg@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 505253A1006 for <iccrg@ietfa.amsl.com>; Fri, 11 Dec 2020 14:08:33 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -17.6
X-Spam-Level:
X-Spam-Status: No, score=-17.6 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIMWL_WL_MED=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, ENV_AND_HDR_SPF_MATCH=-0.5, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001, USER_IN_DEF_DKIM_WL=-7.5, USER_IN_DEF_SPF_WL=-7.5] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=google.com
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 6iHYjb29JUG3 for <iccrg@ietfa.amsl.com>; Fri, 11 Dec 2020 14:08:31 -0800 (PST)
Received: from mail-ej1-x62d.google.com (mail-ej1-x62d.google.com [IPv6:2a00:1450:4864:20::62d]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 7981E3A1016 for <iccrg@irtf.org>; Fri, 11 Dec 2020 14:08:31 -0800 (PST)
Received: by mail-ej1-x62d.google.com with SMTP id ce23so14396025ejb.8 for <iccrg@irtf.org>; Fri, 11 Dec 2020 14:08:31 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=T8Qz6UYHdmp1N/q4o/fbNv51HIeDhQSxlcBkq7tSLxc=; b=Hy2xmGcnoPufS3AINLCNp5tdnuvvHTPEkeUJnV62fgaxWm4btp72KrS6STSmYPc7U3 ne+S8zIkFx3fL+/qZBIqRRsxhnwntYfXoQVm/Zvsm3kR/pOWFqUTK2/Aa+dHWpR7p2hK FD3ZB1CEjwmwCE42207r3hKv0WcTwf2NzNs0BWKuD+ZYUUWY0SW+WIkZR0qrgdmY25aW lEFB5xq2OQFCGCDGu7ZqPw9NviIKgvPQnWRMZwiBsSwwwqjd49rKxBqVbfui9CZoLIhS WhA+aN8KmqY7Zi7iKyFsHLhVmL8XlV0eMf2xNncKtZhXorWGeZy0iDM6Yd+EsEh2A2E6 oXuQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=T8Qz6UYHdmp1N/q4o/fbNv51HIeDhQSxlcBkq7tSLxc=; b=s6PlqtC6Dw+Jzt00bIG5BOSr6b0KBYj3oVQOIJhuE8ZBA8gIMDXcxA4OAnrxeWBeVX 7Oe9we4BTsMFwnoWAcvDCrVD6XIzxL/HnSIFIKBRwZCjd8NL5y6Nkb/aaQ4+aXhi9E7Y efL/wr8cv3h5kAdF8c+/IYJOR+8vtfWNRJ2QUo8rf9QIPV1Fg2B6T1gsTRT9+rARzVF5 fRQUKC0jIJqd7zsyVlpog1gBrScyAqzRe84EwtxluMZjUeT5HE67mgG0ujzqhhgkvR3j 1iZyHtsMOc+hnL+g8SPe1RhZr5V4n62VJ+ek3woV0vivY7EmFtkiIjxESz58Eegcqo9q owfQ==
X-Gm-Message-State: AOAM532G58uGglrpktJDarIaub2xR5A4mKwKgP6K9wEDIug1fexUYTHy 6IsZm0JWnxKulGde4nAqCY6VHQkVPAxFq8VIQWRAdw==
X-Google-Smtp-Source: ABdhPJzWDHBnxdPIO/DkOhgtkfLD8h7EvroHinTEf0oAFf0Exl2rZzCLaFX3jwXH+vxBFNtOACfEqEs702MeNpst4OM=
X-Received: by 2002:a17:906:fa12:: with SMTP id lo18mr13163395ejb.354.1607724509414; Fri, 11 Dec 2020 14:08:29 -0800 (PST)
MIME-Version: 1.0
References: <160435977209.20839.4083263519198538783@ietfa.amsl.com> <CAK6E8=dh=kH36q0FFn4GJumSyU6cagf+rPy5UU2FAUiD+JOqbQ@mail.gmail.com> <CAAK044RKeeOhWj9P3XGpQa+qGZTyh-iKV2gXN5GnS6N39Duc8Q@mail.gmail.com> <CAPREpbYoE5sqUknUN0FJrc10T-Z-xhX4eokzLuZMmshkD1zORQ@mail.gmail.com> <CAK6E8=dgSPVhW-oRe1XeOnvZyqB4pMbQTuQGR8=9Pzm7v6xspA@mail.gmail.com> <adeef3ba-94e7-eb1a-ae86-838fcedf60b4@gmx.at> <CAPREpbYQVkPCdizqUbSXOjHwu-mVfL1cCc=R2Rtr3K48Hq2O=A@mail.gmail.com> <8b5b8012-0914-c833-6390-0e98a97074ad@gmx.at>
In-Reply-To: <8b5b8012-0914-c833-6390-0e98a97074ad@gmx.at>
From: Kevin Yang <yyd@google.com>
Date: Fri, 11 Dec 2020 17:08:18 -0500
Message-ID: <CAPREpbZnY+7oKP046SYA=fpH4MJpJXvjuEvoK4qxgx66XPM96w@mail.gmail.com>
To: "Scheffenegger, Richard" <rs.ietf@gmx.at>
Cc: Yuchung Cheng <ycheng@google.com>, "tcpm@ietf.org Extensions" <tcpm@ietf.org>, Eric Dumazet <edumazet@google.com>, iccrg IRTF list <iccrg@irtf.org>, Neal Cardwell <ncardwell@google.com>
Content-Type: text/plain; charset="UTF-8"
Archived-At: <https://mailarchive.ietf.org/arch/msg/iccrg/WShMhMNY4BNGHtgW_W-OsUEa84Y>
Subject: Re: [iccrg] [tcpm] Fwd: New Version Notification for draft-yang-tcpm-ets-00.txt
X-BeenThere: iccrg@irtf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "Discussions of Internet Congestion Control Research Group \(ICCRG\)" <iccrg.irtf.org>
List-Unsubscribe: <https://www.irtf.org/mailman/options/iccrg>, <mailto:iccrg-request@irtf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/iccrg/>
List-Post: <mailto:iccrg@irtf.org>
List-Help: <mailto:iccrg-request@irtf.org?subject=help>
List-Subscribe: <https://www.irtf.org/mailman/listinfo/iccrg>, <mailto:iccrg-request@irtf.org?subject=subscribe>
X-List-Received-Date: Fri, 11 Dec 2020 22:08:40 -0000

Thank you Richard,

To make less confusion, the new proposed ETSopt is targeting a different
option kind, i.e. not reusing RFC7323 TSopt, so please allow me to use
ETSval and ETSecr to refer to the timestamps in ETS option.

For saving more space in <SYN> and <SYN,ACK> by reusing the ETSecr, I generally
like this idea about XOR ETSecr with other fields. But considered the
complexity it adds to the protocol and implementation, I'm on the fence and
waiting for more inputs from others.

To help others understand the problem, I summarize it in the following:

The idea is to XOR ETSecr with EcrDel and MaxACKDel fields in <SYN> and
<SYN,ACK> to save the 32 bits space used by EcrDel.

The ETSecr is all-zero in <SYN>, so we can XOR them to save 32 bits without
problem. But to XOR ETSecr with the other fields in <SYN,ACK>, we need to
prevent <SYN,ACK> mis-paired with retransmitted <SYN>s.

One way to solve the problem is to:
1. In <SYN,ACK>, make S (e.g. S=3) bits of either in EcrDel or MaxACKDel to
be 0, sacrifice a little accuracy, e.g. roundup to neaest multiple of 8.

2. Need to rearrange the position of EcrDel or MaxACKDel so that those S bits
coincide with the least significant of ETSecr. So the S bits of ETSecr
remain the same in <SYN,ACK>.

3. In <SYN> and retransmitted <SYN>, the sender makes each retransmitted <SYN>
have ETSval's last S bits that are different from before.

4. When the sender receives the <SYN,ACK>, it knows which <SYN> to pair using
the last S bit of ETSecr.


About the 2^10 nanosecond unit, I'm thinking that might not make it easier for
computation EcrDel = LatestACKDel + TSecrAge (page 7), since both component
are not directly compute from nanosecond: TSecrAge is the difference of two TS
clock (in microsecond), LatestACKDel can be computed from tp->tcp_mstamp in
Linux which is also in microsecond. So if EcrDel can be represented in
microsecond, there should be no div operation needed. Also, it is more natural
to keep EcrDel with the same microsecond(10^3 nanosecond) format as ETSval
and ETSecr.

Best,
Kevin


On Tue, Nov 24, 2020 at 8:22 AM Scheffenegger, Richard <rs.ietf@gmx.at> wrote:
>
>
>
> Am 23.11.2020 um 02:47 schrieb Kevin Yang:
> >> The high level approach there was to use the unused TSecr field (should
> >> be 0 for 7323/1323), and overlay (xor) in the SYN/ACK's TSopt ecr field
> >> the client's TSopt val with the servers 32-bit negotiation field... As
> >> the client can retain knowledge of the initial TSopt value (there should
> >> be a randomized initial value), the client can extract the server side
> >> options by xor'ing it's known initial value when the SYN/ACK is
> >> received. Or fall back to default 7323 operation, if the result of the
> >> XOR is zero...
> >>
> >
> > I agree that the TSecr in <SYN> might be used for other purposes. But I'm
> > not sure if we can alter the TSecr in <SYN,ACK> by XOR other info.
> > One specific example I came up with is that a sender may send out many
> > SYNs because of timeout,
> > then when it receives a <SYN,ACK>, it does not know which TSval should
> > be used for xor op.
>
> (E)TS opt is not necessarily the old differentiation between subsequent
> SYN packets; extending some reserved bits (during the SYN handshake) may
> be another easy way to have sufficient differentiation available.
>
> E.g. The EcrDel value may be restricted to no less than 4 or 8 usec (any
> lower value rounded up), yielding sufficient bits which would expected
> to be zero in the SYN,ACK; The TSval offset can then be selected by the
> sender in such a way, to change at these locations for each
> retransmission of the SYN, allowing the sender to disambiguate which SYN
> a particular SYN,ACK pairs up with...
>
>
>
> >> It could be used almost as a drop-in use of timestamp-negotiation, as
> >> long as it can be guaranteed, that at least one bit is set in the 32bit
> >> field (e.g. setting the reserved bit to 1).
> >
> > In this way we need to add another "ETSval'' in usec if we use the
> > RFC7323/1323 TSopt,
> > the reason is explained above.
>
> As long as some more coarse time resolution is acceptable during the
> (special case handling) 3WHS, all you need is a few bits to disambiguate
> retransmitted SYN packets. We did spent some thought on the
> retransmitted SYN problem during the TS-nego design phase. A single
> reserved bit is not sufficient, though;
>
> >
> >> EcrDelUnit: I think the codepoint assignment could be improved (but this
> >> is really nit-picking; just that a broken implementation may send out
> >> TSopt with len=12, but initialized-to-zero superflous bytes...
> >> 0: invalid
> >> 1: milliseconds [2^20 nanoseconds?]
> >> 2: microseconds [2^10 nanoseconds?]
> >> 3: reserved (nanoseconds)
> >
> > Thanks for the nice suggestion. I agree we probably should have
> > all-zero codepoint to be
> > "no information". For 2^k nanosec unit, I guess that is for bit-op
> > convenience and performance?
>
> Yes, simple binary shift operations instead of multiply/divide, and
> internally representing timestamp values in nanoseconds
> (timespec/tv_nsec). The error when using timeval/tv_usec may even be
> small enough to not matter in many environments (eg. simply use a
> "microsecond 2^10" value directly, without adjusting for the 2.4% error,
> as you are interested in deltas on short timescales, not across long
> timespans?