TUCoPS :: HP Unsorted N :: bu-1942.htm

ncpfs, Multiple Vulnerabilities
ncpfs, Multiple Vulnerabilities
ncpfs, Multiple Vulnerabilities



--00032555850ae47cf7048110ba94
Content-Type: text/plain; charset=ISO-8859-1

=========================================== ncpfs, Multiple Vulnerabilities
 March 5, 2010
 CVE-2010-0788, CVE-2010-0790, CVE-2010-0791
===========================================
==Description=
The ncpmount, ncpumount, and ncplogin utilities, installed as part of the ncpfs
package, contain several vulnerabilities.

1. ncpmount, ncpumount, and ncplogin are vulnerable to race conditions that
allow a local attacker to unmount arbitrary mountpoints, causing
denial-of-service, or mount Netware shares to arbitrary directories,
potentially leading to root compromise.  This issue was formerly assigned
CVE-2009-3297, but has since been re-assigned CVE-2010-0788 to avoid overlap
with related bugs in other packages.

2. ncpumount is vulnerable to an information disclosure vulnerability that
allows a local attacker to verify the existence of arbitrary files, violating
directory permissions.  This issue has been assigned CVE-2010-0790.

3. ncpmount, ncpumount, and ncplogin create lockfiles insecurely, allowing a
local attacker to leave a stale lockfile at /etc/mtab~, causing other mount
utilities to fail and creating denial-of-service conditions.  This issue has
been assigned CVE-2010-0791.

==Workaround=
If unprivileged users do not need the ability to mount and unmount Netware
shares, then the suid bit should be removed from these utilities.

