From: Chris Wright <chrisw@sous-sol.org>
To: torvalds@osdl.org, akpm@osdl.org
Cc: Olaf Kirch <okir@suse.de>, Greg KH <greg@kroah.com>,
linux-kernel@vger.kernel.org, stable@kernel.org,
Steven French <sfrench@us.ibm.com>,
shaggy@austin.ibm.com, Mark Moseley <moseleymark@gmail.com>,
Marcel Holtmann <holtmann@redhat.com>
Subject: [PATCH resend] smbfs chroot issue (CVE-2006-1864)
Date: Tue, 9 May 2006 13:29:23 -0700 [thread overview]
Message-ID: <20060509202923.GS24291@moss.sous-sol.org> (raw)
From: Olaf Kirch <okir@suse.de>
Mark Moseley reported that a chroot environment on a SMB share can be
left via "cd ..\\". Similar to CVE-2006-1863 issue with cifs, this fix
is for smbfs.
Steven French <sfrench@us.ibm.com> wrote:
Looks fine to me. This should catch the slash on lookup or equivalent,
which will be all obvious paths of interest.
Signed-off-by: Chris Wright <chrisw@sous-sol.org>
---
This fix is in -stable, but doesn't appear to be in your tree yet.
fs/smbfs/dir.c | 5 +++++
1 file changed, 5 insertions(+)
--- linus-2.6.orig/fs/smbfs/dir.c
+++ linus-2.6/fs/smbfs/dir.c
@@ -434,6 +434,11 @@ smb_lookup(struct inode *dir, struct den
if (dentry->d_name.len > SMB_MAXNAMELEN)
goto out;
+ /* Do not allow lookup of names with backslashes in */
+ error = -EINVAL;
+ if (memchr(dentry->d_name.name, '\\', dentry->d_name.len))
+ goto out;
+
lock_kernel();
error = smb_proc_getattr(dentry, &finfo);
#ifdef SMBFS_PARANOIA
_______________________________________________
stable mailing list
stable@linux.kernel.org
http://linux.kernel.org/mailman/listinfo/stable
reply other threads:[~2006-05-09 20:27 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20060509202923.GS24291@moss.sous-sol.org \
--to=chrisw@sous-sol.org \
--cc=akpm@osdl.org \
--cc=greg@kroah.com \
--cc=holtmann@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=moseleymark@gmail.com \
--cc=okir@suse.de \
--cc=sfrench@us.ibm.com \
--cc=shaggy@austin.ibm.com \
--cc=stable@kernel.org \
--cc=torvalds@osdl.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome