projects
/
xen.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2fece35
)
grant_table: fix GNTTABOP_cache_flush handling
author
Andrew Cooper
<andrew.cooper3@citrix.com>
Tue, 12 Sep 2017 12:44:11 +0000
(14:44 +0200)
committer
Jan Beulich
<jbeulich@suse.com>
Tue, 12 Sep 2017 12:44:11 +0000
(14:44 +0200)
Don't fall over a NULL grant_table pointer when the owner of the domain
is a system domain (DOMID_{XEN,IO} etc).
This is CVE-2017-14318 / XSA-232.
Reported-by: Matthew Daley <mattd@bugfuzz.com>
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Jan Beulich <jbeulich@suse.com>
xen/common/grant_table.c
patch
|
blob
|
history
diff --git
a/xen/common/grant_table.c
b/xen/common/grant_table.c
index fb3859ce8e12ba5f3f3b9b8bd1480bdf74d1297a..c3895e6201c523fa5ea5bfab506c56410e99187e 100644
(file)
--- a/
xen/common/grant_table.c
+++ b/
xen/common/grant_table.c
@@
-3046,7
+3046,7
@@
static int cache_flush(gnttab_cache_flush_t *cflush, grant_ref_t *cur_ref)
page = mfn_to_page(mfn);
owner = page_get_owner_and_reference(page);
- if ( !owner )
+ if ( !owner
|| !owner->grant_table
)
{
rcu_unlock_domain(d);
return -EPERM;