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]
Message-ID: <20070412104924.GF4095@ftp.linux.org.uk>
Date:	Thu, 12 Apr 2007 11:49:24 +0100
From:	Al Viro <viro@....linux.org.uk>
To:	jjohansen@...e.de
Cc:	linux-kernel@...r.kernel.org,
	linux-security-module@...r.kernel.org,
	linux-fsdevel@...r.kernel.org, chrisw@...s-sol.org,
	Andreas Gruenbacher <agruen@...e.de>
Subject: Re: [AppArmor 33/41] Add d_namespace_path() to obtain namespace relative pathnames

> +char *d_namespace_path(struct dentry *dentry, struct vfsmount *vfsmnt,
> +		       char *buf, int buflen)
> +{
> +	char *res;
> +	struct vfsmount *rootmnt, *nsrootmnt;
> +	struct dentry *root;
> +
> +	read_lock(&current->fs->lock);
> +	rootmnt = mntget(current->fs->rootmnt);
> +	read_unlock(&current->fs->lock);
> +	spin_lock(&vfsmount_lock);
> +	nsrootmnt = mntget(rootmnt->mnt_ns->root);

... and when somebody does umount -l on your chroot jail, you get
NULL ->mnt_ns.  Oops...
-
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