lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Thu, 2 Aug 2007 19:31:57 +0200
From:	"Rafael J. Wysocki" <rjw@...k.pl>
To:	Andrew Morton <akpm@...ux-foundation.org>
Cc:	linux-kernel@...r.kernel.org, Tejun Heo <htejun@...il.com>,
	Greg KH <greg@...ah.com>
Subject: Re: 2.6.23-rc1-mm2: Fix crash in sysfs_hash_and_remove

From: Rafael J. Wysocki <rjw@...k.pl>

My test box crashes during suspend, while the nonboot CPUs are being disabled,
because sysfs_hash_and_remove() doesn't check if dir_sd passed to it is not
NULL.  Fix it.

Signed-off-by: Rafael J. Wysocki <rjw@...k.pl>
---
 fs/sysfs/inode.c |    2 ++
 1 file changed, 2 insertions(+)

Index: linux-2.6.23-rc1-mm2/fs/sysfs/inode.c
===================================================================
--- linux-2.6.23-rc1-mm2.orig/fs/sysfs/inode.c
+++ linux-2.6.23-rc1-mm2/fs/sysfs/inode.c
@@ -191,6 +191,8 @@ int sysfs_hash_and_remove(struct kobject
 	struct sysfs_addrm_cxt acxt;
 	struct sysfs_dirent **pos, *sd;
 
+	if (!dir_sd)
+		return -ENOENT;
 	sysfs_addrm_start(&acxt, dir_sd);
 	if (!sysfs_resolve_for_remove(kobj, &acxt.parent_sd))
 		goto addrm_finish;
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