Received: by 2002:a05:7412:b112:b0:f9:3106:f1c0 with SMTP id az18csp135193rdb; Mon, 18 Dec 2023 01:13:36 -0800 (PST) X-Google-Smtp-Source: AGHT+IHYAjPKcodn5K+BC3gVY3rcJiuMG+sPAyUVsr9I43ILUjS5rR/cXHRSJ7JHxQSCxC/imKPP X-Received: by 2002:a17:90a:d143:b0:286:6cd8:ef04 with SMTP id t3-20020a17090ad14300b002866cd8ef04mr20372658pjw.28.1702890816175; Mon, 18 Dec 2023 01:13:36 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702890816; cv=none; d=google.com; s=arc-20160816; b=NnfOc9rL/8ATlrA4VijhA7bbIpvT8qt9IiyZiMcKgjd4d5xvv6961c9Jgl8IGoEXd9 yyVRf76unDbnvYcK4/C3XPv1lWp2n9082weHWMW7iqlCb03Jv4ff/JvZyJEb8K4Ap4z9 aerkVaCm/j1MDMQ1SlD/MLY2hoAwGfmHvxwWT6A3kWhQ+UyyNIBDiUD8t26yTSyeJxzf EDnHWgb3X7O6Z1iHRyDWskIZ2dNAaXWJ9qE2jL3sCCZgKgCMvwUCqrBe4YbHZSyUnpzV LbwSz1pNmrm8yVlT3D7qDR7xDcEYr0hnxhwo00bb7dSGjhG5tSYtgtBio5L02EUfFXmc 7Okw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=l8wf06F/XJLNPFw5y4gVtxQ1Sn+Ur9N/zSmsQOxOZr0=; fh=G9R3k9cEYwB9YaDXokbdT+WuQlJ5FATgGDhomVg9P64=; b=tNvhghkvVxqpz4pKOKeXBT2wMqUbOR3dSevm9StoQj4Nt+HvYz7z++u+usbPSrgkgY 2nvYqer8ImS/WCTdvxSykW9k86wTO0fd1u1BR/s8oNNbS2TJ7irX/nocmnSHWWFIPASM TIdfF5phfAUYKXcxX1ynlj6RkjMSzEE6gbCzdEltWoFOznhTBCN1t+OxELbRc0iknO60 mCbz3EKMsps2FqggoZ6OjTjyhoAyYV7Z/qBHJk93C+lmcX9X9+H3l7NRVjroRL9XhHTR M/IoUlm95iidgsyibGWnJdovS9HAT3Ns679GGRvLcx6ISKyybI06Uz2ILDS8Ez/+A5Dy W4MQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=GTM4oZND; spf=pass (google.com: domain of linux-kernel+bounces-3232-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-3232-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id x15-20020a17090a46cf00b0028b1041dd7esi2194515pjg.26.2023.12.18.01.13.35 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 18 Dec 2023 01:13:36 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-3232-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=GTM4oZND; spf=pass (google.com: domain of linux-kernel+bounces-3232-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-3232-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id CFE00283849 for ; Mon, 18 Dec 2023 09:13:35 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id C905E11CA8; Mon, 18 Dec 2023 09:12:18 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="GTM4oZND" X-Original-To: linux-kernel@vger.kernel.org Received: from mail-pl1-f171.google.com (mail-pl1-f171.google.com [209.85.214.171]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C17D515483; Mon, 18 Dec 2023 09:12:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-pl1-f171.google.com with SMTP id d9443c01a7336-1d32c5ce32eso28100805ad.0; Mon, 18 Dec 2023 01:12:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1702890736; x=1703495536; darn=vger.kernel.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=l8wf06F/XJLNPFw5y4gVtxQ1Sn+Ur9N/zSmsQOxOZr0=; b=GTM4oZNDvpdrT5b5SY3MT86K0UVKmfUaftKFxYSOJKdlRKAlgLLUtY7+9B3yFmUhQZ PYQZBf0RP02WY1v9rt0MmiExryp3zX8MnGLo7r+Z6RzFGcQEEmZnIufbQnTEcDCXzmPU vsvUrxPW5mdHLRnASXU4+dw07tXQqkPxj0vy5CZ860wrNpbxzSgAhD7oe1xpRtejwtmi GStWeyy6YKyQFUi0t8DtG1uiEJiZu0rogG8TRxCXA2AF2d36avd5dQA0dd6gw7qpoF9c CppIG7q/Dc5/Wx8sCkOqOVIF8+F7+/JzBD1MFAGIWDlIL+KqRa2aDOZiyl+nmn1Rxcfn O2vw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1702890736; x=1703495536; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=l8wf06F/XJLNPFw5y4gVtxQ1Sn+Ur9N/zSmsQOxOZr0=; b=JJtZhDO5ENtg5ywh8kH/NEeHUZYJP3xOb4ltO6N0XPUHk7ptVH8INdQ493jwaj4aml hadgmW2Sc8OeunAL3KaLZRo5tJ6hjPtJjTIbs//mziLXPy7TVVJ2x28cUVkqrKteHGMo mx9QKQZKLxx9AEQzYJ9w1VWKEDkM9KkHhq6Ltjm1GOEpOP/wYL2PcaDdsDZmZMfc+xzh ZLIzKxnoMldaWHIySka+oxq+Wbivq+8J+SeFeDxYEXVOIZT398KKSQ4hosDiqtavc0TM 5tu9VJRDEAKYG9Avp2DpUb9af1Lr4owethJm+FTC7vsqwjM8zTMsCgPfkrF7m2ww8Zz5 xNQw== X-Gm-Message-State: AOJu0YyuvFu4ZOtE4EawPbSHUS4B3IdfamBR0C1G881oFtntbk01SmAI SCvb6988EMm7zYkAucOtoj9nzl0vrWGo6R2m X-Received: by 2002:a17:902:e54b:b0:1d0:bf4c:166c with SMTP id n11-20020a170902e54b00b001d0bf4c166cmr20889261plf.1.1702890736006; Mon, 18 Dec 2023 01:12:16 -0800 (PST) Received: from Laptop-X1 ([43.228.180.230]) by smtp.gmail.com with ESMTPSA id t18-20020a170902e85200b001d0675e59f9sm18525659plg.200.2023.12.18.01.12.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 18 Dec 2023 01:12:15 -0800 (PST) Date: Mon, 18 Dec 2023 17:12:10 +0800 From: Hangbin Liu To: Dmitry Safonov Cc: Shuah Khan , David Ahern , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Salam Noureddine , Bob Gilligan , linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org, netdev@vger.kernel.org, Dmitry Safonov <0x7f454c46@gmail.com> Subject: Re: [PATCH 11/12] selftests/net: Add TCP-AO selfconnect/simultaneous connect test Message-ID: References: <20231215-tcp-ao-selftests-v1-0-f6c08180b985@arista.com> <20231215-tcp-ao-selftests-v1-11-f6c08180b985@arista.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20231215-tcp-ao-selftests-v1-11-f6c08180b985@arista.com> On Fri, Dec 15, 2023 at 02:36:25AM +0000, Dmitry Safonov wrote: > Check that a rare functionality of TCP named self-connect works with > TCP-AO. This "under the cover" also checks TCP simultaneous connect > (TCP_SYN_RECV socket state), which would be harder to check other ways. > > In order to verify that it's indeed TCP simultaneous connect, check > the counters TCPChallengeACK and TCPSYNChallenge. > > Sample of the output: > > # ./self-connect_ipv6 > > 1..4 > > # 1738[lib/setup.c:254] rand seed 1696451931 > > TAP version 13 > > ok 1 self-connect(same keyids): connect TCPAOGood 0 => 24 > > ok 2 self-connect(different keyids): connect TCPAOGood 26 => 50 > > ok 3 self-connect(restore): connect TCPAOGood 52 => 97 > > ok 4 self-connect(restore, different keyids): connect TCPAOGood 99 => 144 > > # Totals: pass:4 fail:0 xfail:0 xpass:0 skip:0 error:0 > > Signed-off-by: Dmitry Safonov Tested-by: Hangbin Liu