Function at 0x4aed7d
Capabilities:
Resolve function by parsing pe exports

Disassembly:
mov ecx, dword [ebp - 0x3c]
cmp ecx, edi
jne 0x5176cd
mov ecx, 0x483540
call dword [sym.imp.HAL.dll_ExAcquireFastMutex]
mov dword [0x483560], esi
cmp dword [ebx], edi
je 0x4d5e19
mov eax, dword [ebp - 0x1c]
test byte [eax + 0x93], 0x40
mov dword [ebp - 0x20], 0xc0000041
jne 0x4d5e19
mov dword [0x483560], edi
mov ecx, 0x483540
call dword [sym.imp.HAL.dll_ExReleaseFastMutex]
mov ecx, ebx
call sym.ntoskrnl.exe_ObfDereferenceObject
jmp 0x4af36a
push 0x84
push 0x41cf60
call fcn.0040ba92
mov eax, dword fs:[0x124]
mov dword [ebp - 0x40], eax
mov eax, dword fs:[0x124]
mov al, byte [eax + 0x140]
mov byte [ebp - 0x28], al
xor ebx, ebx
mov dword [ebp - 0x2c], ebx
test al, al
je 0x508218
mov dword [ebp - 4], ebx
mov ecx, dword [ebp + 8]
mov eax, dword [sym.ntoskrnl.exe_MmUserProbeAddress]
cmp ecx, eax
jae 0x5174e4
mov eax, dword [ecx]
mov dword [ecx], eax
mov edx, dword [ebp + 0x14]
cmp edx, ebx
je 0x4aee12
mov eax, dword [sym.ntoskrnl.exe_MmUserProbeAddress]
cmp edx, eax
mov esi, eax
jae 0x4aeddc
mov esi, edx
push 6
pop ecx
lea edi, [ebp - 0x94]
rep movsd dword es:[edi], dword [esi]
cmp dword [ebp - 0x94], 0x18
jne 0x5174eb
mov dword [ebp - 0x60], edx
cmp edx, eax
jae 0x5174f5
test dl, 3
jne 0x5174fd
mov al, byte [edx]
mov byte [edx], al
mov al, byte [edx + 0x14]
mov byte [edx + 0x14], al
mov ebx, dword [ebp + 0x1c]
xor esi, esi
cmp ebx, esi
je 0x4aee51
mov eax, dword [sym.ntoskrnl.exe_MmUserProbeAddress]
cmp ebx, eax
jae 0x51750a
mov ecx, dword [ebx]
cmp ecx, 0xc
jne 0x5174eb
mov dword [ebp - 0x64], ebx
cmp ebx, eax
jae 0x517511
test bl, 3
jne 0x517519
mov al, byte [ebx]
mov byte [ebx], al
mov al, byte [ebx + 8]
mov byte [ebx + 8], al
mov ecx, dword [ebp + 0x20]
cmp ecx, esi
je 0x4aee69
mov eax, dword [sym.ntoskrnl.exe_MmUserProbeAddress]
cmp ecx, eax
jae 0x517523
mov eax, dword [ecx]
mov dword [ecx], eax
mov ecx, dword [ebp + 0x28]
cmp ecx, esi
je 0x4aee8e
mov eax, dword [sym.ntoskrnl.exe_MmUserProbeAddress]
cmp ecx, eax
jae 0x51752a
mov edx, dword [ecx]
mov dword [ebp - 0x2c], edx
cmp ecx, eax
jae 0x517531
mov eax, dword [ecx]
mov dword [ecx], eax
cmp dword [ebp + 0x24], esi
je 0x4aeea0
push 1
push dword [ebp - 0x2c]
push dword [ebp + 0x24]
call sym.ntoskrnl.exe_ProbeForWrite
mov eax, dword [sym.ntoskrnl.exe_MmUserProbeAddress]
cmp dword [ebp + 0x10], eax
jae 0x4aeead
mov eax, dword [ebp + 0x10]
mov esi, eax
lea edi, [ebp - 0x7c]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
mov esi, dword [ebp + 0x18]
mov dword [ebp - 0x24], esi
test esi, esi
je 0x4aeedf
lea eax, [ebp - 0x24]
push eax
push 1
push 1
push 0
push 0
push dword [ebp - 0x28]
push esi
call fcn.004a96d2
mov dword [ebp - 0x20], eax
test eax, eax
jl 0x4d5e10
or dword [ebp - 4], 0xffffffff
xor ebx, ebx
lea eax, [ebp - 0x1c]
push eax
push ebx
push dword [ebp - 0x28]
push dword [sym.ntoskrnl.exe_LpcPortObjectType]
push 1
push ebx
push ebx
push dword [ebp + 0xc]
call sym.ntoskrnl.exe_ObReferenceObjectByName
mov edi, eax
cmp edi, 0xc0000024
je 0x505c73
cmp edi, ebx
jl 0x4cd970
mov ecx, dword [ebp - 0x1c]
mov eax, dword [ecx + 0x90]
and al, 0xf
cmp al, 1
jne 0x51756e
cmp esi, ebx
je 0x4aefa7
mov eax, dword [ecx + 0x88]
cmp eax, ebx
je 0x4d5df6
push eax
call sym.ntoskrnl.exe_PsReferencePrimaryToken
mov edi, eax
lea eax, [ebp - 0x4c]
push eax
push 1
push edi
call sym.ntoskrnl.exe_SeQueryInformationToken
mov dword [ebp - 0x20], eax
mov eax, dword [ebp - 0x1c]
mov ecx, dword [eax + 0x88]
add ecx, 0xc8
mov edx, edi
call fcn.00493829
cmp dword [ebp - 0x20], ebx
jl 0x4aef8a
mov eax, dword [ebp - 0x4c]
push dword [eax]
push dword [ebp - 0x24]
call sym.ntoskrnl.exe_RtlEqualSid
test al, al
je 0x51758f
push ebx
push dword [ebp - 0x4c]
call sym.ntoskrnl.exe_ExFreePoolWithTag
cmp dword [ebp - 0x24], esi
je 0x4aef9c
push 1
push dword [ebp - 0x28]
push dword [ebp - 0x24]
call fcn.004a97a3
mov esi, dword [ebp - 0x20]
cmp esi, ebx
jl 0x5175a2
lea eax, [ebp - 0x38]
push eax
push ebx
push ebx
push 0x94
push ebx
push dword [ebp - 0x28]
push ebx
push dword [sym.ntoskrnl.exe_LpcPortObjectType]
push dword [ebp - 0x28]
call sym.ntoskrnl.exe_ObCreateObject
cmp eax, ebx
jl 0x5175a0
push 0x25
pop ecx
xor eax, eax
mov ebx, dword [ebp - 0x38]
mov edi, ebx
rep stosd dword es:[edi], eax
mov dword [ebx + 0x90], 4
mov eax, dword [ebp - 0x1c]
mov dword [ebx], eax
mov eax, dword [ebp - 0x1c]
mov ax, word [eax + 0x8c]
mov word [ebx + 0x8c], ax
lea edi, [ebx + 0x30]
lea esi, [ebp - 0x7c]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
lea eax, [ebx + 0x78]
mov dword [eax + 4], eax
mov dword [eax], eax
lea eax, [ebx + 0x80]
mov dword [eax + 4], eax
mov dword [eax], eax
cmp byte [ebp - 0x74], 1
jne 0x50863d
or byte [ebx + 0x93], 0x80
push ebx
call fcn.004af649
xor esi, esi
cmp eax, esi
jl 0x4d5e02
cmp dword [ebp + 0x14], esi
je 0x4c1c27
push esi
lea eax, [ebp - 0x48]
push eax
push dword [ebp - 0x28]
push dword [sym.ntoskrnl.exe_MmSectionObjectType]
push 6
push dword [ebp - 0x90]
call sym.ntoskrnl.exe_ObReferenceObjectByHandle
mov ecx, dword [ebp - 0x48]
mov dword [ebp - 0x3c], ecx
cmp eax, esi
jl 0x4d5e02
mov eax, dword [ebp - 0x8c]
mov dword [ebp - 0x70], eax
xor ecx, ecx
mov dword [ebp - 0x6c], ecx
mov eax, dword fs:[0x124]
mov esi, dword [eax + 0x44]
lea edi, [ebx + 0x20]
push 4
push ecx
push 2
lea eax, [ebp - 0x88]
push eax
lea eax, [ebp - 0x70]
push eax
push ecx
push ecx
push edi
push esi
push dword [ebp - 0x48]
call sym.ntoskrnl.exe_MmMapViewOfSection
mov dword [ebp - 0x20], eax
mov ecx, dword [ebp - 0x70]
mov dword [ebp - 0x8c], ecx
test eax, eax
jl 0x5175a7
mov eax, dword [edi]
mov dword [ebp - 0x84], eax
mov dword [ebx + 0x88], esi
mov ecx, esi
call sym.ntoskrnl.exe_ObfReferenceObject
mov eax, dword [ebp - 0x1c]
movzx eax, word [eax + 0x8e]
cmp dword [ebp - 0x2c], eax
ja 0x5175b9
push 0x47c180
call sym.ntoskrnl.exe_ExAllocateFromPagedLookasideList
test eax, eax
je 0x4d5e09
mov dword [eax + 4], eax
mov dword [eax], eax
and dword [eax + 0xc], 0
and word [eax + 0x1c], 0
mov ebx, eax
mov dword [ebp - 0x50], ebx
mov dword [ebp - 0x44], ebx
test ebx, ebx
je 0x5175c1
lea edi, [ebx + 0x30]
mov dword [ebp - 0x34], edi
mov eax, dword [ebp - 0x40]
mov ecx, dword [eax + 0x1ec]
mov dword [ebx + 0x20], ecx
mov eax, dword [eax + 0x1f0]
mov dword [ebx + 0x24], eax
mov edx, edi
cmp dword [ebp + 0x14], 0
je 0x4c1c17
mov eax, dword [ebp - 0x88]
mov dword [ebx + 0x2c], eax
push 6
pop ecx
lea esi, [ebp - 0x94]
rep movsd dword es:[edi], dword [esi]
xor eax, eax
lea edi, [edx + 0x20]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
and dword [edx + 0x18], 0
mov eax, dword [ebp - 0x3c]
mov dword [edx + 0x1c], eax
mov ecx, dword [ebp - 0x2c]
lea eax, [ecx + 0x2c]
mov word [ebx + 0x18], ax
add eax, 0x30
mov word [ebx + 0x1a], ax
mov word [ebx + 0x1c], 0xa
mov esi, dword [ebp + 0x24]
test esi, esi
je 0x4af191
mov dword [ebp - 4], 1
lea edi, [edx + 0x2c]
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
or dword [ebp - 4], 0xffffffff
xor edi, edi
mov dword [ebp - 0x20], edi
mov ecx, 0x483540
call dword [sym.imp.HAL.dll_ExAcquireFastMutex]
mov esi, dword [ebp - 0x40]
mov dword [0x483560], esi
mov eax, dword [ebp - 0x1c]
test byte [eax + 0x93], 0x40
jne 0x5175e3
mov dword [ebx + 0xc], edi
mov eax, dword [0x5b5eb4]
mov dword [ebx + 0x28], eax
inc dword [0x5b5eb4]
je 0x517630
mov eax, dword [ebx + 0x28]
mov dword [esi + 0x23c], eax
mov eax, dword [ebp - 0x1c]
add eax, 0x10
mov ecx, dword [eax + 4]
mov dword [ebx], eax
mov dword [ebx + 4], ecx
mov dword [ecx], ebx
mov dword [eax + 4], ebx
lea eax, [esi + 0x1c8]
mov ecx, dword [ebp - 0x1c]
add ecx, 0x78
mov edx, dword [ecx + 4]
mov dword [eax], ecx
mov dword [eax + 4], edx
mov dword [edx], eax
mov dword [ecx + 4], eax
mov dword [esi + 0x208], ebx
mov ebx, dword [ebp - 0x38]
mov ecx, ebx
call sym.ntoskrnl.exe_ObfReferenceObject
mov eax, dword [ebp - 0x34]
mov dword [eax + 0x18], ebx
dec dword [esi + 0xd4]
mov dword [0x483560], edi
mov ecx, 0x483540
call dword [sym.imp.HAL.dll_ExReleaseFastMutex]
cmp dword [ebp - 0x20], edi
jl 0x4af27d
mov eax, dword [ebp - 0x1c]
test byte [eax + 0x93], 0x20
jne 0x505c94
push edi
push 1
push 1
push dword [eax + 0xc]
call sym.ntoskrnl.exe_KeReleaseSemaphore
inc dword [esi + 0xd4]
jne 0x4af268
lea eax, [esi + 0x34]
cmp dword [eax], eax
jne 0x51763f
push edi
push edi
push dword [ebp - 0x28]
push edi
lea eax, [esi + 0x1f4]
push eax
call sym.ntoskrnl.exe_KeWaitForMutexObject
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0x20], 0xc0
je 0x517650
lea eax, [ebp - 0x34]
push esi
push eax
lea eax, [ebp - 0x44]
push eax
call fcn.004af5ba
cmp dword [ebp - 0x20], edi
jne 0x5176f9
mov ecx, eax
mov dword [ebp - 0x3c], ecx
mov eax, dword [ebp - 0x44]
cmp eax, edi
je 0x5176dc
movsx eax, word [eax + 0x18]
add eax, 0xffffffd4
cmp eax, dword [ebp - 0x2c]
jb 0x517677
cmp dword [ebp + 0x24], edi
je 0x4af2fc
mov dword [ebp - 4], 2
mov eax, dword [ebp + 0x28]
cmp eax, edi
je 0x4af2d9
mov ecx, dword [ebp - 0x2c]
mov dword [eax], ecx
mov ecx, dword [ebp - 0x2c]
mov esi, dword [ebp - 0x34]
add esi, 0x2c
mov edi, dword [ebp + 0x24]
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
or dword [ebp - 4], 0xffffffff
xor edi, edi
mov esi, dword [ebp - 0x40]
mov ebx, dword [ebp - 0x38]
cmp dword [ebx + 4], edi
je 0x4ad6eb
mov eax, dword [ebp - 0x1c]
movzx esi, word [eax + 0x8c]
lea eax, [ebp - 0x30]
push eax
push edi
push edi
push 0x1f0001
push edi
push ebx
call sym.ntoskrnl.exe_ObInsertObject
mov dword [ebp - 0x20], eax
cmp eax, edi
jl 0x4af36a
mov dword [ebp - 4], 3
mov eax, dword [ebp - 0x30]
mov ecx, dword [ebp + 8]
mov dword [ecx], eax
mov eax, dword [ebp + 0x20]
cmp eax, edi
je 0x4af343
mov dword [eax], esi
cmp dword [ebp + 0x14], edi
je 0x4af355
push 6
pop ecx
mov esi, dword [ebp - 0x34]
mov edi, dword [ebp + 0x14]
rep movsd dword es:[edi], dword [esi]
xor edi, edi
cmp dword [ebp + 0x1c], edi
je 0x4af366
mov esi, dword [ebp - 0x34]
add esi, 0x20
mov edi, dword [ebp + 0x1c]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
or dword [ebp - 4], 0xffffffff
xor edx, edx
mov ecx, dword [ebp - 0x44]
call fcn.00493664
mov eax, dword [ebp - 0x20]
call fcn.0040bad2
ret 0x24
and dword [ebx + 0x2c], 0
push 0xb
pop ecx
xor eax, eax
rep stosd dword es:[edi], eax
jmp 0x4af14d
mov dword [ebp - 0x3c], esi
jmp 0x4af0c7
cmp dword [ebp - 0x24], esi
jne 0x4cde65
mov eax, edi
jmp 0x4af377
push 1
push dword [ebp - 0x28]
push dword [ebp - 0x24]
call fcn.004a97a3
jmp 0x4cd979
cmp dword [esi], 0x18
jne 0x517564
push 6
pop ecx
lea edi, [ebp - 0x94]
rep movsd dword es:[edi], dword [esi]
jmp 0x508223
mov dword [ebp - 0x20], 0xc00002a0
jmp 0x4aef8a
mov esi, eax
jmp 0x5175d5
xor ebx, ebx
jmp 0x4af0fc
or dword [ebp - 4], 0xffffffff
jmp 0x4af377
mov dword [ebp - 0x20], 0xc0000034
jmp 0x4ad726
lea eax, [ebp - 0x1c]
push eax
push ebx
push dword [ebp - 0x28]
push dword [0x483564]
push 1
push ebx
push ebx
push dword [ebp + 0xc]
call sym.ntoskrnl.exe_ObReferenceObjectByName
mov edi, eax
jmp 0x4aef0d
push edi
push 1
add eax, 0x94
push eax
call sym.ntoskrnl.exe_KeSetEvent
mov eax, dword [ebp - 0x1c]
jmp 0x4af248
mov esi, dword [ebp + 0x14]
cmp esi, ebx
jne 0x4d5ddd
mov eax, dword [ebp + 0x1c]
cmp eax, ebx
jne 0x51755b
mov eax, dword [ebp + 0x28]
cmp eax, ebx
je 0x50823a
mov eax, dword [eax]
mov dword [ebp - 0x2c], eax
mov esi, dword [ebp + 0x10]
lea edi, [ebp - 0x7c]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
mov esi, dword [ebp + 0x18]
mov dword [ebp - 0x24], esi
jmp 0x4aeee5
lea eax, [ebx + 0x3c]
push eax
push 0
lea eax, [ebp - 0x7c]
push eax
push dword [ebp - 0x40]
call sym.ntoskrnl.exe_SeCreateClientSecurity
test eax, eax
jl 0x4d5e02
jmp 0x4af026
mov dword [eax], ebx
jmp 0x4aedc4
mov eax, 0xc000000d
jmp 0x4d5e10
mov byte [eax], 0
jmp 0x4aedff
call sym.ntoskrnl.exe_ExRaiseDatatypeMisalignment
mov edx, dword [ebp + 0x14]
jmp 0x4aee08
mov ecx, dword [eax]
jmp 0x4aee2a
mov byte [eax], 0
jmp 0x4aee3e
call sym.ntoskrnl.exe_ExRaiseDatatypeMisalignment
jmp 0x4aee47
mov dword [eax], esi
jmp 0x4aee65
mov edx, dword [eax]
jmp 0x4aee7f
mov dword [eax], esi
jmp 0x4aee8a
cmp dword [eax], 0xc
je 0x50822e
mov eax, 0xc000000d
jmp 0x4af377
call sym.ntoskrnl.exe_ObfDereferenceObject
cmp dword [ebp - 0x24], esi
je 0x517585
push 1
push dword [ebp - 0x28]
push dword [ebp - 0x24]
call fcn.004a97a3
mov eax, 0xc0000042
jmp 0x4af377
mov dword [ebp - 0x20], 0xc00002a0
jmp 0x4aef81
mov esi, eax
mov ecx, dword [ebp - 0x1c]
jmp 0x5175d7
mov ecx, dword [ebp - 0x48]
call sym.ntoskrnl.exe_ObfDereferenceObject
mov esi, dword [ebp - 0x20]
jmp 0x5175d5
mov dword [ebp - 0x2c], eax
jmp 0x4af0da
mov ecx, dword [ebp - 0x3c]
test ecx, ecx
je 0x5175cd
call sym.ntoskrnl.exe_ObfDereferenceObject
mov esi, 0xc0000017
mov ebx, dword [ebp - 0x38]
mov ecx, ebx
call sym.ntoskrnl.exe_ObfDereferenceObject
mov eax, esi
jmp 0x4af377
mov dword [ebp - 0x20], 0xc0000034
jmp 0x4af222
mov dword [0x5b5eb4], 1
jmp 0x4af1d1
mov byte [esi + 0x49], 1
mov cl, 1
call dword [sym.imp.HAL.dll_HalRequestSoftwareInterrupt]
jmp 0x4af268
lea ebx, [esi + 0x1f4]
push ebx
call sym.ntoskrnl.exe_KeReadStateEvent
test eax, eax
je 0x4af28a
push edi
push edi
push edi
push 7
push ebx
call sym.ntoskrnl.exe_KeWaitForMutexObject
mov dword [ebp - 0x20], edi
jmp 0x4af28a
mov dword [ebp - 0x2c], eax
jmp 0x4af2c1
call sym.ntoskrnl.exe_ObfDereferenceObject
jmp 0x4ad6f6
cmp ecx, edi
je 0x5176e5
call sym.ntoskrnl.exe_ObfDereferenceObject
mov ecx, dword [ebp - 0x38]
call sym.ntoskrnl.exe_ObfDereferenceObject
mov dword [ebp - 0x20], 0xc0000041
jmp 0x4af374
mov ebx, eax
add esi, 0x1f4
push esi
call sym.ntoskrnl.exe_KeReadStateEvent
test eax, eax
je 0x517716
push edi
push edi
push edi
push 7
push esi
call sym.ntoskrnl.exe_KeWaitForMutexObject
mov ecx, dword [ebp - 0x44]
cmp ecx, edi
je 0x517724
xor edx, edx
call fcn.00493664
cmp ebx, edi
je 0x51772f
mov ecx, ebx
call sym.ntoskrnl.exe_ObfDereferenceObject
mov ecx, dword [ebp - 0x38]
call sym.ntoskrnl.exe_ObfDereferenceObject
jmp 0x4af374