Function at 0x456798
Capabilities:
Link many functions at runtime

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x34
push ebx
xor ebx, ebx
test byte [ebp + 0x10], 0x80
push esi
mov esi, eax
mov dword [ebp - 0x24], ebx
mov byte [ebp - 2], bl
mov dword [ebp - 8], ebx
mov dword [ebp - 0x34], 0xc
mov dword [ebp - 0x30], ebx
je 0x45661d
mov dword [ebp - 0x2c], ebx
mov byte [ebp - 1], 0x10
jmp 0x456627
mov dword [ebp - 0x2c], 1
mov byte [ebp - 1], bl
lea eax, [ebp - 0x24]
push eax
call fcn.00457bc7
pop ecx
test eax, eax
jne 0x456d17
mov eax, 0x8000
test dword [ebp + 0x10], eax
jne 0x456655
test dword [ebp + 0x10], 0x74000
jne 0x456651
cmp dword [ebp - 0x24], eax
je 0x456655
or byte [ebp - 1], 0x80
mov eax, dword [ebp + 0x10]
and eax, 3
sub eax, ebx
mov ecx, 0xc0000000
mov edx, 0x80000000
je 0x4566ac
dec eax
je 0x456694
dec eax
je 0x45668f
call fcn.0044e885
mov dword [eax], ebx
or dword [esi], 0xffffffff
call fcn.0044e872
push 0x16
pop esi
mov dword [eax], esi
call fcn.0044e820
mov eax, esi
jmp 0x45676d
mov dword [ebp - 0xc], ecx
jmp 0x4566af
test byte [ebp + 0x10], 8
je 0x4566a3
test dword [ebp + 0x10], 0x70000
jne 0x45668f
mov dword [ebp - 0xc], 0x40000000
jmp 0x4566af
mov dword [ebp - 0xc], edx
mov eax, dword [ebp + 0x14]
push 0x10
pop ecx
sub eax, ecx
je 0x4566f0
sub eax, ecx
je 0x4566e7
sub eax, ecx
je 0x4566de
sub eax, ecx
je 0x4566d5
sub eax, 0x40
jne 0x45666f
cmp dword [ebp - 0xc], edx
sete al
mov dword [ebp - 0x14], eax
jmp 0x4566f3
mov dword [ebp - 0x14], 3
jmp 0x4566f3
mov dword [ebp - 0x14], 2
jmp 0x4566f3
mov dword [ebp - 0x14], 1
jmp 0x4566f3
mov dword [ebp - 0x14], ebx
mov eax, dword [ebp + 0x10]
mov edx, 0x700
and eax, edx
mov ecx, 0x400
push edi
mov edi, 0x100
cmp eax, ecx
jg 0x45673f
je 0x456736
cmp eax, ebx
je 0x456736
cmp eax, edi
je 0x45672d
cmp eax, 0x200
je 0x456771
cmp eax, 0x300
jne 0x456751
mov dword [ebp - 0x18], 2
jmp 0x456781
mov dword [ebp - 0x18], 4
jmp 0x456781
mov dword [ebp - 0x18], 3
jmp 0x456781
cmp eax, 0x500
je 0x45677a
cmp eax, 0x600
je 0x456771
cmp eax, edx
je 0x45677a
call fcn.0044e885
mov dword [eax], ebx
or dword [esi], 0xffffffff
call fcn.0044e872
push 0x16
pop esi
mov dword [eax], esi
call fcn.0044e820
mov eax, esi
pop edi
pop esi
pop ebx
leave
ret
mov dword [ebp - 0x18], 5
jmp 0x456781
mov dword [ebp - 0x18], 1
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x10], 0x80
test edi, eax
je 0x4567a5
mov ecx, dword [0x5ebb2c]
not ecx
and ecx, dword [ebp + 0x18]
test cl, cl
js 0x4567a5
mov dword [ebp - 0x10], 1
test al, 0x40
je 0x4567bb
or dword [ebp - 0x10], 0x4000000
or dword [ebp - 0xc], 0x10000
or dword [ebp - 0x14], 4
test eax, 0x1000
je 0x4567c5
or dword [ebp - 0x10], edi
test al, 0x20
je 0x4567d2
or dword [ebp - 0x10], 0x8000000
jmp 0x4567dd
test al, 0x10
je 0x4567dd
or dword [ebp - 0x10], 0x10000000
call fcn.00456376
or ebx, 0xffffffff
mov dword [esi], eax
cmp eax, ebx
jne 0x45680c
call fcn.0044e885
and dword [eax], 0
mov dword [esi], ebx
call fcn.0044e872
mov dword [eax], 0x18
call fcn.0044e872
mov eax, dword [eax]
jmp 0x45676c
mov eax, dword [ebp + 8]
mov edi, dword [sym.imp.kernel32.dll_CreateFileW]
push 0
push dword [ebp - 0x10]
mov dword [eax], 1
push dword [ebp - 0x18]
lea eax, [ebp - 0x34]
push eax
push dword [ebp - 0x14]
push dword [ebp - 0xc]
push dword [ebp + 0xc]
call edi
mov dword [ebp - 0x20], eax
cmp eax, ebx
jne 0x4568a9
mov ecx, dword [ebp - 0xc]
mov eax, 0xc0000000
and ecx, eax
cmp ecx, eax
jne 0x456872
test byte [ebp + 0x10], 1
je 0x456872
and dword [ebp - 0xc], 0x7fffffff
push 0
push dword [ebp - 0x10]
lea eax, [ebp - 0x34]
push dword [ebp - 0x18]
push eax
push dword [ebp - 0x14]
push dword [ebp - 0xc]
push dword [ebp + 0xc]
call edi
mov dword [ebp - 0x20], eax
cmp eax, ebx
jne 0x4568a9
mov esi, dword [esi]
mov eax, esi
sar eax, 5
mov eax, dword [eax*4 + 0x5f0e80]
and esi, 0x1f
shl esi, 6
lea eax, [eax + esi + 4]
and byte [eax], 0xfe
call dword [sym.imp.kernel32.dll_GetLastError]
push eax
call fcn.0044e898
pop ecx
call fcn.0044e872
mov eax, dword [eax]
mov dword [ebp - 8], eax
jmp 0x456d0f
push dword [ebp - 0x20]
call dword [sym.imp.kernel32.dll_GetFileType]
test eax, eax
jne 0x4568fa
mov esi, dword [esi]
mov eax, esi
sar eax, 5
mov eax, dword [eax*4 + 0x5f0e80]
and esi, 0x1f
shl esi, 6
lea eax, [eax + esi + 4]
and byte [eax], 0xfe
call dword [sym.imp.kernel32.dll_GetLastError]
mov esi, eax
push esi
call fcn.0044e898
pop ecx
push dword [ebp - 0x20]
call dword [sym.imp.kernel32.dll_CloseHandle]
test esi, esi
jne 0x45689a
call fcn.0044e872
mov dword [eax], 0xd
jmp 0x45689a
cmp eax, 2
jne 0x456905
or byte [ebp - 1], 0x40
jmp 0x45690e
cmp eax, 3
jne 0x45690e
or byte [ebp - 1], 8
push dword [ebp - 0x20]
push dword [esi]
call fcn.00456140
mov eax, dword [esi]
mov edx, eax
and eax, 0x1f
sar edx, 5
mov edx, dword [edx*4 + 0x5f0e80]
pop ecx
shl eax, 6
pop ecx
mov cl, byte [ebp - 1]
or cl, 1
mov byte [edx + eax + 4], cl
mov eax, dword [esi]
mov edx, eax
and eax, 0x1f
sar edx, 5
mov edx, dword [edx*4 + 0x5f0e80]
shl eax, 6
lea eax, [edx + eax + 0x24]
and byte [eax], 0x80
mov byte [ebp - 3], cl
and byte [ebp - 3], 0x48
mov byte [ebp - 1], cl
jne 0x4569de
test cl, 0x80
je 0x456c10
test byte [ebp + 0x10], 2
je 0x4569de
push 2
push ebx
push dword [esi]
call fcn.0045389a
mov edi, eax
add esp, 0xc
cmp edi, ebx
jne 0x45699a
call fcn.0044e885
cmp dword [eax], 0x83
je 0x4569de
push dword [esi]
call fcn.0045352e
jmp 0x456899
and dword [ebp - 0x28], 0
push 1
lea eax, [ebp - 0x28]
push eax
push dword [esi]
call fcn.00457555
add esp, 0xc
test eax, eax
jne 0x4569cc
cmp word [ebp - 0x28], 0x1a
jne 0x4569cc
mov eax, edi
cdq
push edx
push eax
push dword [esi]
call fcn.0045739f
add esp, 0xc
cmp eax, ebx
je 0x45698e
push 0
push 0
push dword [esi]
call fcn.0045389a
add esp, 0xc
cmp eax, ebx
je 0x45698e
test byte [ebp - 1], 0x80
je 0x456c10
mov edi, 0x74000
mov ecx, 0x4000
test dword [ebp + 0x10], edi
jne 0x456a06
mov eax, dword [ebp - 0x24]
and eax, edi
jne 0x456a03
or dword [ebp + 0x10], ecx
jmp 0x456a06
or dword [ebp + 0x10], eax
mov eax, dword [ebp + 0x10]
and eax, edi
cmp eax, ecx
je 0x456a53
cmp eax, 0x10000
je 0x456a3f
cmp eax, 0x14000
je 0x456a3f
cmp eax, 0x20000
je 0x456a4d
cmp eax, 0x24000
je 0x456a4d
cmp eax, 0x40000
je 0x456a39
cmp eax, 0x44000
jne 0x456a57
mov byte [ebp - 2], 1
jmp 0x456a57
mov ecx, dword [ebp + 0x10]
mov eax, 0x301
and ecx, eax
cmp ecx, eax
jne 0x456a57
mov byte [ebp - 2], 2
jmp 0x456a57
mov byte [ebp - 2], 0
test dword [ebp + 0x10], 0x70000
je 0x456c10
xor edi, edi
test byte [ebp - 1], 0x40
mov dword [ebp - 0x1c], edi
jne 0x456c10
mov eax, dword [ebp - 0xc]
mov ecx, 0xc0000000
and eax, ecx
cmp eax, 0x40000000
je 0x456b38
cmp eax, 0x80000000
je 0x456b00
cmp eax, ecx
jne 0x456c10
mov eax, dword [ebp - 0x18]
cmp eax, edi
jbe 0x456c10
cmp eax, 2
jbe 0x456ab5
cmp eax, 4
jbe 0x456ad7
cmp eax, 5
jne 0x456c10
movsx eax, byte [ebp - 2]
xor edi, edi
dec eax
je 0x456be0
dec eax
jne 0x456c10
mov dword [ebp - 0x1c], 0xfeff
push 2
jmp 0x456be9
push 2
push edi
push edi
push dword [esi]
call fcn.00454d27
add esp, 0x10
or eax, edx
je 0x456ab5
push edi
push edi
push edi
push dword [esi]
call fcn.00454d27
and eax, edx
add esp, 0x10
cmp eax, ebx
je 0x45698e
push 3
lea eax, [ebp - 0x1c]
push eax
push dword [esi]
call fcn.00457555
add esp, 0xc
cmp eax, ebx
je 0x45698e
cmp eax, 2
je 0x456b87
cmp eax, 3
jne 0x456bd2
cmp dword [ebp - 0x1c], 0xbfbbef
jne 0x456b87
mov byte [ebp - 2], 1
jmp 0x456c10
mov eax, dword [ebp - 0x18]
cmp eax, edi
jbe 0x456c10
cmp eax, 2
jbe 0x456ab5
cmp eax, 4
ja 0x456aac
push 2
push edi
push edi
push dword [esi]
call fcn.00454d27
add esp, 0x10
or eax, edx
je 0x456ab5
push edi
push edi
push edi
push dword [esi]
call fcn.00454d27
add esp, 0x10
and eax, edx
cmp eax, ebx
jne 0x456c10
jmp 0x45698e
mov eax, dword [ebp - 0x1c]
and eax, 0xffff
cmp eax, 0xfffe
jne 0x456bb0
push dword [esi]
call fcn.0045352e
pop ecx
call fcn.0044e872
push 0x16
pop esi
mov dword [eax], esi
mov dword [ebp - 8], esi
jmp 0x456d0f
cmp eax, 0xfeff
jne 0x456bd2
push edi
push 2
push dword [esi]
call fcn.0045389a
add esp, 0xc
cmp eax, ebx
je 0x45698e
mov byte [ebp - 2], 2
jmp 0x456c10
push edi
push edi
push dword [esi]
call fcn.0045389a
add esp, 0xc
jmp 0x456b7a
mov dword [ebp - 0x1c], 0xbfbbef
push 3
pop ebx
mov eax, ebx
sub eax, edi
push eax
lea eax, [ebp + edi - 0x1c]
push eax
push dword [esi]
call fcn.004540e0
add esp, 0xc
cmp eax, 0xffffffff
je 0x45698e
add edi, eax
cmp ebx, edi
jg 0x456bea
or ebx, 0xffffffff
mov eax, dword [esi]
mov ecx, eax
sar ecx, 5
mov ecx, dword [ecx*4 + 0x5f0e80]
and eax, 0x1f
shl eax, 6
lea eax, [ecx + eax + 0x24]
mov cl, byte [eax]
xor cl, byte [ebp - 2]
and cl, 0x7f
xor byte [eax], cl
mov eax, dword [esi]
mov ecx, eax
sar ecx, 5
mov ecx, dword [ecx*4 + 0x5f0e80]
and eax, 0x1f
shl eax, 6
lea eax, [ecx + eax + 0x24]
mov ecx, dword [ebp + 0x10]
mov dl, byte [eax]
shr ecx, 0x10
shl cl, 7
and dl, 0x7f
or cl, dl
cmp byte [ebp - 3], 0
mov byte [eax], cl
jne 0x456c83
test byte [ebp + 0x10], 8
je 0x456c83
mov eax, dword [esi]
mov ecx, eax
and eax, 0x1f
sar ecx, 5
mov ecx, dword [ecx*4 + 0x5f0e80]
shl eax, 6
lea eax, [ecx + eax + 4]
or byte [eax], 0x20
mov ecx, dword [ebp - 0xc]
mov eax, 0xc0000000
and ecx, eax
cmp ecx, eax
jne 0x456d0f
test byte [ebp + 0x10], 1
je 0x456d0f
push dword [ebp - 0x20]
call dword [sym.imp.kernel32.dll_CloseHandle]
push 0
push dword [ebp - 0x10]
lea eax, [ebp - 0x34]
push 3
push eax
push dword [ebp - 0x14]
mov eax, dword [ebp - 0xc]
and eax, 0x7fffffff
push eax
push dword [ebp + 0xc]
call dword [sym.imp.kernel32.dll_CreateFileW]
cmp eax, ebx
jne 0x456cf8
call dword [sym.imp.kernel32.dll_GetLastError]
push eax
call fcn.0044e898
mov eax, dword [esi]
mov ecx, eax
and eax, 0x1f
sar ecx, 5
mov ecx, dword [ecx*4 + 0x5f0e80]
shl eax, 6
lea eax, [ecx + eax + 4]
and byte [eax], 0xfe
push dword [esi]
call fcn.004561c1
pop ecx
jmp 0x456899
mov esi, dword [esi]
mov ecx, esi
sar ecx, 5
mov ecx, dword [ecx*4 + 0x5f0e80]
and esi, 0x1f
shl esi, 6
mov dword [esi + ecx], eax
mov eax, dword [ebp - 8]
jmp 0x45676c
push ebx
push ebx
push ebx
push ebx
push ebx
call fcn.0044e7ce
int3