From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-qv1-f41.google.com (mail-qv1-f41.google.com [209.85.219.41]) (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 E640BB658 for ; Sun, 5 Jan 2025 17:48:43 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.219.41 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736099325; cv=none; b=C7xl9hE8LenxL5t9yBuEvxqY3DuWZdj6pwtfT1ZzhE8lQrZ9psam3NvJObdsYJe94e22Vr0ftujGogw+2L19VNkmAWFJpNTzADeaS4Z6QDZiqBTvKmSR88fUAm81EuMNIFdhXJ4+RIWKvKJhahs99W1dqZm00UXLw4McNhgT3Ak= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736099325; c=relaxed/simple; bh=VSKGgBXQitW70O3PlbpQGia2OfQLlQk/cJr0CNetNwQ=; h=Date:Message-ID:MIME-Version:Content-Type:From:To:Cc:Subject: References:In-Reply-To; b=Kh2mIWRZDxcx005pO4hpmSPWaHqNhcpI325n35ntM56WvK8rD0713wOk7z3XBayc+llAJ/23vu1+DT9kHhiFhi45xwJZ0QNIzIN1XiQIA6OV3X7bLgSax1L7b4V3MQT07c2YL1nouauRAlKmdWtTOEVvIWAuujxtVez5QJ2PVfo= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=paul-moore.com; spf=pass smtp.mailfrom=paul-moore.com; dkim=pass (2048-bit key) header.d=paul-moore.com header.i=@paul-moore.com header.b=AEqyPlUp; arc=none smtp.client-ip=209.85.219.41 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=paul-moore.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=paul-moore.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=paul-moore.com header.i=@paul-moore.com header.b="AEqyPlUp" Received: by mail-qv1-f41.google.com with SMTP id 6a1803df08f44-6d8e8445219so121803816d6.0 for ; Sun, 05 Jan 2025 09:48:43 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=paul-moore.com; s=google; t=1736099323; x=1736704123; darn=vger.kernel.org; h=in-reply-to:references:subject:cc:to:from:content-transfer-encoding :mime-version:message-id:date:from:to:cc:subject:date:message-id :reply-to; bh=eqFAn42MR7s18zOlzS1GbLo3k3bDKDCPzEgFCfO1vGQ=; b=AEqyPlUps09mnZk+9/ejA3Nl+Xm06DvS15Agk6gT5GY+nvQrxLJO0K0Xw7CpRmGHnh TnHjHPWd7s4Gc2iAzfN+a8bFGcQZnwuK+BUXUW0BNm2L86LqRxZHi7m+zqeDCsmZU5mW P09IjgbC/wMakH49fN8LcLfZCEoPMFbQYDAvsQMS+trE4kZ1rpVRchh/eatnRRyxVpt+ /kPcxJ1yvtoloLcR4j+dwO4i81V9HuSiAEC3dst3OgM0YJexjWsW104SB3c2mY2MDjiS 7nehPqhsSYITgJCkPI+0kCCb9z/Erdj2BHNWx4oL6TSWgBlUizxTFmYxwp27x5dI4D9O YQ8A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1736099323; x=1736704123; h=in-reply-to:references:subject:cc:to:from:content-transfer-encoding :mime-version:message-id:date:x-gm-message-state:from:to:cc:subject :date:message-id:reply-to; bh=eqFAn42MR7s18zOlzS1GbLo3k3bDKDCPzEgFCfO1vGQ=; b=ZEFFwdgXLbCWAzHAr3y22C5SV9Go0n4oY88F8M0axq2JHuZKthzsL1kpmf3LR3OA7n OXeImV/A/BP0RcnwzQg5PEp0MtWJG+oiZ2dqhLdRgRrAkVTXmSfYARvI9XJwYGqiC1ia YRtJgGTbfOIyWkqo/6+JNf/SwZ9Ood20vn6NUS1OwTUB/LLkLuOimCslGgcXx5MOLvSz NAbyUofwLKw8fHpLwK3HpszATj6M5kjOcN77EtjWZgHjG4UsEtQeWOigvq9fKkjA/y2P 2xlbeYUGWwogAy6f0aJt1fBteZxb7BmInCl2xhdSkb96dyJxLvEi+cNwvP7iuP39syQq zf6A== X-Forwarded-Encrypted: i=1; AJvYcCVKFFbiYq0mqSHrRaKH4IfvsKxvWQF1ww6NstCw+5HMsUISJ/W/RSbwd1ydNKGEEntr7zu3mmJM0ZAkXp8=@vger.kernel.org X-Gm-Message-State: AOJu0YyE2H2aAsp4zUjnOr+kDo7iWdD4eCG0Z2ln6SYgy45PqTU6UcIx 2aRXF5s7X/CDN6gI/Yboz08L1PZLSztqKNYnskA76YZkDQVEAPv0OYSOdaTxgQ== X-Gm-Gg: ASbGnctIvf3oiFFs5DDvemdLNeBJfcRMNu4XqiteuX8weVicTNsFzE7gajt1WAzzTwI qy8rfjnftFqP1ws6+9kIImpJ36IPsojbhXmCECTrTP590TIetbmOjwDHHo2/ujo7ZKU8P6wkFCg /mWftQuzIgNZQKL8VM/XrHWq/PbnT4LAapolUrQiCBBNIIQReaqTNaP20OUZT328PZuiBh8LZi+ OicBUSovqNvO/6mn8KHBpUHQc+IV7C+0kymt7xcTyLjN2d18D4= X-Google-Smtp-Source: AGHT+IEBG2Jubo3FltlrYRM8ERHRDZ/LXGRqqLAqTN9MUrsepD9bPzsvEaQWRSOl1ScA1KyeHxxvaA== X-Received: by 2002:ad4:5f89:0:b0:6d8:8416:9c54 with SMTP id 6a1803df08f44-6dd2333272amr1029158056d6.16.1736099322941; Sun, 05 Jan 2025 09:48:42 -0800 (PST) Received: from localhost ([70.22.175.108]) by smtp.gmail.com with ESMTPSA id 6a1803df08f44-6dd180ebe59sm162056656d6.27.2025.01.05.09.48.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 05 Jan 2025 09:48:42 -0800 (PST) Date: Sun, 05 Jan 2025 12:48:41 -0500 Message-ID: <2f7db63290c5c81513721f10a65f602e@paul-moore.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=UTF-8 Content-Transfer-Encoding: 8bit X-Mailer: pstg-pwork:20250105_1245/pstg-lib:20250105_1245/pstg-pwork:20250105_1245 From: Paul Moore To: Tanya Agarwal , jmorris@namei.org, serge@hallyn.com Cc: kees@kernel.org, yuehaibing@huawei.com, linux-security-module@vger.kernel.org, linux-kernel@vger.kernel.org, matthewgarrett@google.com, skhan@linuxfoundation.org, anupnewsmail@gmail.com, tanyaagarwal25699@gmail.com Subject: Re: [PATCH v3] lockdown: Initialize array before use References: <20250105070537.58334-1-tanyaagarwal25699@gmail.com> In-Reply-To: <20250105070537.58334-1-tanyaagarwal25699@gmail.com> On Jan 5, 2025 Tanya Agarwal wrote: > > The static code analysis tool "Coverity Scan" pointed the following > details out for further development considerations: > CID 1486102: Uninitialized scalar variable (UNINIT) > uninit_use_in_call: Using uninitialized value *temp when calling > strlen. > > Conclusion: > Initialize array before use in lockdown_read() to satisfy the static > analyzer. > > Fixes: 000d388ed3bb ("security: Add a static lockdown policy LSM") > Signed-off-by: Tanya Agarwal I removed the 'Fixes:' tag as the code isn't actually broken as we discussed in previous iterations of this patch. I also edited the subject line and commit description a bit, but otherwise this is fine. Merged into lsm/dev. -- paul-moore.com