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

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x53f72c
push eax
mov dword fs:[0], esp
sub esp, 0x548
push ebx
push esi
push edi
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
xor ebx, ebx
mov dword [0x593050], ebx
call edi
mov esi, dword [esp + 0x564]
mov dword [0x593058], eax
cmp esi, ebx
je 0x496fa0
cmp word [esi], bx
je 0x496fa0
mov eax, dword [esp + 0x568]
cmp eax, ebx
je 0x496fa0
cmp word [eax], bx
je 0x496fa0
cmp dword [0x59305c], ebx
jne 0x496254
mov dword [0x593050], 2
mov dword [0x593054], 0xc4e
jmp 0x496fb4
mov eax, dword [0x54a4b4]
push ebp
mov dword [esp + 0x30], 1
mov dword [esp + 0x50], ebx
mov dword [esp + 0x7c], ebx
mov dword [esp + 0x2c], eax
or eax, 0xffffffff
mov ecx, 9
mov dword [esp + 0x18], eax
mov dword [esp + 0x40], eax
xor eax, eax
lea edi, [esp + 0x16c]
mov dword [esp + 0x168], ebx
mov dword [esp + 0x560], ebx
rep stosd dword es:[edi], eax
lea ecx, [esp + 0x8c]
mov dword [esp + 0x38], ebx
push ecx
push 0x60
push 1
push 5
push 0x80
push 0x120089
push esi
mov dword [esp + 0x90], ebx
mov dword [esp + 0xa8], ebx
call fcn.004bb100
mov ebp, eax
add esp, 0x1c
cmp ebp, 0xffffffff
mov dword [esp + 0x24], ebp
jne 0x49630f
cmp dword [esp + 0x8c], 0xc0000034
je 0x496f1f
push ebx
push 0x60
push 1
push 7
push 0x80
push 0x120089
push esi
call fcn.004bb100
mov ebp, eax
add esp, 0x1c
cmp ebp, 0xffffffff
mov dword [esp + 0x24], ebp
je 0x496c80
lea edx, [esp + 0x168]
push 0x28
push edx
push ebp
call fcn.004ba310
add esp, 0xc
test eax, eax
je 0x496ca4
mov ecx, 0xf
xor eax, eax
lea edi, [esp + 0xd9]
mov byte [esp + 0xd8], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [esp + 0xd8]
push eax
push ebp
call fcn.0049acf0
add esp, 8
test eax, eax
je 0x496cc8
lea ecx, [esp + 0xd8]
test ecx, ecx
je 0x496cec
push 0x10
lea edx, [esp + 0xdc]
push 0x575608
push edx
call fcn.0042ecc0
add esp, 0xc
test eax, eax
jne 0x496cec
test byte [esp + 0x10a], 1
je 0x496cec
mov edx, dword [esp + 0xf8]
lea eax, [esp + 0x28]
push eax
lea ecx, [esp + 0x40]
push ebx
push ecx
push ebx
push edx
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x50], ebx
call fcn.004909f0
mov eax, dword [esp + 0x3c]
add esp, 0x14
cmp eax, ebx
jne 0x496d10
mov ecx, 0xf
xor eax, eax
lea edi, [esp + 0x191]
mov byte [esp + 0x190], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov ecx, 0x13
xor eax, eax
lea edi, [esp + 0x11c]
mov dword [esp + 0x118], ebx
rep stosd dword es:[edi], eax
mov ecx, 0xd
lea edi, [esp + 0xa4]
mov dword [esp + 0xa0], ebx
mov dword [esp + 0x78], ebx
rep stosd dword es:[edi], eax
lea ecx, [esp + 0x14]
call fcn.0051a5b0
lea eax, [esp + 0x118]
lea ecx, [esp + 0xd8]
push eax
push ecx
push ebp
mov byte [esp + 0x56c], 1
call fcn.0049af60
add esp, 0xc
test eax, eax
je 0x496d34
mov ecx, 0xe1
xor eax, eax
lea edi, [esp + 0x1d1]
mov byte [esp + 0x1d0], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea edx, [esp + 0x1d0]
push edx
push ebp
stosb byte es:[edi], al
call fcn.00497320
add esp, 8
test eax, eax
je 0x496d4d
lea eax, [esp + 0xa0]
lea ecx, [esp + 0x118]
push eax
lea edx, [esp + 0xdc]
push ecx
push edx
push ebp
call fcn.0049b1e0
add esp, 0x10
test eax, eax
je 0x496d66
cmp word [esp + 0xaa], bx
jne 0x496d7f
lea ecx, [esp + 0x20]
call fcn.0051a5b0
lea eax, [esp + 0x60]
lea ecx, [esp + 0x6c]
push eax
lea edx, [esp + 0x24]
push ecx
lea eax, [esp + 0x120]
push edx
lea ecx, [esp + 0xe4]
push eax
push ecx
push ebp
mov byte [esp + 0x578], 2
mov dword [esp + 0x84], ebx
mov dword [esp + 0x78], ebx
call fcn.0049b430
add esp, 0x18
test eax, eax
je 0x496d98
mov edx, dword [esp + 0x6c]
xor ecx, ecx
mov si, word [edx + 0xc]
cmp si, bx
jbe 0x49653f
mov edx, dword [esp + 0x60]
mov eax, ecx
and eax, 0xffff
lea eax, [eax + eax*4]
test byte [edx + eax*8 + 8], 1
lea eax, [edx + eax*8]
je 0x496539
mov eax, dword [eax]
cmp eax, 1
jb 0x496dca
cmp eax, 4
ja 0x496dca
inc ecx
cmp cx, si
jb 0x496511
lea ecx, [esp + 0x78]
lea edx, [esp + 0x190]
push ecx
push 0x40
lea eax, [esp + 0x60]
push edx
lea ecx, [esp + 0x124]
push eax
push ecx
mov dword [esp + 0x6c], ebx
call fcn.004a5f60
add esp, 0x14
test eax, eax
je 0x496de0
mov edx, dword [esp + 0x58]
push edx
call fcn.004bded0
add esp, 4
cmp eax, ebx
mov dword [esp + 0x84], eax
je 0x496df6
lea ecx, [esp + 0x20]
mov byte [esp + 0x560], 1
call fcn.0051a710
mov edi, dword [esp + 0x56c]
push ebx
push edi
call fcn.004ba5d0
push ebx
push 0x60
push 3
push 1
push 0x80
push 0x120116
push edi
mov esi, eax
call fcn.004bb100
add esp, 0x24
cmp eax, 0xffffffff
mov dword [esp + 0x18], eax
jne 0x4965ff
push 1
push ebx
push edi
call fcn.004ba390
push ebx
push 0x60
push 1
push 7
push 0x80
push 0x120116
push edi
call fcn.004bb100
add esp, 0x28
cmp eax, 0xffffffff
mov dword [esp + 0x18], eax
je 0x496e0c
mov edi, dword [esp + 0x18]
xor eax, eax
cmp esi, ebx
mov dword [esp + 0x4c], edi
sete al
cmp esi, ebx
mov dword [esp + 0x50], eax
je 0x496670
mov ecx, dword [0x593590]
mov eax, dword [esp + 0x56c]
lea edx, [esp + 0x2c]
push ecx
push edx
push 0x5752e4
push eax
call fcn.004bac20
add esp, 0x10
test eax, eax
je 0x496670
mov ecx, dword [esp + 0x2c]
push ebx
push 0x60
push 2
push 7
push 0x80
push 0x12019f
push ecx
call fcn.004b9f10
add esp, 0x1c
cmp eax, 0xffffffff
mov dword [esp + 0x40], eax
je 0x496670
mov edi, eax
mov dword [esp + 0x7c], 1
mov dword [esp + 0x4c], edi
mov eax, dword [esp + 0xb4]
mov edx, dword [esp + 0xb0]
push eax
push edx
push edi
mov dword [esp + 0x34], ebx
mov dword [esp + 0x1c], ebx
call fcn.004bc080
add esp, 0xc
test eax, eax
je 0x496e22
cmp edi, dword [esp + 0x18]
jne 0x4966a7
mov dword [esp + 0x50], 1
mov eax, dword [esp + 0x13c]
mov ebx, dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 0
push 0
push eax
push ebp
call ebx
push 0
push 0
push 0
push edi
call ebx
mov eax, dword [esp + 0xc8]
test eax, eax
jne 0x4966dc
mov esi, 1
xor ebx, ebx
jmp 0x496aee
mov edi, dword [esp + 0xcc]
cmp eax, 1
jne 0x4966ef
mov edi, dword [esp + 0xd0]
mov ecx, dword [esp + 0x84]
push edi
mov edx, dword [ecx]
call dword [edx + 0xc]
mov esi, dword [0x575604]
mov ecx, eax
mov eax, esi
xor edx, edx
div edi
mov dword [esp + 0x90], ecx
mov dword [esp + 0x3c], esi
mov ebp, eax
mov eax, dword [esp + 0xc8]
imul ebp, ecx
cmp eax, 1
mov dword [esp + 0x64], ebp
je 0x496734
mov eax, esi
xor edx, edx
div edi
test edx, edx
je 0x496740
mov esi, edi
mov ebp, ecx
mov dword [esp + 0x3c], esi
mov dword [esp + 0x64], ebp
push esi
call fcn.00520a0a
add esp, 4
mov dword [esp + 0x34], eax
test eax, eax
je 0x496e57
push ebp
call fcn.00520a0a
add esp, 4
mov dword [esp + 0x44], eax
test eax, eax
je 0x496e6d
mov eax, dword [esp + 0x13c]
mov ecx, dword [esp + 0x24]
push 0
push 0
push eax
push ecx
call ebx
mov eax, esi
xor edx, edx
xor ebx, ebx
div edi
mov dword [esp + 0x54], ebx
mov dword [esp + 0x48], ebx
mov dword [esp + 0x9c], eax
mov edi, dword [esp + 0x34]
mov ecx, esi
mov edx, ecx
xor eax, eax
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
mov edi, dword [esp + 0x44]
mov ecx, ebp
mov edx, ecx
xor eax, eax
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
mov edi, dword [esp + 0x9c]
mov eax, dword [esp + 0xc8]
lea ecx, [edi + ebx]
cmp ecx, eax
jb 0x4967f5
mov edi, eax
mov eax, dword [esp + 0xd0]
sub edi, ebx
mov dword [esp + 0x28], 1
lea esi, [edi - 1]
imul esi, dword [esp + 0xcc]
add esi, eax
mov eax, dword [esp + 0x34]
mov ecx, dword [esp + 0x24]
push 0
lea edx, [esp + 0x6c]
push 0
push edx
push esi
push eax
push ecx
mov dword [esp + 0x80], 0
call fcn.004ba790
add esp, 0x18
test eax, eax
je 0x496a5e
cmp esi, dword [esp + 0x68]
jne 0x496a74
mov ebx, dword [esp + 0x34]
mov ebp, dword [esp + 0x44]
mov dword [esp + 0x98], edi
xor edi, edi
mov dword [esp + 0x80], edi
mov eax, dword [esp + 0x48]
mov edx, dword [esp + 0xc8]
mov ecx, dword [esp + 0xcc]
inc eax
cmp eax, edx
mov dword [esp + 0x48], eax
mov dword [esp + 0x94], ecx
jne 0x496876
mov ecx, dword [esp + 0xd0]
mov dword [esp + 0x94], ecx
mov edx, dword [esp + 0xc4]
xor eax, eax
cmp eax, edx
mov dword [esp + 0x1c], edi
ja 0x496916
jb 0x49689c
mov edx, dword [esp + 0x54]
mov eax, dword [esp + 0xc0]
cmp edx, eax
jae 0x496916
lea eax, [esp + 0x70]
lea edx, [esp + 0x88]
push eax
mov eax, dword [esp + 0xac]
push edx
push ecx
push ebx
push eax
mov dword [esp + 0x9c], edi
mov dword [esp + 0x84], edi
call fcn.004aad10
add esp, 0x14
test eax, eax
je 0x496a32
lea eax, [esp + 0x1c]
mov ecx, dword [esp + 0x84]
push eax
mov eax, dword [esp + 0x94]
push eax
mov eax, dword [esp + 0x78]
push ebp
mov edx, dword [ecx]
push eax
mov eax, dword [esp + 0x98]
push eax
mov eax, dword [esp + 0x8c]
push eax
lea eax, [esp + 0x1a8]
push eax
call dword [edx + 0x14]
cmp eax, edi
je 0x496a48
mov ecx, dword [esp + 0x1c]
jmp 0x496975
mov ecx, dword [esp + 0xd4]
mov eax, dword [esp + 0x90]
cmp ecx, eax
mov dword [esp + 0x1c], ecx
jbe 0x496932
mov ecx, eax
mov dword [esp + 0x1c], ecx
mov eax, dword [esp + 0xa8]
and eax, 0xffff
sub eax, edi
je 0x49695d
dec eax
je 0x49694d
dec eax
jne 0x496975
lea esi, [ebx + 8]
jmp 0x49695f
mov eax, ecx
lea esi, [ebx + 4]
mov edi, ebp
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
jmp 0x49696a
mov esi, ebx
mov edx, ecx
mov edi, ebp
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x1c]
xor edi, edi
mov eax, dword [esp + 0xc8]
mov edx, dword [esp + 0x48]
cmp edx, eax
jne 0x4969b1
mov eax, dword [esp + 0xb4]
mov ecx, dword [esp + 0xb0]
cmp eax, edi
ja 0x49699e
cmp ecx, 0x1000
jbe 0x4969b1
and ecx, 0xfff
xor eax, eax
mov edx, ecx
or edx, eax
jne 0x4969b1
mov ecx, 0x1000
mov esi, dword [esp + 0x80]
mov eax, dword [esp + 0x98]
add esi, ecx
dec eax
mov dword [esp + 0x80], esi
mov dword [esp + 0x98], eax
je 0x4969e2
mov edx, dword [esp + 0x94]
add ebx, edx
add ebp, ecx
jmp 0x496846
mov ebx, dword [esp + 0x54]
mov ecx, dword [esp + 0x44]
mov edx, dword [esp + 0x4c]
lea eax, [esp + 0x5c]
push edi
push eax
push esi
add ebx, esi
push ecx
push edx
mov dword [esp + 0x68], ebx
mov dword [esp + 0x70], edi
call fcn.004ba890
add esp, 0x14
test eax, eax
je 0x496a8a
cmp dword [esp + 0x5c], esi
jb 0x496aa0
cmp dword [esp + 0x28], edi
jne 0x496ac7
mov ebp, dword [esp + 0x64]
mov ebx, dword [esp + 0x48]
mov esi, dword [esp + 0x3c]
jmp 0x496794
mov dword [0x593050], 0x1c
mov dword [0x593054], 0xda3
jmp 0x496ab4
mov dword [0x593050], 0x12
mov dword [0x593054], 0xdac
jmp 0x496ab4
mov dword [0x593050], 0xd
mov dword [0x593054], 0xd80
jmp 0x496ab4
mov dword [0x593050], 0xd
mov dword [0x593054], 0xd88
jmp 0x496ab4
mov dword [0x593050], 0xe
mov dword [0x593054], 0xdd6
jmp 0x496ab4
mov dword [0x593050], 0xe
mov dword [0x593054], 0xdde
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [0x593058], eax
mov dword [esp + 0x10], 1
mov eax, dword [esp + 0x34]
push eax
call fcn.00520a33
mov ecx, dword [esp + 0x48]
push ecx
call fcn.00520a33
mov edi, dword [esp + 0x54]
mov esi, dword [esp + 0x30]
mov ebx, dword [esp + 0x18]
mov ebp, dword [esp + 0x2c]
add esp, 8
push edi
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test esi, esi
je 0x496ee0
test ebx, ebx
jne 0x496ee0
mov bl, byte [esp + 0x574]
test bl, 4
je 0x496b24
lea edx, [esp + 0x74]
lea eax, [esp + 0x38]
push edx
push eax
push ebp
call fcn.004bb8b0
add esp, 0xc
cmp ebp, 0xffffffff
je 0x496b33
push ebp
call dword [0x593fb8]
or ebp, 0xffffffff
test bl, 2
je 0x496b4b
lea ecx, [esp + 0x168]
push 0x28
push ecx
push edi
call fcn.004ba350
add esp, 0xc
mov esi, dword [esp + 0x40]
cmp edi, esi
jne 0x496c73
mov eax, dword [esp + 0x18]
or edi, 0xffffffff
cmp eax, edi
je 0x496b6d
push eax
call dword [0x593fb8]
mov dword [esp + 0x18], edi
cmp esi, edi
je 0x496b7c
push esi
call dword [0x593fb8]
mov dword [esp + 0x40], edi
mov edx, dword [0x54a4b4]
mov dword [esp + 0x10], edx
mov eax, dword [0x593590]
mov esi, dword [esp + 0x56c]
lea ecx, [esp + 0x10]
push eax
push ecx
push 0x5751c4
push esi
mov byte [esp + 0x570], 3
call fcn.004bac20
add esp, 0x10
test eax, eax
je 0x496eb0
mov edx, dword [esp + 0x10]
push edx
push esi
call fcn.004ba950
add esp, 8
test eax, eax
je 0x496c5a
mov eax, dword [esp + 0x2c]
push esi
push eax
call fcn.004ba950
add esp, 8
test eax, eax
je 0x496bfa
mov ecx, dword [esp + 0x10]
push 1
push ecx
mov dword [esp + 0x38], 0
call fcn.004ba690
add esp, 8
jmp 0x496ecf
mov dword [0x593050], 0x27
mov dword [0x593054], 0xe2f
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, dword [esp + 0x10]
push esi
push edx
mov dword [0x593058], eax
call fcn.004ba950
add esp, 8
test eax, eax
jne 0x496ecf
mov eax, dword [esp + 0x570]
mov dword [esp + 0x30], edi
test eax, eax
je 0x496ecf
mov ecx, dword [esp + 0x10]
push 0x103
push ecx
push eax
call fcn.00422de4
add esp, 0xc
jmp 0x496ecf
mov dword [0x593050], 0x28
mov dword [0x593054], 0xe3d
jmp 0x496ec4
mov dword [esp + 0x30], 0
jmp 0x496ee0
mov dword [0x593050], 3
mov dword [0x593054], 0xc7d
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [0x593058], eax
jmp 0x496f1f
mov dword [0x593050], 5
mov dword [0x593054], 0xc85
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [0x593058], eax
jmp 0x496ef3
mov dword [0x593050], 0xf
mov dword [0x593054], 0xc8c
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [0x593058], eax
jmp 0x496ef3
mov dword [0x593050], 0x22
mov dword [0x593054], 0xc93
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [0x593058], eax
jmp 0x496ef3
mov dword [0x593050], 0x31
mov dword [0x593054], 0xc9a
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [0x593058], eax
jmp 0x496ef3
mov dword [0x593050], 0x14
mov dword [0x593054], 0xcaa
jmp 0x496e36
mov dword [0x593050], 0x1f
mov dword [0x593054], 0xcb2
jmp 0x496e36
mov dword [0x593050], 0x14
mov dword [0x593054], 0xcb8
jmp 0x496e36
mov dword [0x593050], 1
mov dword [0x593054], 0xcbf
jmp 0x496e36
mov dword [0x593050], 0x14
mov dword [0x593054], 0xcc9
call dword [sym.imp.KERNEL32.dll_GetLastError]
lea ecx, [esp + 0x20]
mov dword [0x593058], eax
mov byte [esp + 0x560], 1
call fcn.0051a710
jmp 0x496e41
mov dword [0x593050], 0x32
mov dword [0x593054], 0xccf
jmp 0x496dac
mov dword [0x593050], 0xb
mov dword [0x593054], 0xcdf
jmp 0x496dac
mov dword [0x593050], 0xc
mov dword [0x593054], 0xce8
jmp 0x496dac
mov dword [0x593050], 4
mov dword [0x593054], 0xd0e
jmp 0x496e36
mov dword [0x593050], 0x25
mov dword [0x593054], 0xd34
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [0x593058], eax
lea ecx, [esp + 0x14]
mov byte [esp + 0x560], 0
call fcn.0051a710
jmp 0x496ef3
mov dword [0x593050], 0x21
mov dword [0x593054], 0xd5a
jmp 0x496e8e
mov edx, dword [esp + 0x34]
push edx
call fcn.00520a33
add esp, 4
mov dword [0x593050], 0x21
mov dword [0x593054], 0xd64
call dword [sym.imp.KERNEL32.dll_GetLastError]
lea ecx, [esp + 0x14]
mov dword [0x593058], eax
mov byte [esp + 0x560], 0
call fcn.0051a710
mov ebp, dword [esp + 0x24]
jmp 0x496ef1
mov dword [0x593050], 0x24
mov dword [0x593054], 0xe1e
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [0x593058], eax
lea ecx, [esp + 0x10]
mov byte [esp + 0x560], 1
call fcn.0043bde0
lea ecx, [esp + 0x14]
mov byte [esp + 0x560], 0
call fcn.0051a710
xor ebx, ebx
cmp ebp, 0xffffffff
je 0x496eff
push ebp
call dword [0x593fb8]
mov eax, dword [esp + 0x18]
cmp eax, 0xffffffff
je 0x496f0f
push eax
call dword [0x593fb8]
mov eax, dword [esp + 0x40]
cmp eax, 0xffffffff
je 0x496f1f
push eax
call dword [0x593fb8]
mov eax, dword [esp + 0x38]
mov esi, dword [esp + 0x30]
cmp eax, ebx
pop ebp
je 0x496f57
cmp esi, ebx
jne 0x496f4a
mov ecx, dword [esp + 0x70]
mov edx, dword [esp + 0x568]
push ecx
push eax
push edx
call fcn.004bab90
mov eax, dword [esp + 0x40]
add esp, 0xc
push eax
call fcn.00520a33
add esp, 4
mov dword [esp + 0x34], ebx
cmp esi, ebx
je 0x496f88
cmp dword [esp + 0x78], ebx
je 0x496f70
mov eax, dword [esp + 0x28]
push 1
push eax
call fcn.004ba690
add esp, 8
cmp dword [esp + 0x4c], ebx
je 0x496f88
mov ecx, dword [esp + 0x568]
push 1
push ecx
call fcn.004ba690
add esp, 8
lea ecx, [esp + 0x28]
mov dword [esp + 0x55c], 0xffffffff
call fcn.0043bde0
mov eax, esi
jmp 0x496fc0
mov dword [0x593050], 1
mov dword [0x593054], 0xc48
call edi
mov dword [0x593058], eax
mov eax, 1
mov ecx, dword [esp + 0x554]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
add esp, 0x554
ret