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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x50ee00
mov eax, dword fs:[0]
push eax
sub esp, 0x44
mov eax, dword [0x559540]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, ecx
mov dword [ebp - 0x38], ebx
cmp dword [ebx + 4], 1
mov dword [ebp - 0x50], vtable.nfapi::AutoLock.0
mov dword [ebp - 0x4c], 0x5646a4
push 0x5646a4
jne 0x4e7557
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
push dword [ebx + 0xc]
mov dword [ebp - 4], 0
push dword [ebx + 8]
push dword [0x564698]
call fcn.004eb120
mov edi, dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
add esp, 0xc
test eax, eax
je 0x4e754b
test byte [ebx + 0x10], 1
lea esi, [eax - 8]
je 0x4e7102
push 0x5646a4
mov dword [ebp - 0x30], vtable.nfapi::AutoUnlock.0
mov dword [ebp - 0x2c], 0x5646a4
call edi
mov ecx, dword [0x564588]
lea eax, [esi + 0x48]
push eax
push dword [ebx + 0xc]
mov byte [ebp - 4], 1
mov edx, dword [ecx]
push dword [ebx + 8]
call dword [edx + 0xc]
push 0x5646a4
mov byte [ebp - 4], 0
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov eax, dword [ebx + 0x10]
shr eax, 0x13
test al, 1
je 0x4e71fe
push 0x5646a4
mov dword [ebp - 0x30], vtable.nfapi::AutoUnlock.0
mov dword [ebp - 0x2c], 0x5646a4
call edi
mov ecx, dword [0x564588]
lea edx, [esi + 0x48]
push edx
push dword [ebx + 0xc]
mov byte [ebp - 4], 2
mov eax, dword [ecx]
push dword [ebx + 8]
call dword [eax + 8]
push 0x5646a4
mov byte [ebp - 4], 0
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
test byte [esi + 0x48], 0x40
jne 0x4e754b
push 0
push 0x53
call fcn.004eb240
mov edx, eax
add esp, 8
mov dword [ebp - 0x34], edx
test edx, edx
je 0x4e754b
mov ecx, dword [ebx + 8]
mov dword [edx + 4], ecx
mov ecx, dword [ebx + 0xc]
mov dword [edx + 8], ecx
mov dword [edx], 0x13
mov dword [edx + 0xc], 0x43
movdqu xmm0, xmmword [esi + 0x48]
push edx
movdqu xmmword [edx + 0x10], xmm0
movdqu xmm0, xmmword [esi + 0x58]
movdqu xmmword [edx + 0x20], xmm0
movdqu xmm0, xmmword [esi + 0x68]
movdqu xmmword [edx + 0x30], xmm0
movdqu xmm0, xmmword [esi + 0x78]
movdqu xmmword [edx + 0x40], xmm0
mov ax, word [esi + 0x88]
mov word [edx + 0x50], ax
mov al, byte [esi + 0x8a]
mov byte [edx + 0x52], al
call fcn.004e9670
push 0
push dword [ebp - 0x34]
call fcn.004eb2f0
add esp, 0xc
test byte [esi + 0x48], 1
je 0x4e71fe
push dword [ebx + 0xc]
push dword [ebx + 8]
call fcn.004e9940
push esi
call fcn.004e6c60
add esp, 0xc
push 0x5646a4
call edi
jmp 0x4e79ca
mov eax, dword [ebx + 0x10]
shr eax, 2
test al, 1
je 0x4e7302
mov edx, dword [esi + 0x1c]
lea eax, [esi + 0x14]
cmp dword [eax], eax
je 0x4e7302
lea ebx, [esi + 0x14]
lea ecx, [ecx]
mov edi, dword [ebx]
mov eax, dword [edi + 4]
mov ecx, dword [edi]
mov dword [eax], ecx
mov dword [ecx + 4], eax
mov eax, dword [esi + 0x1c]
mov ecx, dword [edi + 0x14]
cmp eax, ecx
jb 0x4e723d
sub eax, ecx
mov dword [esi + 0x1c], eax
jmp 0x4e7244
mov dword [esi + 0x1c], 0
mov eax, dword [edi + 0x14]
cmp edx, eax
jb 0x4e7252
sub edx, eax
mov dword [ebp - 0x28], edx
jmp 0x4e7259
mov dword [ebp - 0x28], 0
test byte [esi + 0x93], 4
push 0x5646a4
je 0x4e729f
mov dword [ebp - 0x30], vtable.nfapi::AutoUnlock.0
mov dword [ebp - 0x2c], 0x5646a4
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
push dword [edi + 0x14]
lea eax, [edi + 0x18]
mov byte [ebp - 4], 3
push eax
push dword [edi + 0x10]
push dword [edi + 0xc]
push 2
call fcn.004e9b40
add esp, 0x14
mov dword [ebp - 0x30], vtable.nfapi::AutoUnlock.0
jmp 0x4e72d6
mov dword [ebp - 0x40], vtable.nfapi::AutoUnlock.0
mov dword [ebp - 0x3c], 0x5646a4
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
push dword [edi + 0x14]
mov ecx, dword [0x564588]
lea eax, [edi + 0x18]
push eax
push dword [edi + 0x10]
mov byte [ebp - 4], 4
mov edx, dword [ecx]
push dword [edi + 0xc]
call dword [edx + 0x14]
mov dword [ebp - 0x40], vtable.nfapi::AutoUnlock.0
push 0x5646a4
mov byte [ebp - 4], 0
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
push 0
push edi
call fcn.004eb2f0
mov edx, dword [ebp - 0x28]
add esp, 8
test edx, edx
je 0x4e72ff
cmp dword [ebx], ebx
jne 0x4e7220
mov ebx, dword [ebp - 0x38]
mov eax, dword [ebx + 0x10]
shr eax, 3
test al, 1
je 0x4e7403
mov edx, dword [esi + 0x28]
lea eax, [esi + 0x20]
cmp dword [eax], eax
je 0x4e7403
lea ebx, [esi + 0x20]
mov edi, dword [ebx]
mov eax, dword [edi + 4]
mov ecx, dword [edi]
mov dword [eax], ecx
mov dword [ecx + 4], eax
mov eax, dword [esi + 0x28]
mov ecx, dword [edi + 0x14]
cmp eax, ecx
jb 0x4e733e
sub eax, ecx
mov dword [esi + 0x28], eax
jmp 0x4e7345
mov dword [esi + 0x28], 0
mov eax, dword [edi + 0x14]
cmp edx, eax
jb 0x4e7353
sub edx, eax
mov dword [ebp - 0x28], edx
jmp 0x4e735a
mov dword [ebp - 0x28], 0
test byte [esi + 0x93], 4
push 0x5646a4
je 0x4e73a0
mov dword [ebp - 0x30], vtable.nfapi::AutoUnlock.0
mov dword [ebp - 0x2c], 0x5646a4
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
push dword [edi + 0x14]
lea eax, [edi + 0x18]
mov byte [ebp - 4], 5
push eax
push dword [edi + 0x10]
push dword [edi + 0xc]
push 3
call fcn.004e9b40
add esp, 0x14
mov dword [ebp - 0x30], vtable.nfapi::AutoUnlock.0
jmp 0x4e73d7
mov dword [ebp - 0x40], vtable.nfapi::AutoUnlock.0
mov dword [ebp - 0x3c], 0x5646a4
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
push dword [edi + 0x14]
mov ecx, dword [0x564588]
lea eax, [edi + 0x18]
push eax
push dword [edi + 0x10]
mov byte [ebp - 4], 6
mov edx, dword [ecx]
push dword [edi + 0xc]
call dword [edx + 0x18]
mov dword [ebp - 0x40], vtable.nfapi::AutoUnlock.0
push 0x5646a4
mov byte [ebp - 4], 0
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
push 0
push edi
call fcn.004eb2f0
mov edx, dword [ebp - 0x28]
add esp, 8
test edx, edx
je 0x4e7400
cmp dword [ebx], ebx
jne 0x4e7321
mov ebx, dword [ebp - 0x38]
mov eax, dword [ebx + 0x10]
mov edi, dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
shr eax, 4
test al, 1
je 0x4e745c
test byte [esi + 0x93], 2
jne 0x4e745c
lea eax, [esi + 0x2c]
cmp dword [eax], eax
jne 0x4e745c
push 0x5646a4
mov dword [ebp - 0x30], vtable.nfapi::AutoUnlock.0
mov dword [ebp - 0x2c], 0x5646a4
call edi
mov ecx, dword [0x564588]
push dword [ebx + 0xc]
mov byte [ebp - 4], 7
push dword [ebx + 8]
mov eax, dword [ecx]
call dword [eax + 0x1c]
push 0x5646a4
mov byte [ebp - 4], 0
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov eax, dword [ebx + 0x10]
shr eax, 5
test al, 1
je 0x4e74af
test byte [esi + 0x93], 2
jne 0x4e74af
lea eax, [esi + 0x38]
cmp dword [eax], eax
jne 0x4e74af
push 0x5646a4
mov dword [ebp - 0x30], vtable.nfapi::AutoUnlock.0
mov dword [ebp - 0x2c], 0x5646a4
call edi
mov ecx, dword [0x564588]
push dword [ebx + 0xc]
mov byte [ebp - 4], 8
push dword [ebx + 8]
mov eax, dword [ecx]
call dword [eax + 0x20]
push 0x5646a4
mov byte [ebp - 4], 0
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
cmp dword [esi + 0x40], 0x40000
ja 0x4e74e2
cmp dword [esi + 0x34], 0x40000
ja 0x4e74e2
cmp dword [esi + 0x28], 0x40000
ja 0x4e74e2
cmp dword [esi + 0x1c], 0x40000
ja 0x4e74e2
push dword [esi + 0x8f]
push esi
call fcn.004e9e70
add esp, 8
mov eax, dword [ebx + 0x10]
shr eax, 1
test al, 1
je 0x4e754b
mov eax, dword [esi + 0x93]
test al, 0x20
jne 0x4e754b
or eax, 0x20
mov dword [ebp - 0x30], vtable.nfapi::AutoUnlock.0
push 0x5646a4
mov dword [esi + 0x93], eax
mov dword [ebp - 0x2c], 0x5646a4
call edi
mov ecx, dword [0x564588]
lea eax, [esi + 0x48]
push eax
push dword [ebx + 0xc]
mov byte [ebp - 4], 9
mov edx, dword [ecx]
push dword [ebx + 8]
call dword [edx + 0x10]
push 0x5646a4
mov byte [ebp - 4], 0
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
push 1
push dword [ebx + 0xc]
push dword [ebx + 8]
call fcn.004e9820
add esp, 0xc
push 0x5646a4
call edi
jmp 0x4e79ca
mov edi, dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
call edi
push dword [ebx + 0xc]
mov dword [ebp - 4], 0xa
push dword [ebx + 8]
push dword [0x5646a0]
call fcn.004eb120
mov ecx, dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
add esp, 0xc
test eax, eax
je 0x4e79c3
lea esi, [eax - 8]
mov eax, dword [ebx + 0x10]
shr eax, 8
mov dword [ebp - 0x28], esi
test al, 1
je 0x4e75d7
push 0x5646a4
mov dword [ebp - 0x30], vtable.nfapi::AutoUnlock.0
mov dword [ebp - 0x2c], 0x5646a4
call ecx
mov ecx, dword [0x564588]
lea eax, [esi + 0x44]
push eax
push dword [ebx + 0xc]
mov byte [ebp - 4], 0xb
mov edx, dword [ecx]
push dword [ebx + 8]
call dword [edx + 0x24]
push 0x5646a4
mov byte [ebp - 4], 0xa
call edi
mov ecx, dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov eax, dword [ebx + 0x10]
shr eax, 0x14
test al, 1
je 0x4e76a1
push 0x5646a4
mov dword [ebp - 0x30], vtable.nfapi::AutoUnlock.0
mov dword [ebp - 0x2c], 0x5646a4
call ecx
mov ecx, dword [0x564588]
lea edx, [esi + 0x66]
push edx
push dword [ebx + 0xc]
mov byte [ebp - 4], 0xc
mov eax, dword [ecx]
push dword [ebx + 8]
call dword [eax + 0x28]
push 0x5646a4
mov byte [ebp - 4], 0xa
call edi
test byte [esi + 0x66], 0x40
jne 0x4e79bd
push 0
push 0x52
call fcn.004eb240
mov edi, eax
add esp, 8
test edi, edi
je 0x4e79bd
mov ecx, dword [ebx + 8]
mov dword [edi + 4], ecx
mov ecx, dword [ebx + 0xc]
mov dword [edi + 8], ecx
mov dword [edi], 0x14
mov dword [edi + 0xc], 0x42
movdqu xmm0, xmmword [esi + 0x66]
push edi
movdqu xmmword [edi + 0x10], xmm0
movdqu xmm0, xmmword [esi + 0x76]
movdqu xmmword [edi + 0x20], xmm0
movdqu xmm0, xmmword [esi + 0x86]
movdqu xmmword [edi + 0x30], xmm0
movdqu xmm0, xmmword [esi + 0x96]
movdqu xmmword [edi + 0x40], xmm0
mov ax, word [esi + 0xa6]
mov word [edi + 0x50], ax
call fcn.004e9670
push 0
push edi
call fcn.004eb2f0
add esp, 0xc
mov eax, dword [ebx + 0x10]
shr eax, 0xa
test al, 1
je 0x4e777a
mov edi, dword [esi + 0x1c]
lea eax, [esi + 0x14]
mov dword [ebp - 0x2c], eax
cmp dword [eax], eax
je 0x4e777a
mov dword [ebp - 0x44], 0x5646a4
mov dword [ebp - 0x48], vtable.nfapi::AutoUnlock.0
mov edi, edi
mov edx, dword [eax]
mov dword [ebp - 0x3c], edx
mov eax, dword [edx + 4]
mov ecx, dword [edx]
mov dword [eax], ecx
mov dword [ecx + 4], eax
mov eax, dword [esi + 0x1c]
mov ecx, dword [edx + 0x14]
cmp eax, ecx
jb 0x4e76f0
sub eax, ecx
mov dword [esi + 0x1c], eax
jmp 0x4e76f7
mov dword [esi + 0x1c], 0
mov ecx, dword [edx + 0x14]
cmp edi, ecx
jb 0x4e7705
sub edi, ecx
mov dword [ebp - 0x34], edi
jmp 0x4e770c
mov dword [ebp - 0x34], 0
mov edi, dword [edx + 0x38]
lea ebx, [edx + 0x34]
add edi, 0x3c
lea esi, [edx + 0x18]
add edi, edx
sub ecx, edi
push 0x5646a4
add esi, ecx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov ecx, dword [0x564588]
push ebx
push esi
mov esi, dword [ebp - 0x3c]
mov eax, dword [ecx]
push edi
mov byte [ebp - 4], 0xd
lea edx, [esi + 0x18]
push edx
push dword [esi + 0x10]
push dword [esi + 0xc]
call dword [eax + 0x30]
push 0
push esi
call fcn.004eb2f0
mov edi, dword [ebp - 0x34]
add esp, 8
mov byte [ebp - 4], 0xa
push 0x5646a4
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov esi, dword [ebp - 0x28]
test edi, edi
je 0x4e7777
mov eax, dword [ebp - 0x2c]
cmp dword [eax], eax
jne 0x4e76d0
mov ebx, dword [ebp - 0x38]
mov eax, dword [ebx + 0x10]
shr eax, 0xb
test al, 1
je 0x4e7855
mov edi, dword [esi + 0x28]
lea eax, [esi + 0x20]
mov dword [ebp - 0x3c], eax
cmp dword [eax], eax
je 0x4e7855
mov dword [ebp - 0x44], 0x5646a4
mov dword [ebp - 0x48], vtable.nfapi::AutoUnlock.0
mov edx, dword [eax]
mov dword [ebp - 0x2c], edx
mov eax, dword [edx + 4]
mov ecx, dword [edx]
mov dword [eax], ecx
mov dword [ecx + 4], eax
mov eax, dword [esi + 0x28]
mov ecx, dword [edx + 0x14]
cmp eax, ecx
jb 0x4e77c7
sub eax, ecx
mov dword [esi + 0x28], eax
jmp 0x4e77ce
mov dword [esi + 0x28], 0
mov ecx, dword [edx + 0x14]
cmp edi, ecx
jb 0x4e77dc
sub edi, ecx
mov dword [ebp - 0x34], edi
jmp 0x4e77e3
mov dword [ebp - 0x34], 0
mov edi, dword [edx + 0x38]
lea ebx, [edx + 0x34]
add edi, 0x3c
lea esi, [edx + 0x18]
add edi, edx
sub ecx, edi
push 0x5646a4
add esi, ecx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov ecx, dword [0x564588]
push ebx
push esi
mov esi, dword [ebp - 0x2c]
mov eax, dword [ecx]
push edi
mov byte [ebp - 4], 0xe
lea edx, [esi + 0x18]
push edx
push dword [esi + 0x10]
push dword [esi + 0xc]
call dword [eax + 0x34]
push 0
push esi
call fcn.004eb2f0
mov edi, dword [ebp - 0x34]
add esp, 8
mov byte [ebp - 4], 0xa
push 0x5646a4
test edi, edi
je 0x4e79ad
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov eax, dword [ebp - 0x3c]
mov esi, dword [ebp - 0x28]
cmp dword [eax], eax
jne 0x4e77a7
mov ebx, dword [ebp - 0x38]
mov edi, dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov eax, dword [ebx + 0x10]
mov esi, dword [ebp - 0x28]
shr eax, 0xc
test al, 1
je 0x4e78a8
lea eax, [esi + 0x2c]
cmp dword [eax], eax
jne 0x4e78a8
push 0x5646a4
mov dword [ebp - 0x48], vtable.nfapi::AutoUnlock.0
mov dword [ebp - 0x44], 0x5646a4
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov ecx, dword [0x564588]
push dword [ebx + 0xc]
mov byte [ebp - 4], 0xf
push dword [ebx + 8]
mov eax, dword [ecx]
call dword [eax + 0x38]
push 0x5646a4
mov byte [ebp - 4], 0xa
call edi
mov eax, dword [ebx + 0x10]
shr eax, 0xd
test al, 1
je 0x4e78f2
lea eax, [esi + 0x38]
cmp dword [eax], eax
jne 0x4e78f2
push 0x5646a4
mov dword [ebp - 0x48], vtable.nfapi::AutoUnlock.0
mov dword [ebp - 0x44], 0x5646a4
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov ecx, dword [0x564588]
push dword [ebx + 0xc]
mov byte [ebp - 4], 0x10
push dword [ebx + 8]
mov eax, dword [ecx]
call dword [eax + 0x3c]
push 0x5646a4
mov byte [ebp - 4], 0xa
call edi
cmp dword [esi + 0x40], 0x40000
ja 0x4e7925
cmp dword [esi + 0x34], 0x40000
ja 0x4e7925
cmp dword [esi + 0x28], 0x40000
ja 0x4e7925
cmp dword [esi + 0x1c], 0x40000
ja 0x4e7925
push dword [esi + 0xac]
push esi
call fcn.004ea270
add esp, 8
mov eax, dword [ebx + 0x10]
shr eax, 9
test al, 1
je 0x4e79a0
push 0x5646a4
mov dword [ebp - 0x48], vtable.nfapi::AutoUnlock.0
mov dword [ebp - 0x44], 0x5646a4
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov ecx, dword [0x564588]
lea eax, [esi + 0x44]
push eax
push dword [ebx + 0xc]
mov byte [ebp - 4], 0x11
mov edx, dword [ecx]
push dword [ebx + 8]
call dword [edx + 0x2c]
push 0x5646a4
mov byte [ebp - 4], 0xa
call edi
mov eax, dword [ebx + 8]
mov ecx, 0x564738
mov dword [ebp - 0x20], eax
mov eax, dword [ebx + 0xc]
mov dword [ebp - 0x1c], eax
lea eax, [ebp - 0x24]
push eax
mov dword [ebp - 0x24], 9
mov dword [ebp - 0x18], 0
call fcn.004ea520
push dword [0x564778]
call dword [sym.imp.KERNEL32.dll_SetEvent]
push 0x5646a4
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
jmp 0x4e79ca
mov edi, dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
call edi
mov ebx, dword [ebp - 0x38]
jmp 0x4e785b
mov ecx, dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
push 0x5646a4
call ecx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004ebd2c
mov esp, ebp
pop ebp
ret