Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RpcCommon/Misc.c GetUnloadedLocationInfo, out of range buffer access #22

Closed
hfiref0x opened this issue Jan 15, 2019 · 0 comments
Closed

Comments

@hfiref0x
Copy link
Contributor

hfiref0x commented Jan 15, 2019

RpcCommon\Misc.c

memcpy(pLocationInfo->Location, pUnloadEventTrace->ImageName, sizeof(pLocationInfo->Location));

where

memcpy destination

WCHAR Location[MAX_PATH];

memcpy source

WCHAR ImageName[32]; // Image name

memcpy number of bytes to copy = sizeof(pLocationInfo->Location) is 520 bytes.

The 520 bytes copied from source may lead to crash if memory beyond this array is not available.

Split from #17

Edit:
By the way, I can't find where this routine used.

@hfiref0x hfiref0x changed the title RpcCommon\Misc.c GetUnloadedLocationInfo, out of range buffer access RpcCommon/Misc.c GetUnloadedLocationInfo, out of range buffer access Jan 15, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant