Received: by 2002:ab2:69cc:0:b0:1f4:be93:e15a with SMTP id n12csp281291lqp; Fri, 12 Apr 2024 18:50:31 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUA0rNbYGTFeQd5jNiPqiJt+wQ+aB5KHNe8EwGZUUWPa+yKQgbp4qLRDCwKuh9EgxWYJggnbSCt4uCiw+4MrvDXliN9rI/JLx/aakcBUQ== X-Google-Smtp-Source: AGHT+IFLQKexEMq5X+uCTp6WpNpCeb3dOsfLKQTL3U/0AXD41dXVseh1uAE3gGwYTatFd5RXl/wn X-Received: by 2002:a17:902:db06:b0:1e0:e8b5:3225 with SMTP id m6-20020a170902db0600b001e0e8b53225mr5381203plx.12.1712973031301; Fri, 12 Apr 2024 18:50:31 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1712973031; cv=pass; d=google.com; s=arc-20160816; b=qQ112F880ItT5/EwY0S8Z0871jZyHcV0j/dHCAm2wOVXSprmzNPPedbn/Nid4sZuc0 bBHGxQNI2qiY2c+qmpylXmKaSdqn55Qv00HSzaTFGeoGfZuNN0gHSStsOgx+Hum/Kk0j otBRQYdqQH6vWN8n4HXhow85niU3D7ZUOpKhRMfYt9vx54llwFkGvGU5gTkHynJCnyjw dwW5D9PTi8XArkvRM4YI21tmx3E0gSL02hXRI5VIsmJF9Hs2f51tU/ETl5MtyHkij3mr H78tTkpPySSE92kf1VOqw/UEbYsBYJMZ3Zdiin6XVnVgq7r85dMR2bzgQIC4vKh440mc OJHA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:list-unsubscribe:list-subscribe :list-id:precedence:dkim-signature; bh=4GoxZ/DDCn693PM29RJyJPYwUobIu0pR6Xc9xkzx0qE=; fh=KY6szYI3k+kB2sEyyfBLvaKZCRZsEUpcM1SyBQNL7G8=; b=G4G2NtTYsOoHVgJqaNJkeS1C4dUj1E4RXOFNQ2D74fCNSzF73Pk/ZQGhPm/XbXUH59 iwiJ7Ah4L84zFoOXF/mSEBBm+0kY0VxvrxP0nED9uqBr/9D6QLHTaqTv4JwU+uiEeH1Y nbEDyzRbOhDAk1TYJHMMforb/xemd3Phe0FZ0ucSgycSoiwXnW93NLo5/r9RTPpmTKoe R9FGBiD+InPoyHo/wdlHq5JZxiHqiGwkOCygeZ70Y0mJnsgfkaskLVZeC3omolrXaApR epFLuRw21G5rVC/JrSAUxjEgX39J4BGP88Vo5WC9cThw1jdjAGG2hGJPAT4TAUE8zBHw cfnw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=fNrSaqOH; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-143501-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-143501-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [2604:1380:40f1:3f00::1]) by mx.google.com with ESMTPS id k13-20020a170902d58d00b001e43f6d20c9si4275224plh.606.2024.04.12.18.50.30 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 12 Apr 2024 18:50:31 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-143501-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) client-ip=2604:1380:40f1:3f00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=fNrSaqOH; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-143501-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-143501-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 sy.mirrors.kernel.org (Postfix) with ESMTPS id 67BF7B219C5 for ; Sat, 13 Apr 2024 01:50:27 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id EACAA1078B; Sat, 13 Apr 2024 01:50:17 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="fNrSaqOH" Received: from mail-pj1-f52.google.com (mail-pj1-f52.google.com [209.85.216.52]) (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 E9DD546BA; Sat, 13 Apr 2024 01:50:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.216.52 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712973017; cv=none; b=KXVrmwZL+RR4l5UbDUImOmMu9uhNdrxv6vCSjcC31MSHUs7fE+7BDq9sXy71+7rHFNMcsWtpU9otlKVfWWZW8aZT8O3uYLfQk/rWXqkLwrGGKlk4H7cZFWyFJPX1Zn8FGn5COO01Qq3hZnMtGtpNTjPsLEGWi88BDsd4VM3qtow= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712973017; c=relaxed/simple; bh=nK7S4AX7MvARgqM6BBHBiwuYAnJjjYfTAUaMHXm0s7s=; h=MIME-Version:References:In-Reply-To:From:Date:Message-ID:Subject: To:Cc:Content-Type; b=U2xrzWrmLvbFu6S7YoamNJgG24hdzIuz8Uxv9pD54RlnmzlwGyu9NpcvFhnL9FxI30t31x0LLuStMhaQCNnSc2I/V0uB8/e2z7df8eTOzZMrljFk+tA+SKcWcGz6Kb9mi8hg/K/JMHrNabMmMGu/h07lAU1nSQrz+BE863OTn9Y= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=fNrSaqOH; arc=none smtp.client-ip=209.85.216.52 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-pj1-f52.google.com with SMTP id 98e67ed59e1d1-2a2d0ca3c92so986493a91.0; Fri, 12 Apr 2024 18:50:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1712973015; x=1713577815; darn=vger.kernel.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=4GoxZ/DDCn693PM29RJyJPYwUobIu0pR6Xc9xkzx0qE=; b=fNrSaqOHzM3eH+01xq9bOJj41HrL/gZ+mehDlcXFXKa5e1VGoCAYLXjb/3PJGxwPtC Q54QYm90XtMzOQkwGS9+T8XOmnlDguCL4jFm8RmPAwv3EGPyzbh505QXTAivmI9slmdG vIcp5ZY6FydAMNksZ0O+N1cm6cnQsNg6u5f1j8+bzVlAGO/2usosmlxXMGRIpMe8MJob dvy9KOQemat+M+Ii3kyC7DDzKsY3kUNabCmsKYvp2nTjXdfnJlgPzrnvTNuxWw/abXqa 2790AeMb/Vhgrt1bidNo29EuTRDuEKXyRJYXhRRmf+q0/9DdmEj1L1v6H1AiA1nDOpRJ SzBg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1712973015; x=1713577815; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=4GoxZ/DDCn693PM29RJyJPYwUobIu0pR6Xc9xkzx0qE=; b=fuD2pBeQVB+nQD6sgfPTnK0wbD150HtcMJ+iL1VG3s1h6Z+mrjdV9WanzuxVem19+I 9H+UBASz5VVwgTwk7CFEusa7TYaYOyaTGnNDWH/VFs/cMdUI8IGVAKMigTVySDZwfEAp ZSxe2LDbhtMrkKaSTZwG5JGWea8SiRX83sSdYM33+0dumaW4R4g/2iPIM+06ePB7yntH MYN/2EtggHsPFMXXIWv0C/Nsrpp/YgKNX/uIfKeHQjYCLUZk1b8PJUgLWFNGPxMrgwpI 6vYeZJrntMzrwdcJF0ffyPAy0VyqKYWVbROBW/71Xbfccy0BOkPOg+Gv+9GFUzsrP4Je 0u0A== X-Forwarded-Encrypted: i=1; AJvYcCUxNLpc1aY7giA4IA0O1sicXLYUnKBeNfzC9Pnk/bB5IXJOP/RpQCZDnWl2NDEocXc6J/uSH2fZY5yOoqHd7xvgUdLCJDH1tV2nW5dQoxaKkZntyN68CDYihaQDbgxnAbyLKS1a4KU5pyEL36UQDSU58bPw+X1Mod+8/ka/gi49NWzB/J2Y X-Gm-Message-State: AOJu0Ywcs26gQ9iWqRuV9HrO7Vj0DxhWGMEAarPmUBJ9QnsPWi/FEpgp Ne/HjsqfhPlQmc7tsrkTJPwflZS5GmCZ4FK2XrfVsh4RyAJwN4dKdlaXmsv66MZQGD1XnnliRsJ gzrD+scO+3jT4pXdFMnsI/dSlD/0= X-Received: by 2002:a17:90b:8cb:b0:2a5:3c66:25a8 with SMTP id ds11-20020a17090b08cb00b002a53c6625a8mr10160280pjb.15.1712973015100; Fri, 12 Apr 2024 18:50:15 -0700 (PDT) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20240413-tcp-ao-selftests-fixes-v1-0-f9c41c96949d@gmail.com> <20240413-tcp-ao-selftests-fixes-v1-3-f9c41c96949d@gmail.com> In-Reply-To: <20240413-tcp-ao-selftests-fixes-v1-3-f9c41c96949d@gmail.com> From: Dmitry Safonov <0x7f454c46@gmail.com> Date: Sat, 13 Apr 2024 02:50:03 +0100 Message-ID: Subject: Re: [PATCH net 3/4] selftests/tcp_ao: Fix fscanf() call for format-security To: 0x7f454c46@gmail.com Cc: "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Shuah Khan , netdev@vger.kernel.org, linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Sat, 13 Apr 2024 at 02:43, Dmitry Safonov via B4 Relay wrote: > > From: Dmitry Safonov <0x7f454c46@gmail.com> > > On my new laptop with packages from nixos-unstable, gcc 12.3.0 produces: > > lib/proc.c: In function =E2=80=98netstat_read_type=E2=80=99: > > lib/proc.c:89:9: error: format not a string literal and no format argum= ents [-Werror=3Dformat-security] > > 89 | if (fscanf(fnetstat, type->header_name) =3D=3D EOF) > > | ^~ > > cc1: some warnings being treated as errors > > Here the selftests lib parses header name, while expectes non-space word > ending with a column. > > Fixes: cfbab37b3da0 ("selftests/net: Add TCP-AO library") > Signed-off-by: Dmitry Safonov <0x7f454c46@gmail.com> Actually, now I see that it was also reported, adding Reported-by: Muhammad Usama Anjum Link: https://lore.kernel.org/all/0c6d4f0d-2064-4444-986b-1d1ed782135f@coll= abora.com/ --=20 Dmitry