Bug 181795 (CVE-2006-0555)
Summary: | CVE-2006-0555 NFS client panic using O_DIRECT | ||||||
---|---|---|---|---|---|---|---|
Product: | [Other] Security Response | Reporter: | Mark J. Cox <mjc> | ||||
Component: | vulnerability | Assignee: | Steve Dickson <steved> | ||||
Status: | CLOSED ERRATA | QA Contact: | Brian Brock <bbrock> | ||||
Severity: | high | Docs Contact: | |||||
Priority: | medium | ||||||
Version: | unspecified | CC: | jbaron, security-response-team, steved | ||||
Target Milestone: | --- | Keywords: | Security | ||||
Target Release: | --- | ||||||
Hardware: | All | ||||||
OS: | Linux | ||||||
Whiteboard: | |||||||
Fixed In Version: | RHSA-2006-0493 | Doc Type: | Bug Fix | ||||
Doc Text: | Story Points: | --- | |||||
Clone Of: | Environment: | ||||||
Last Closed: | 2006-05-24 09:27:57 UTC | Type: | --- | ||||
Regression: | --- | Mount Type: | --- | ||||
Documentation: | --- | CRM: | |||||
Verified Versions: | Category: | --- | |||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
Cloudforms Team: | --- | Target Upstream Version: | |||||
Embargoed: | |||||||
Attachments: |
|
Description
Mark J. Cox
2006-02-16 16:49:04 UTC
Proposed fix from Mike: @@ -88,6 +88,15 @@ nfs_get_user_pages(int rw, unsigned long *pages, NULL); up_read(¤t->mm->mmap_sem); } + + BUG_ON(result > page_count); + /* + * If we got fewer pages than expected from get_user_pages(), + * the user buffer runs off the end of a mapping; return EFAULT. + */ + if (result > 0 && result < page_count) + result = -EFAULT; + return result; } Trond followed up with: Since get_user_pages() hasn't returned an error here, I think you'll find you also need to ensure that the pages it returned get released correctly. Also, a result of zero pages could, AFAICS, create the same panic. Perhaps something like the following instead? if (result >= 0 && result < page_count) { nfs_free_user_pages(*pages, result, 0); *pages = NULL; result = -EFAULT; } embargo set at 20060227:1600 Created attachment 128145 [details]
purposed patch
committed in stream U4 build 34.24. A test kernel with this patch is available from http://people.redhat.com/~jbaron/rhel4/ An advisory has been issued which should help the problem described in this bug report. This report is therefore being closed with a resolution of ERRATA. For more information on the solution and/or where to find the updated files, please follow the link below. You may reopen this bug report if the solution does not work for you. http://rhn.redhat.com/errata/RHSA-2006-0493.html |