Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp2527703rwb; Fri, 11 Nov 2022 10:31:44 -0800 (PST) X-Google-Smtp-Source: AA0mqf7/LnaEKRGZnMqF6/e8VEMkdGHPWl2c3k187lI9lZ59wH5JJ7GBVolr9mWbmqM9NkYcMmzW X-Received: by 2002:a05:6402:3983:b0:467:69e3:c25b with SMTP id fk3-20020a056402398300b0046769e3c25bmr1714806edb.3.1668191504225; Fri, 11 Nov 2022 10:31:44 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668191504; cv=none; d=google.com; s=arc-20160816; b=tEWNqMFS7mtFcfBvAp01Bl1Gy0k2PFgAE3mPDvNsKZCrnyxnAGg3HyMcQAxK9C9JVm M9mAy+98TKW72N0hwIjXdmzEF/FHj/49+2CNEph/z6CPB4dc5VpZTxKCkLL2qpExy1qi qdytnj06VhGdV9mpwAtFLwIBcqrUMrdeo2zwzFVhdLp1N8yjYEpb+VpAXF4QZZ/Yfu4m bQ04zBzHXg6Bgw4MUutGIo48b36tjs5ciYpjvX+TudJOo2l+6PPSZWB7YkEF2wbk43B3 8iMQ7z4GWGUAnKj3uBrzLNMW0P+0I2QT8/Gf0kz6xKVpTZnNkSLsyMOaqYxqbPDeha1V ujjQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=Q7Xa+py3hjWExofDQ+1PRKQ3Oe9rzLGK9/H+JFsk8ag=; b=SjMpnsmIXPVi0JD/rBaKU+aZ+EUlMTVcDddTedWFTTiMgWY9pbQtVq1/K8uQowc5jQ b6/sVJzR5ZcmlstV4f9DfCeZQ4R3HsQaX5KL8LFxuSp+Pe/MU0FocBO7TSuaPD7izkkv naMf20DER2qA0Kk9I8gtfq2y4G9H3bHW2niQeSZBXfTl1hGbq6iYCLiwF1xjwJ/aHZx9 36QCAY9BCET+bc4FVVWlAtjD5QCnqn8sQZjA0ke20mZSdwSLmMPV3t/pJx4lp4QwZiAm 2wKzBVnoiJq9HrPwoicSe/AHctrlJDA5Rlpv5F1hgp8RkT0JAcBSzAB7vKS2UDNU6H0z U9rQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@networkplumber-org.20210112.gappssmtp.com header.s=20210112 header.b=0NM6cLho; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=networkplumber.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id a13-20020a170906274d00b007891fd9179bsi1193994ejd.150.2022.11.11.10.31.22; Fri, 11 Nov 2022 10:31:44 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@networkplumber-org.20210112.gappssmtp.com header.s=20210112 header.b=0NM6cLho; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=networkplumber.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231911AbiKKRUz (ORCPT + 91 others); Fri, 11 Nov 2022 12:20:55 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59090 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233384AbiKKRUw (ORCPT ); Fri, 11 Nov 2022 12:20:52 -0500 Received: from mail-pj1-x102a.google.com (mail-pj1-x102a.google.com [IPv6:2607:f8b0:4864:20::102a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CBA0F4AF05 for ; Fri, 11 Nov 2022 09:20:51 -0800 (PST) Received: by mail-pj1-x102a.google.com with SMTP id b1-20020a17090a7ac100b00213fde52d49so5235571pjl.3 for ; Fri, 11 Nov 2022 09:20:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20210112.gappssmtp.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:from:to:cc:subject:date :message-id:reply-to; bh=Q7Xa+py3hjWExofDQ+1PRKQ3Oe9rzLGK9/H+JFsk8ag=; b=0NM6cLhoH+3WjjgYZBTbNSEPh49+js6VWNIUWiAJeeNh8tSXof6Nro/C+hEnmJWwiB Z9bOEBFJYbRowPCO40fyyS4rHwlONanG5yjUdlxKUjgy+mug694Rp7NHARCUEIrPm7RA QFbgZWQv93vAYE+VekT3Otr+QeE3eAE+Zjppdt0aHfRIxNZOQzJXE11edeuP7qiOME8h sMTbbhuu1zDpduNoEuZfBruldCUZX7s2kYSEWHzGG//CkBbgEE25Ci7952WjF/iqwsOG T8MAkMe2w+Z2R+WaNNv55iV+tX48ih2NPkgrSkh6PanMu0l2UUMOGEk9YbL6yVOueec4 k0ug== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=Q7Xa+py3hjWExofDQ+1PRKQ3Oe9rzLGK9/H+JFsk8ag=; b=JL3d1ipmvvc/3kxnBFa6BTMp7OhU50F7ZvbOZ02Y5CX3y85RVqvqjS9vDLMd6n4ZYH 4Cr7yWFaKlpEj2H5Hz4OQgyDmn7rCnGwMMwRszLQiTWYR9VWZFz1RezOHLO2FDjLRnT1 v6hiCykcBYVMNcVAjRJuDhwbMYB95hTO+G1s4k/9n1Sppl4ZZ+wPsnhdWHIYGkmryhUQ d1tWgxflwShRfwEZ+pbyfv05dZIV6i8pe9NLhC7MN0zndGh6mBoJgw5NUkxuUVboISgE hHpELrFyRxM13wiJTjMrD13DAyy7IN0HKoLMgtYLczPhUw8nuVxnRVDbT2mHdMp3f2sG AGxQ== X-Gm-Message-State: ANoB5pnpPsVh9gEICedKDOd4uB7BWpz43TPPSSgtmmZTkkSudraAT7T+ g5e98gtYRS0Bt1azfPhtLJHelQ== X-Received: by 2002:a17:902:7d89:b0:188:5c0c:758a with SMTP id a9-20020a1709027d8900b001885c0c758amr3381385plm.134.1668187251323; Fri, 11 Nov 2022 09:20:51 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id d207-20020a621dd8000000b0056be1581126sm1892393pfd.143.2022.11.11.09.20.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Nov 2022 09:20:50 -0800 (PST) Date: Fri, 11 Nov 2022 09:20:47 -0800 From: Stephen Hemminger To: Jamie Bainbridge Cc: Eric Dumazet , "David S. Miller" , Hideaki YOSHIFUJI , David Ahern , Jakub Kicinski , Paolo Abeni , netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v2] tcp: Add listening address to SYN flood message Message-ID: <20221111092047.7d33bcd3@hermes.local> In-Reply-To: <7ccd58e8e26bcdd82e66993cbd53ff59eebe3949.1668139105.git.jamie.bainbridge@gmail.com> References: <7ccd58e8e26bcdd82e66993cbd53ff59eebe3949.1668139105.git.jamie.bainbridge@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS autolearn=ham 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 Fri, 11 Nov 2022 14:59:32 +1100 Jamie Bainbridge wrote: > + xchg(&queue->synflood_warned, 1) == 0) { > + if (IS_ENABLED(CONFIG_IPV6) && sk->sk_family == AF_INET6) { > + net_info_ratelimited("%s: Possible SYN flooding on port %pI6c.%u. %s.\n", > + proto, &sk->sk_v6_rcv_saddr, > + sk->sk_num, msg); > + } else { > + net_info_ratelimited("%s: Possible SYN flooding on port %pI4.%u. %s.\n", > + proto, &sk->sk_rcv_saddr, > + sk->sk_num, msg); Minor nit, the standard format for printing addresses would be to use colon seperator before port if (IS_ENABLED(CONFIG_IPV6) && sk->sk_family == AF_INET6) { net_info_ratelimited("%s: Possible SYN flooding on [%pI6c]:%u. %s.\n", proto, &sk->sk_v6_rcv_saddr, sk->sk_num, msg); } else { net_info_ratelimited("%s: Possible SYN flooding on %pI4:%u. %s.\n", proto, &sk->sk_rcv_saddr, sk->sk_num, msg);