Skip to content

Unhandled Memory Allocation Failure / Invalid Write #698

Description

@zachmse

Openclos.c calls ExAllocatePoolWithTag (line 1955) without checking to see if the allocation was successful. In cases where allocation failed, the subsequent call to RtlAppendUnicodeToString (line 1957) results in an invalid write.

pFiltMod->AdapterName.Buffer = ExAllocatePoolWithTag(NPF_NONPAGED, pFiltMod->AdapterName.MaximumLength, NPF_UNICODE_BUFFER_TAG);
pFiltMod->AdapterName.Length = 0;
RtlAppendUnicodeToString(&pFiltMod->AdapterName, AdapterName->Buffer + DEVICE_PATH_CCH);

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions