Received: by 2002:a05:6a10:6d10:0:0:0:0 with SMTP id gq16csp856367pxb; Fri, 22 Apr 2022 12:44:28 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz6rzdCSdLupdj47aSe2yE5VqCphWzh/EvcSlOC5lAhuMTijyXggWI8KvMOHMrfDEnQUowW X-Received: by 2002:a17:903:32c6:b0:158:ded2:e766 with SMTP id i6-20020a17090332c600b00158ded2e766mr6165469plr.117.1650656668118; Fri, 22 Apr 2022 12:44:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1650656668; cv=none; d=google.com; s=arc-20160816; b=m0Lku8qGjJliOp5HkNtuXvj3UGVRFdn59qnsrGWi5ZRSQQHJdyNea6T3H1zQP6Fukt adEmva3emF3GeDAre0XHBgZHKEM3ucFss+KejoURIStPlqql15O6iGkAh0YUm0t1I2jj rdGQnbGdGoCOgv+gtUeH7oq+yUEjkhv8yN+2eZJZPtmNgAuaaWSTK2Hx0LjEuZNCT07t LuBSfCwnMZVtOm2V/7u1GSIr1HPRmsMTKuILGNc+e9yi7/dwRXSCiol0alIbjJhdxxb4 E7l5vf05BYw1+DbcWdgBcVQ/DUXNF7rK1aNq0Ag15P4D9UxlLOKcGCsJgL61oLDP64QI qePA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=AE7l3U3Ok/l/ma4wVBxTAWhqFVPfRK/mIEy0ba9HyK0=; b=PVTFgkG2GAQ0GvnLFyjAEioXIBR0zh5gXjWOWBkudHY1OsttjlhbmV+k8wm4RbB4bd 7Fag5Hn7YoT4IA9GZW3yAj+ZFIWmvHzj/tX+82UPexBV4vf+A4KygU/pp9hQiKHcZcKy rO6PWFQJbfXGrWDTKve2GrdHE3qDB4HiQOKw/GUc8eyqUL98wzcDvPdA1fBjp9P8ctPW Ac59OD6znJFpoetEwEhYMCqtzy3MPmGrXdhewfQUN0zPkvoYEXsVPfFYJGRlV/z9o2oD 4vxkXOI1JvheJfiAnGGHkyKtTdY7J3y7zcXCc1Qvq1055m7vMZdizFJwleyGwEGtApcn vwFw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20210112 header.b=mZ9Ge9ei; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id f64-20020a636a43000000b00381cbf13898si9200510pgc.373.2022.04.22.12.44.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 22 Apr 2022 12:44:28 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20210112 header.b=mZ9Ge9ei; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: from out1.vger.email (out1.vger.email [IPv6:2620:137:e000::1:20]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 71C0221573E; Fri, 22 Apr 2022 11:51:39 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1383755AbiDUCDH (ORCPT + 99 others); Wed, 20 Apr 2022 22:03:07 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42926 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1383776AbiDUCDC (ORCPT ); Wed, 20 Apr 2022 22:03:02 -0400 Received: from mail-yw1-x112f.google.com (mail-yw1-x112f.google.com [IPv6:2607:f8b0:4864:20::112f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A5A91101D1 for ; Wed, 20 Apr 2022 19:00:13 -0700 (PDT) Received: by mail-yw1-x112f.google.com with SMTP id 00721157ae682-2ec42eae76bso37480217b3.10 for ; Wed, 20 Apr 2022 19:00:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=AE7l3U3Ok/l/ma4wVBxTAWhqFVPfRK/mIEy0ba9HyK0=; b=mZ9Ge9eiHVANFgD4+KOUXL1r2F71/Kiyi5Ioyx/BT61bDLjjP95WftDAMJrBH//GBC kV63YgO+r6UptKN1T3M+prV/q4e1QlwHPXiwAuPcyrYzA/F1hQbLYtN1JgyS55X3OimJ eOBuVnNJg4CnBIZLypL2m4P06HJxTDCet3rYw5r1EAw/FPMrPwUF2xXOTRWKVcVet2Lq S/uQ6UisWZiXssiKxQJ7aiN30BdjW6+ETRI0pR5fQmWbIt+FzLk1ZBLDUx6HmxEkmfT/ 7WSh2BNHOP5jm4tR7JnBcG55if9Tr9Ri4sRI97AEOydNb3VDhfC5keLovEe+sLJlHw0F 9lGw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=AE7l3U3Ok/l/ma4wVBxTAWhqFVPfRK/mIEy0ba9HyK0=; b=q8iMi3mIsktCPtR0v3h3lr8mPlAvmStJedFIqHtL42QdanuZ1HFDUA08AAoeywMEWb LwM406H2OfbJN/qUKDbLlA1xaijJBAdOV7d0Te9+WADr6TGu3O4gAaVobMaqkzDXwSZh bRleHxx4PFFJZOmOSzl1r5XLoYQ4WDYzwf/Sl+J0MDQeERhGliad282YwMrLml9db/GT uV636K5uE94QT+/vLRKdhPZx0Y4wbwnLei6E8OkjlAq5nLXXxjLhPWbsEmAMMfRoX6oK IqrYg1W2HoVB0gyAvCspLEB6WPJotRDSyMnnzJE8G9tDQTUA9VfT7Fcm81ho5MsX2tP/ MJZQ== X-Gm-Message-State: AOAM533cWuuBcps3U8LII6uGjKojW3mrx++pdVyQDshRmi5mQeucVQSe h5SfMFkatE89asleLGaXlndEyxFORj3a24dGfJZjijBFgH9EAw== X-Received: by 2002:a0d:cb07:0:b0:2f1:c718:b273 with SMTP id n7-20020a0dcb07000000b002f1c718b273mr11764955ywd.467.1650506412639; Wed, 20 Apr 2022 19:00:12 -0700 (PDT) MIME-Version: 1.0 References: <20220421005026.686A45EC01F2@us226.sjc.aristanetworks.com> In-Reply-To: <20220421005026.686A45EC01F2@us226.sjc.aristanetworks.com> From: Eric Dumazet Date: Wed, 20 Apr 2022 19:00:01 -0700 Message-ID: Subject: Re: [PATCH v2 net] tcp: md5: incorrect tcp_header_len for incoming connections To: Francesco Ruggeri Cc: Paolo Abeni , Jakub Kicinski , David Ahern , Hideaki YOSHIFUJI , David Miller , LKML , netdev Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-9.5 required=5.0 tests=BAYES_00,DKIMWL_WL_MED, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,USER_IN_DEF_DKIM_WL autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Apr 20, 2022 at 5:50 PM Francesco Ruggeri wrote: > > In tcp_create_openreq_child we adjust tcp_header_len for md5 using the > remote address in newsk. But that address is still 0 in newsk at this > point, and it is only set later by the callers (tcp_v[46]_syn_recv_sock). > Use the address from the request socket instead. > > > > Fixes: cfb6eeb4c860 ("[TCP]: MD5 Signature Option (RFC2385) support.") > Signed-off-by: Francesco Ruggeri Thanks for fixing this Francesco. Reviewed-by: Eric Dumazet