Function at 0x45e604
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x64
push ebx
push esi
mov esi, dword [ebp + 8]
xor ebx, ebx
mov bx, word [esi]
push edi
mov dword [ebp - 0x10], ecx
mov byte [ebp - 2], 0
mov byte [ebp - 1], 0
mov dword [ebp - 8], 0xffff0000
mov eax, ebx
call fcn.00431c5f
test al, al
mov edi, 0x4b0
je 0x45e640
and dword [ebp - 8], 0
jmp 0x45e756
push 4
push esi
push str._UNI
call fcn.00432c0f
add esp, 0xc
test al, al
je 0x45e65c
mov dword [ebp - 8], edi
jmp 0x45e756
push 8
push esi
push str._UNICODE
call fcn.00432c0f
add esp, 0xc
test al, al
jne 0x45e654
push 5
pop edi
push edi
push esi
push str._UNIB
call fcn.00432c0f
add esp, 0xc
test al, al
je 0x45e692
mov dword [ebp - 8], 0x4b1
jmp 0x45e756
push 9
push esi
push str._UNICODEB
call fcn.00432c0f
add esp, 0xc
test al, al
jne 0x45e686
push edi
push esi
push str._ANSI
call fcn.00432c0f
add esp, 0xc
test al, al
jne 0x45e637
push 4
push esi
push str._GBK
call fcn.00432c0f
add esp, 0xc
test al, al
je 0x45e6da
mov dword [ebp - 8], 0x3a8
jmp 0x45e756
push edi
push esi
push str._BIG5
call fcn.00432c0f
add esp, 0xc
test al, al
je 0x45e6f6
mov dword [ebp - 8], 0x3b6
jmp 0x45e756
push edi
push esi
push str._UTF8
call fcn.00432c0f
add esp, 0xc
test al, al
je 0x45e712
mov dword [ebp - 8], 0xfde9
jmp 0x45e756
push edi
push esi
push str._UTF7
call fcn.00432c0f
add esp, 0xc
test al, al
je 0x45e72e
mov dword [ebp - 8], 0xfde8
jmp 0x45e756
cmp bx, 0x2d
jne 0x45e756
xor eax, eax
add esi, 2
mov ax, word [esi]
push eax
call fcn.00410c71
add esp, 4
test al, al
je 0x45e756
push esi
mov dword [ebp + 8], esi
call fcn.00437c70
pop ecx
mov dword [ebp - 8], eax
lea eax, [ebp + 8]
push eax
call fcn.00404807
push 4
lea eax, [ebp + 8]
push eax
push str.fix
call fcn.00438eee
mov bl, al
add esp, 0x10
neg bl
sbb bl, bl
push 0x497994
lea ecx, [ebp - 0x28]
and ebx, 2
mov byte [ebp - 0x40], bl
call fcn.004419bc
push str.READLINE
lea ecx, [ebp - 0x14]
call fcn.004419bc
mov ecx, dword [ebp - 0x10]
xor eax, eax
push eax
mov dword [ebp - 0x48], eax
mov dword [ebp - 0x1c], eax
push 0x2c
lea eax, [ebp - 0x28]
push eax
xor edi, edi
lea eax, [ebp + 8]
inc edi
push eax
mov dword [ebp - 0x34], edi
mov dword [ebp - 0x18], edi
call fcn.0042d8a6
mov esi, dword [ebp - 0x28]
push esi
push 0x4a0574
mov dword [ebp + 8], eax
call fcn.00432c89
test al, al
pop ecx
pop ecx
je 0x45e84b
mov dword [ebp - 0x1c], edi
mov byte [ebp - 2], 1
and dword [ebp - 0x30], 0
lea ecx, [ebp - 0x38]
call fcn.0043717e
mov ecx, dword [ebp - 0x10]
push edi
push 0
lea eax, [ebp - 0x38]
push eax
push dword [ebp + 8]
call fcn.0043eb92
mov eax, dword [ebp - 0x38]
mov dword [ebp + 8], eax
cmp word [eax], 0x2c
jne 0x45e8ec
lea ecx, [ebp - 0x2c]
call fcn.0043717e
add dword [ebp + 8], 2
push 0x2c
lea eax, [ebp - 0x2c]
push eax
lea eax, [ebp + 8]
push eax
call fcn.00439b04
mov esi, dword [ebp - 0x2c]
push esi
push 0x4a0570
mov dword [ebp - 0x24], esi
call fcn.00432c89
add esp, 0x14
test al, al
je 0x45e884
mov byte [ebp - 1], 2
mov dword [ebp - 0x30], 0x4a056c
jmp 0x45e8e4
cmp word [esi], 0
je 0x45e7d6
push esi
push 0x498920
call fcn.00432c89
test al, al
pop ecx
pop ecx
jne 0x45e7d6
push esi
push 0x498128
call fcn.00432c89
test al, al
pop ecx
pop ecx
je 0x45e7da
mov byte [ebp - 2], 2
jmp 0x45e7da
push esi
push 0x4a0568
call fcn.00432c89
test al, al
pop ecx
pop ecx
je 0x45e89b
mov byte [ebp - 1], 3
jmp 0x45e8e4
push esi
push 0x49c2ac
call fcn.00432c89
test al, al
pop ecx
pop ecx
je 0x45e8b9
mov byte [ebp - 1], 1
mov dword [ebp - 0x30], 0x4a0564
jmp 0x45e8e4
lea eax, [ebp - 0x34]
push eax
lea eax, [ebp - 0x24]
push eax
call fcn.00439fac
mov eax, dword [ebp - 0x24]
cmp word [eax], 0x2b
pop ecx
pop ecx
jne 0x45e8e4
add dword [ebp - 0x24], 2
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x24]
push eax
call fcn.00439fac
pop ecx
pop ecx
lea ecx, [ebp - 0x2c]
call fcn.00431c4c
mov eax, dword [ebp + 8]
cmp word [eax], 0x2c
jne 0x45e90b
add dword [ebp + 8], 2
push 0x2c
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp + 8]
push eax
call fcn.00439b04
add esp, 0xc
mov ecx, dword [ebp - 0x10]
push 0
lea eax, [ebp - 0x14]
push eax
call fcn.00402c95
push 8
lea ecx, [ebp - 0xc]
call fcn.00437072
mov esi, dword [ebp - 0xc]
and word [esi], 0
cmp dword [ebp - 8], 0
mov dword [ebp - 0x3c], esi
jl 0x45f191
lea ecx, [ebp - 0x64]
call fcn.00437055
mov eax, dword [ebp - 0x28]
xor edi, edi
mov dword [ebp - 0x60], edi
mov dword [ebp - 0x5c], edi
cmp word [eax], 0x75
jne 0x45eace
cmp word [eax + 2], 0x64
jne 0x45eace
cmp word [eax + 4], 0x3a
jne 0x45eace
mov ecx, dword [ebp + 8]
push 0x22
add eax, 6
pop esi
mov word [ecx], di
cmp word [eax], si
mov dword [ebp - 0x2c], eax
jne 0x45e983
inc eax
inc eax
mov dword [ebp - 0x2c], eax
mov ebx, eax
push 0x3a
lea eax, [ebp - 0x2c]
call fcn.00410b80
mov eax, dword [ebp - 0x2c]
cmp eax, ebx
pop ecx
je 0x45e9a1
cmp word [eax - 2], si
jne 0x45e9a1
mov word [eax - 2], di
cmp word [eax], 0x3a
jne 0x45e9ac
mov word [eax], di
inc eax
inc eax
cmp word [eax], si
mov ecx, eax
jne 0x45e9c5
lea ecx, [eax + 2]
inc eax
inc eax
cmp word [eax], si
jne 0x45e9c0
mov word [eax], di
cmp word [eax], di
jne 0x45e9b6
push edi
push edi
push 0x10000
push ecx
lea eax, [ebp - 0x64]
push eax
push ebx
call fcn.0042ff9f
mov ebx, dword [ebp - 0x60]
add esp, 0x18
cmp ebx, edi
jle 0x45e9ee
mov eax, dword [ebp - 0x5c]
mov ecx, dword [ebp - 0x64]
add eax, ecx
mov dword [ebp + 8], eax
jmp 0x45e9f1
mov eax, dword [ebp + 8]
movsx edx, byte [eax]
mov esi, 0xff
xor ecx, ecx
cmp edx, esi
jne 0x45ea14
movsx edi, byte [eax + 1]
cmp edi, 0xfe
jne 0x45ea14
mov dword [ebp - 8], 0x4b0
jmp 0x45ea2b
cmp edx, 0xfe
jne 0x45ea2f
movsx edi, byte [eax + 1]
cmp edi, esi
jne 0x45ea2f
mov dword [ebp - 8], 0x4b1
push 2
jmp 0x45ea58
cmp edx, 0xef
jne 0x45ea59
movsx edx, byte [eax + 1]
cmp edx, 0xbb
jne 0x45ea59
movsx edx, byte [eax + 2]
cmp edx, 0xbf
jne 0x45ea59
mov dword [ebp - 8], 0xfde9
push 3
pop ecx
sub ebx, ecx
cmp dword [ebp - 8], 0x4b1
mov esi, ebx
lea edi, [ecx + eax]
jne 0x45ea8d
and esi, 0xfffffffe
add esi, edi
cmp edi, esi
mov ecx, edi
ja 0x45eb0b
mov al, byte [ecx]
mov dl, byte [ecx + 1]
mov byte [ecx], dl
mov byte [ecx + 1], al
inc ecx
inc ecx
cmp ecx, esi
jbe 0x45ea78
mov eax, dword [ebp + 8]
jmp 0x45eb0b
cmp dword [ebp - 8], 0x4b0
je 0x45eb0b
mov eax, dword [ebp - 0x64]
mov dword [ebp - 0x40], eax
lea eax, [esi + esi + 0x20]
xor ebx, ebx
push eax
lea ecx, [ebp - 0x64]
mov dword [ebp - 0x64], ebx
call fcn.00437099
push dword [ebp - 8]
lea ecx, [ebp - 0x64]
push esi
push edi
call fcn.0043723b
mov eax, dword [ebp - 0x64]
lea ecx, [ebp - 0x40]
mov dword [ebp + 8], eax
call fcn.00431c4c
mov eax, dword [ebp + 8]
jmp 0x45eb0d
mov eax, dword [ebp - 0x14]
cmp word [eax], di
jne 0x45eae3
lea ecx, [ebp - 0x64]
call fcn.00431c4c
jmp 0x45f19f
cmp byte [ebp - 2], 1
mov eax, dword [ebp + 8]
jne 0x45eafc
cmp word [eax], 0x2c
je 0x45eafc
mov edi, 0x80070057
jmp 0x45f189
inc eax
inc eax
test byte [ebp - 2], 1
mov dword [ebp + 8], eax
je 0x45ed81
xor ebx, ebx
cmp dword [ebp - 0x1c], ebx
mov dword [ebp - 0x20], ebx
je 0x45eb66
lea eax, [ebp + 8]
push eax
call fcn.00431c97
mov esi, dword [ebp + 8]
lea eax, [ebp + 8]
push eax
call fcn.004047e3
mov eax, dword [ebp + 8]
cmp word [eax], bx
pop ecx
pop ecx
je 0x45eb3a
mov word [eax], bx
mov eax, dword [ebp + 8]
cmp word [esi], bx
je 0x45eb66
mov ecx, dword [ebp - 0x10]
push 0xffffffffffffffff
push ebx
push esi
call fcn.00411179
cmp eax, ebx
je 0x45eb63
push 0xffffffffffffffff
push dword [eax]
lea ecx, [ebp - 0x20]
call fcn.004372a4
mov eax, dword [ebp - 0x20]
mov dword [ebp + 8], eax
jmp 0x45eb66
mov eax, dword [ebp + 8]
cmp byte [ebp - 1], 3
mov edi, eax
jne 0x45eb74
push eax
jmp 0x45ecba
cmp byte [ebp - 1], 0
je 0x45ec1e
cmp byte [ebp - 1], 1
mov edi, 0x49aa70
je 0x45eb8e
mov edi, 0x497d7c
lea ecx, [ebp - 0x24]
call fcn.0043717e
mov eax, dword [ebp + 8]
mov esi, eax
jmp 0x45ebe3
cmp cx, 0xd
jne 0x45ebb3
cmp word [eax + 2], 0xa
jne 0x45ebb9
mov word [eax], bx
add dword [ebp + 8], 2
jmp 0x45ebbc
cmp cx, 0xa
jne 0x45ebde
mov word [eax], bx
cmp byte [ebp - 1], 0
jne 0x45ebcb
push edi
lea ecx, [ebp - 0x24]
call fcn.004371ec
push esi
lea ecx, [ebp - 0x24]
mov byte [ebp - 1], 0
call fcn.004371ec
mov eax, dword [ebp + 8]
lea esi, [eax + 2]
inc eax
inc eax
mov dword [ebp + 8], eax
mov cx, word [eax]
cmp cx, bx
jne 0x45eb9d
cmp word [esi], bx
je 0x45ec08
cmp byte [ebp - 1], 0
jne 0x45ebff
push edi
lea ecx, [ebp - 0x24]
call fcn.004371ec
push esi
lea ecx, [ebp - 0x24]
call fcn.004371ec
push dword [ebp - 0x24]
mov ecx, dword [ebp - 0x10]
push dword [ebp - 0x14]
call fcn.00436b54
lea ecx, [ebp - 0x24]
jmp 0x45ed65
mov edx, dword [ebp - 0x34]
cmp edx, ebx
jge 0x45ec81
mov cx, word [eax]
xor esi, esi
cmp cx, bx
je 0x45ec4f
cmp cx, 0xa
jne 0x45ec36
inc esi
inc eax
inc eax
mov dword [ebp + 8], eax
mov cx, word [eax]
cmp cx, bx
jne 0x45ec2f
cmp eax, edi
jbe 0x45ec4f
cmp word [eax - 2], 0xa
je 0x45ec4f
inc esi
push 0x20
lea ecx, [ebp - 0x2c]
call fcn.0043719c
push esi
push 0x497ed0
push dword [ebp - 0x2c]
call dword [sym.imp.USER32.dll_wsprintfW]
mov ecx, dword [ebp - 0x10]
add esp, 0xc
push dword [ebp - 0x2c]
push dword [ebp - 0x14]
call fcn.00436b54
lea ecx, [ebp - 0x2c]
jmp 0x45ed65
jne 0x45ecfd
mov dx, word [eax]
cmp dx, bx
mov ecx, eax
mov esi, eax
je 0x45ecd9
cmp dx, 0xa
jne 0x45ec99
mov esi, ecx
mov ecx, eax
inc eax
inc eax
mov dword [ebp + 8], eax
mov dx, word [eax]
cmp dx, bx
jne 0x45ec8f
cmp eax, edi
jbe 0x45ecca
cmp word [eax - 2], 0xa
je 0x45ecca
cmp word [ecx], 0xa
jne 0x45ecb9
inc ecx
inc ecx
push ecx
push dword [ebp - 0x14]
mov ecx, dword [ebp - 0x10]
call fcn.00436b54
jmp 0x45ed6a
cmp ecx, edi
jbe 0x45ecd9
lea eax, [ecx - 2]
cmp word [eax], 0xd
jne 0x45ecd9
mov ecx, eax
cmp word [esi], 0xa
jne 0x45ece1
inc esi
inc esi
sub ecx, esi
sar ecx, 1
push ecx
push esi
jmp 0x45ed4c
mov cx, word [eax]
cmp cx, bx
je 0x45ed02
cmp cx, 0xa
jne 0x45ecf8
dec edx
inc eax
inc eax
mov dword [ebp + 8], eax
cmp edx, 1
jg 0x45ece9
mov esi, dword [ebp - 0x18]
mov edi, eax
jmp 0x45ed3c
cmp esi, ebx
je 0x45ed12
dec dword [ebp - 0x18]
js 0x45ed46
lea eax, [ebp + 8]
call fcn.00410bc4
cmp esi, ebx
je 0x45ed23
cmp dword [ebp - 0x18], ebx
je 0x45ed43
mov eax, dword [ebp + 8]
cmp word [eax], 0xd
jne 0x45ed31
inc eax
inc eax
mov dword [ebp + 8], eax
cmp word [eax], 0xa
jne 0x45ed3c
inc eax
inc eax
mov dword [ebp + 8], eax
cmp word [eax], bx
jne 0x45ed09
jmp 0x45ed46
mov eax, dword [ebp + 8]
sub eax, edi
sar eax, 1
push eax
push edi
lea ecx, [ebp - 0x34]
call fcn.004419d9
push dword [ebp - 0x34]
mov ecx, dword [ebp - 0x10]
push dword [ebp - 0x14]
call fcn.00436b54
lea ecx, [ebp - 0x34]
call fcn.00431c4c
lea ecx, [ebp - 0x20]
call fcn.00431c4c
lea ecx, [ebp - 0x64]
call fcn.00431c4c
xor edi, edi
jmp 0x45f19f
push 8
lea ecx, [ebp - 0x24]
call fcn.00437072
and word [esi], 0
and dword [ebp - 0x1c], 0
xor eax, eax
cmp byte [ebp - 2], 2
lea edi, [ebp - 0x54]
stosd dword es:[edi], eax
mov eax, dword [0x4ae2e0]
mov dword [ebp - 0x58], eax
jne 0x45ee43
lea eax, [ebp - 0x58]
mov dword [ebp - 0x20], eax
push 0
mov dword [ebp - 0x3c], 0x186a0
call dword [sym.imp.KERNEL32.dll_SetLastError]
cmp byte [ebp - 1], 3
jne 0x45ef43
mov eax, dword [ebp - 0x20]
mov eax, dword [eax]
xor edi, edi
mov dword [ebp - 0x2c], edi
mov dword [ebp - 0x44], eax
mov esi, 0x40000
lea eax, [edi + 0x40001]
push eax
lea ecx, [ebp - 0x2c]
call fcn.00437099
mov ebx, dword [ebp - 0x2c]
and dword [ebp - 0x20], 0
push 0
lea eax, [ebp - 0x20]
push eax
push esi
lea eax, [edi + ebx]
push eax
push dword [ebp - 0x44]
call dword [sym.imp.KERNEL32.dll_ReadFile]
cmp dword [ebp - 0x20], esi
jbe 0x45ee0e
mov dword [ebp - 0x20], esi
cmp dword [ebp - 0x20], 0
jne 0x45ee3a
test eax, eax
jne 0x45ef10
cmp byte [ebp - 2], 2
jne 0x45ee31
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x6d
je 0x45ef10
dec dword [ebp - 0x3c]
js 0x45ef10
add edi, dword [ebp - 0x20]
mov byte [edi + ebx], 0
jmp 0x45eddc
xor edi, edi
push edi
push edi
push 3
push edi
push 7
lea eax, [ebp - 0x1c]
push 0x80000000
push dword [ebp - 0x28]
mov ecx, eax
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x2c], edi
call fcn.00404863
cmp dword [ebp - 0x1c], edi
je 0x45ef03
xor eax, eax
and dword [ebp - 0x44], eax
push eax
mov byte [ebp - 0x50], 0
mov byte [ebp - 0x4f], 0
mov byte [ebp - 0x4e], 0
lea edi, [ebp - 0x4d]
stosw word es:[edi], ax
lea eax, [ebp - 0x44]
push eax
push 3
lea eax, [ebp - 0x50]
push eax
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_ReadFile]
cmp byte [ebp - 0x50], 0xff
jne 0x45eeb3
cmp byte [ebp - 0x4f], 0xfe
jne 0x45eee8
mov dword [ebp - 8], 0x4b0
mov dword [ebp - 0x2c], 2
jmp 0x45eee8
cmp byte [ebp - 0x50], 0xfe
jne 0x45eec8
cmp byte [ebp - 0x4f], 0xff
jne 0x45eee8
mov dword [ebp - 8], 0x4b1
jmp 0x45eeaa
cmp byte [ebp - 0x50], 0xef
jne 0x45eee8
cmp byte [ebp - 0x4f], 0xbb
jne 0x45eee8
cmp byte [ebp - 0x4e], 0xbf
jne 0x45eee8
mov dword [ebp - 8], 0xfde9
mov dword [ebp - 0x2c], 3
mov eax, dword [ebp - 0x2c]
cdq
push 0
push edx
push eax
push dword [ebp - 0x1c]
call fcn.00432bc3
add esp, 0x10
test eax, eax
jge 0x45edb1
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
jmp 0x45f179
mov eax, dword [ebp - 8]
lea esi, [ebp - 0x2c]
call fcn.0043df5f
mov ecx, dword [ebp - 0x10]
push eax
push dword [ebp - 0x14]
call fcn.00436b54
mov ecx, esi
call fcn.00431c4c
lea ecx, [ebp - 0x1c]
call fcn.00402b75
lea ecx, [ebp - 0x24]
call fcn.00431c4c
jmp 0x45ed72
cmp byte [ebp - 1], 0
je 0x45efdb
mov eax, dword [ebp - 0x30]
test eax, eax
jne 0x45ef59
mov eax, 0x49895e
push 0xffffffffffffffff
push eax
lea ecx, [ebp - 0x3c]
call fcn.004419f2
or ebx, 1
lea ecx, [ebp - 0x18]
call fcn.0043717e
cmp byte [ebp - 1], 0
jne 0x45ef80
push dword [ebp - 0x3c]
lea ecx, [ebp - 0xc]
call fcn.004371ec
push ebx
push dword [ebp - 8]
lea eax, [ebp - 0x18]
push eax
push dword [ebp - 0x20]
mov byte [ebp - 1], 0
call fcn.0043dc98
add esp, 0x10
cmp byte [ebp - 2], 2
mov edi, eax
jne 0x45efaa
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x6d
je 0x45efcb
mov eax, dword [ebp - 8]
lea esi, [ebp - 0x18]
call fcn.0043df5f
push eax
lea ecx, [ebp - 0xc]
call fcn.004371ec
mov ecx, esi
call fcn.00431c4c
test edi, edi
je 0x45efd3
jmp 0x45ef67
lea ecx, [ebp - 0x18]
call fcn.00431c4c
lea ecx, [ebp - 0x3c]
jmp 0x45f15d
mov edi, dword [ebp - 0x34]
test edi, edi
jge 0x45f03b
xor edi, edi
push dword [ebp - 0x40]
lea eax, [ebp - 0xc]
push dword [ebp - 8]
push eax
push dword [ebp - 0x20]
call fcn.0043dc98
add esp, 0x10
cmp byte [ebp - 2], 2
mov esi, eax
jne 0x45f00c
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x6d
je 0x45f013
test esi, esi
je 0x45f013
inc edi
jmp 0x45efe4
push 0x20
lea ecx, [ebp - 0xc]
mov dword [ebp - 8], 0x4b0
call fcn.00437099
push edi
push 0x497ed0
push dword [ebp - 0xc]
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0xc
jmp 0x45f169
jne 0x45f07e
or ebx, 1
mov eax, esi
mov esi, dword [ebp - 0x24]
push ebx
push dword [ebp - 8]
mov dword [ebp - 0x24], eax
lea eax, [ebp - 0x24]
push eax
push dword [ebp - 0x20]
mov dword [ebp - 0xc], esi
call fcn.0043dc98
add esp, 0x10
cmp byte [ebp - 2], 2
mov edi, eax
jne 0x45f075
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x6d
je 0x45f169
test edi, edi
jne 0x45f040
jmp 0x45f169
xor eax, eax
inc eax
cmp edi, eax
mov dword [ebp - 0x34], eax
jle 0x45f0bf
push dword [ebp - 0x40]
lea eax, [ebp - 0xc]
push dword [ebp - 8]
push eax
push dword [ebp - 0x20]
call fcn.0043dc98
add esp, 0x10
cmp byte [ebp - 2], 2
mov esi, eax
jne 0x45f0b0
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x6d
je 0x45f0bc
test esi, esi
je 0x45f0bc
inc dword [ebp - 0x34]
cmp dword [ebp - 0x34], edi
jl 0x45f088
mov esi, dword [ebp - 0xc]
mov edi, dword [ebp - 0x18]
cmp edi, 1
mov byte [esi], 0
jne 0x45f0e4
or ebx, edi
push ebx
push dword [ebp - 8]
lea eax, [ebp - 0xc]
push eax
push dword [ebp - 0x20]
call fcn.0043dc98
add esp, 0x10
jmp 0x45f169
lea ecx, [ebp - 0x2c]
call fcn.0043717e
test edi, edi
je 0x45f0f5
dec dword [ebp - 0x18]
js 0x45f15a
mov eax, dword [ebp - 0x2c]
and word [eax], 0
xor eax, eax
mov al, bl
or eax, 1
push eax
push dword [ebp - 8]
lea eax, [ebp - 0x2c]
push eax
push dword [ebp - 0x20]
call fcn.0043dc98
add esp, 0x10
cmp byte [ebp - 2], 2
mov esi, eax
jne 0x45f129
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x6d
je 0x45f15a
test esi, esi
je 0x45f15a
mov eax, dword [ebp - 8]
lea esi, [ebp - 0x2c]
call fcn.0043df5f
push eax
lea ecx, [ebp - 0xc]
call fcn.004371ec
test edi, edi
je 0x45f14b
cmp dword [ebp - 0x18], 0
jle 0x45f15a
push 0x497d7c
lea ecx, [ebp - 0xc]
call fcn.004371ec
jmp 0x45f0ec
lea ecx, [ebp - 0x2c]
mov dword [ebp - 8], 0x4b0
call fcn.00431c4c
mov eax, dword [ebp - 8]
lea esi, [ebp - 0xc]
call fcn.0043df5f
mov dword [ebp - 0x3c], eax
xor edi, edi
lea ecx, [ebp - 0x1c]
call fcn.00402b75
lea ecx, [ebp - 0x24]
call fcn.00431c4c
lea ecx, [ebp - 0x64]
call fcn.00431c4c
push dword [ebp - 0x3c]
mov ecx, dword [ebp - 0x10]
push dword [ebp - 0x14]
call fcn.00436b54
lea ecx, [ebp - 0xc]
call fcn.00431c4c
lea ecx, [ebp - 0x38]
call fcn.00431c4c
lea ecx, [ebp - 0x48]
call fcn.00402b75
lea ecx, [ebp - 0x14]
call fcn.00431c4c
lea ecx, [ebp - 0x28]
call fcn.00431c4c
mov eax, edi
pop edi
pop esi
pop ebx
leave
ret 8