mirror of
https://github.com/X11Libre/xserver.git
synced 2026-11-03 03:24:39 +00:00
Xi: unvalidated lengths in Xinput extension [CVE-2014-8095]
Multiple functions in the Xinput extension handling of requests from clients failed to check that the length of the request sent by the client was large enough to perform all the required operations and thus could read or write to memory outside the bounds of the request buffer. This commit includes the creation of a new REQUEST_AT_LEAST_EXTRA_SIZE macro in include/dix.h for the common case of needing to ensure a request is large enough to include both the request itself and a minimum amount of extra data following the request header. Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
parent
2ef42519c4
commit
73c63afb93
17 changed files with 94 additions and 18 deletions
|
|
@ -50,6 +50,7 @@ int
|
|||
SProcXIGetClientPointer(ClientPtr client)
|
||||
{
|
||||
REQUEST(xXIGetClientPointerReq);
|
||||
REQUEST_SIZE_MATCH(xXIGetClientPointerReq);
|
||||
|
||||
swaps(&stuff->length);
|
||||
swapl(&stuff->win);
|
||||
|
|
|
|||
Loading…
Reference in a new issue