==Solution=
A patch has been released that resolves these issues (attached to this
advisory).  ncpfs-2.2.6.partial.patch is intended for ncpfs releases that have
already been patched against the first vulnerability in this report
(CVE-2010-0788, formerly CVE-2009-3297).  It has been tested against the latest
ncpfs packages distributed by Fedora, Red Hat, and Mandriva.
ncpfs-2.2.6.full.patch is intended for ncpfs releases that have not been
patched against any of these vulnerabilities.  It has been tested against the
latest ncpfs packages distributed by Debian, Ubuntu, and the upstream release
(ftp://platan.vc.cvut.cz/pub/linux/ncpfs/). 

Users are advised to recompile from source, or request updated packages from
downstream distributors.

==Credits=
These vulnerabilities were discovered by Dan Rosenberg
(dan.j.rosenberg@gmail.com). 
Thanks to Vitezslav Crhonek for the patch against the first issue.

==References=
CVE identifiers CVE-2010-0788, CVE-2010-0790, and CVE-2010-0791 have been
assigned to these issues.

--00032555850ae47cf7048110ba94
Content-Type: text/x-patch; charset=US-ASCII; name="ncpfs-2.2.6.full.patch"
Content-Disposition: attachment; filename="ncpfs-2.2.6.full.patch"
Content-Transfer-Encoding: base64
X-Attachment-Id: f_g6f8i6ea0

ZGlmZiAtdXIgbmNwZnMtMi4yLjYub3JpZy9zdXRpbC9uY3Bsb2dpbi5jIG5jcGZzLTIuMi42L3N1
dGlsL25jcGxvZ2luLmMKLS0tIG5jcGZzLTIuMi42Lm9yaWcvc3V0aWwvbmNwbG9naW4uYwkyMDEw
LTAzLTAzIDE2OjE4OjU5LjAwMDAwMDAwMCAtMDUwMAorKysgbmNwZnMtMi4yLjYvc3V0aWwvbmNw
bG9naW4uYwkyMDEwLTAzLTAzIDE2OjE3OjQxLjAwMDAwMDAwMCAtMDUwMApAQCAtOTM0LDcgKzkz
NCw5IEBACiAJTldEU0ZyZWVDb250ZXh0KGN0eCk7CiAJLyogbmNwbWFwLCBuY3Bsb2dpbiBtdXN0
IHdyaXRlIGluIC9ldGMvbXRhYiAqLwogCXsKKwkJYmxvY2tfc2lncygpOwogCQlhZGRfbW50X2Vu
dHJ5KG1vdW50X25hbWUsIG1vdW50X3BvaW50LCBpbmZvLmZsYWdzKTsKKwkJdW5ibG9ja19zaWdz
KCk7CiAJfQogCWZyZWUobW91bnRfbmFtZSk7CiAJaWYgKGluZm8uZWNob19tbnRfcG50KSB7CmRp
ZmYgLXVyIG5jcGZzLTIuMi42Lm9yaWcvc3V0aWwvbmNwbV9jb21tb24uYyBuY3Bmcy0yLjIuNi9z
dXRpbC9uY3BtX2NvbW1vbi5jCi0tLSBuY3Bmcy0yLjIuNi5vcmlnL3N1dGlsL25jcG1fY29tbW9u
LmMJMjAxMC0wMy0wMyAxNjoxODo1OS4wMDAwMDAwMDAgLTA1MDAKKysrIG5jcGZzLTIuMi42L3N1
dGlsL25jcG1fY29tbW9uLmMJMjAxMC0wMy0wMyAxNjoxNz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NrX3NpZ3MoKTsKIAlyZXR1cm4gZXJy
OwogfQogCisKK2ludCBuY3BfbW50X3Vtb3VudChjb25zdCBjaGFyICphYnNfbW50LCBjb25zdCBj
aGFyICpyZWxfbW50KQoreworCWlmICh1bW91bnQocmVsX21udCkgIT0gMCkgeworCQllcHJpbnRm
KF8oIkNvdWxkIG5vdCB1bW91bnQgJXM6ICVzXG4iKSwKKwkJCWFic19tbnQsIHN0cmVycm9yKGVy
cm5vKSk7CisJCXJldHVybiAtMTsKKwl9CisJcmV0dXJuIDA7Cit9CisKKworc3RhdGljIGludCBj
aGVja19pc19tb3VudF9jaGlsZCh2b2lkICpwKQoreworCWNvbnN0IGNoYXIgKiphID0gcDsKKwlj
b25zdCBjaGFyICpsYXN0ID0gYVswXTsKKwljb25zdCBjaGFyICptbnQgPSBhWzFdOworCWludCBy
ZXM7CisJY29uc3QgY2hhciAqcHJvY21vdW50cyA9ICIvcHJvYy9tb3VudHMiOworCWludCBmb3Vu
ZDsKKwlGSUxFICpmcDsKKwlzdHJ1Y3QgbW50ZW50ICplbnRwOworCisJcmVzID0gbW91bnQoIiIs
ICIvIiwgIiIsIE1TX1NMQVZFIHwgTVNfUkVDLCBOVUxMKTsKKwlpZiAocmVzID09IC0xKSB7CisJ
CWVwcmludGYoXygiRmFpbGVkIHRvIG1hcmsgbW91bnRzIHNsYXZlOiAlc1xuIiksCisJCQlzdHJl
cnJvcihlcnJubykpOworCQlyZXR1cm4gMTsKKwl9CisKKwlyZXMgPSBtb3VudCgiLiIsICIvdG1w
IiwgIiIsIE1TX0JJTkQgfCBNU19SRUMsIE5VTEwpOworCWlmIChyZXMgPT0gLTEpIHsKKwkJZXBy
aW50ZihfKCJGYWlsZWQgdG8gYmluZCBwYXJlbnQgdG8gL3RtcDogJXNcbiIpLAorCQkJc3RyZXJy
b3IoZXJybm8pKTsKKwkJcmV0dXJuIDE7CisJfQorCisJZnAgPSBzZXRtbnRlbnQocHJvY21vdW50
cywgInIiKTsKKwlpZiAo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bW91
bnQobW91bnRfcG9pbnQpICE9IDApIHsKLQkJZXByaW50ZihfKCJDb3VsZCBub3QgdW1vdW50ICVz
OiAlc1xuIiksCi0JCQltb3VudF9wb2ludCwgc3RyZXJyb3IoZXJybm8pKTsKLQkJcmV0dXJuIC0x
OwotCX0KLQlyZXR1cm4gMDsKKwlyZXMgPSB1bm1vdW50X25jcChtb3VudF9wb2ludCk7CisJcmV0
dXJuIHJlczsKIH0KIAogCkBAIC00MDksNyArNjMzLDggQEAKIAlpbnQgYWxsQ29ubnMgPSAwOwog
CWNvbnN0IGNoYXIgKnNlcnZlck5hbWUgPSBOVUxMOwogCWNvbnN0IGNoYXIgKnRyZWVOYW1lID0g
TlVMTDsKLQl1aWRfdCB1aWQgPSBnZXR1aWQoKTsKKwkKKwl1aWQgPSBnZXR1aWQoKTsKIAogCXBy
b2duYW1lID0gc3RycmNocihhcmd2WzBdLCAnLycpOwogCWlmIChwcm9nbmFtZSkgewo--00032555850ae47cf7048110ba94
Content-Type: text/x-patch; charset=US-ASCII; name="ncpfs-2.2.6.partial.patch"
Content-Disposition: attachment; filename="ncpfs-2.2.6.partial.patch"
Content-Transfer-Encoding: base64
X-Attachment-Id: f_g6f8i9w71

ZGlmZiAtdXIgbmNwZnMtMi4yLjYub3JpZy9zdXRpbC9uY3Bsb2dpbi5jIG5jcGZzLTIuMi42L3N1
dGlsL25jcGxvZ2luLmMKLS0tIG5jcGZzLTIuMi42Lm9yaWcvc3V0aWwvbmNwbG9naW4uYwkyMDEw
LTAzLTAzIDE2OjEzOjQ1LjAwMDAwMDAwMCAtMDUwMAorKysgbmNwZnMtMi4yLjYvc3V0aWwvbmNw
bG9naW4uYwkyMDEwLTAzLTAzIDE2OjE3OjQxLjAwMDAwMDAwMCAtMDUwMApAQCAtOTM0LDcgKzkz
NCw5IEBACiAJTldEU0ZyZWVDb250ZXh0KGN0eCk7CiAJLyogbmNwbWFwLCBuY3Bsb2dpbiBtdXN0
IHdyaXRlIGluIC9ldGMvbX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ybiBlcnI7CiB9CiAKQEAgLTQyMiwxMyArNDY0
LDEzIEBACiAJaW50IHJlczsKIAogCWlmIChmaWQgPT0gLTEpIHsKLQkJZXByaW50ZihfKCJDb3Vs
ZCBub3Qgb3BlbiAlczogJXNcbiIpLAotCQkJbW91bnRfcG9pbnQsIHN0cmVycm9yKGVycm5vKSk7
CisJCWVwcmludGYoXygiSW52YWxpZCBvciB1bmF1dGhvcml6ZWQgbW91bnRwb2ludCAlc1xuIiks
CisJCQltb3VudF9wb2ludCk7CiAJCXJldHVybiAtMTsKIAl9CiAJaWYgKG5jcF9nZXRfbW91bnRf
dWlkKGZpZCwgJm1vdW50X3VpZCkgIT0gMCkgewogCQljbG9zZShmaWQpOwotCQllcHJpbnRmKF8o
IiVzIHByb2JhYmx5IG5vdCBuY3AtZmlsZXN5c3RlbVxuIiksCisJCWVwcmludGYoXygiSW52YWxp
ZCBvciB1bmF1dGhvcml6ZWQgbW91bnRwb2ludCAlc1xuIiksCiAJCQltb3VudF9wb2ludCk7CiAJ
CXJldHVybiAtMTsKIAl9CkBAIC01OTEsNyArNjMzLDggQEAKIAlpbnQgYWxsQ29ubnMgPSAwOwog
CWNvbnN0IGNoYXIgKnNlcnZlck5hbWUgPSBOVUxMOwogCWNvbnN0IGNoYXIgKnRyZWVOYW1lID0g
TlVMTDsKLQl1aWRfdCB1aWQgPSBnZXR1aWQoKTsKKwkKKwl1aWQgPSBnZXR1aWQoKTsKIAogCXBy
b2duYW1lID0gc3RycmNocihhcmd2WzBdLCAnLycpOwogCWlmIChwcm9nbmFtZSkgewo--00032555850ae47cf7048110ba94--

TUCoPS is optimized to look best in Firefox® on a widescreen monitor (1440x900 or better).
Site design & layout copyright © 1986-2024 AOH