Function at 0x4912a0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push esi
push edi
push ebx
sub esp, 0x74
mov ebx, dword [ebp + 8]
cmp dword [ebx + 0x124], 0xfffffffc
je 0x493630
and byte [ebx + 0x1ad], 0xfe
test byte [ebx + 0x1a9], 0x10
je 0x4912e1
push ebx
call fcn.0049b6f0
add esp, 4
test eax, eax
jne 0x492813
and byte [ebx + 0x1a9], 0xef
mov eax, dword [ebx + 0x94]
test byte [ebx + 0x1a2], 0x40
je 0x491333
test eax, eax
je 0x491349
cmp byte [eax + 0x1c], 0
je 0x491337
mov byte [ebp - 0x10], 0xa
mov edx, dword [eax + 0x10]
test edx, edx
push 1
jne 0x491309
mov edx, ebx
lea eax, [ebp - 0x10]
push eax
push edx
call fcn.004984a0
add esp, 0xc
cmp eax, 0xffffffff
je 0x49281b
mov eax, dword [ebx + 0x94]
test eax, eax
je 0x491349
mov byte [eax + 0x1c], 0
mov eax, dword [ebx + 0x94]
test eax, eax
je 0x491349
mov byte [eax + 0x1d], 0
mov eax, dword [ebx + 0x94]
test eax, eax
je 0x491349
mov byte [eax + 0x20], 0
movsx edx, byte [ebx + 0x18c]
cmp edx, 8
ja 0x491dc4
movzx eax, word [edx*2 + 0x506390]
add eax, 0x491368
jmp eax
push 0xe5c
push 0x5063a4
push 2
push 8
call fcn.0047e600
add esp, 0x10
mov eax, dword [ebx + 0x98]
xor esi, esi
mov dword [ebp - 0x50], eax
xor edi, edi
mov edx, dword [ebx + 0x160]
mov eax, dword [ebx + 0xb0]
mov dword [ebp - 0x54], esi
mov dword [ebp - 0x14], edx
mov dword [ebp - 0x48], eax
mov dword [ebp - 0x58], 0
cmp edi, dword [ebp - 0x48]
ja 0x4934a1
cmp edi, dword [ebp - 0x48]
ja 0x492c5e
cmp edi, 4
jne 0x491eff
mov ecx, dword [ebx + 0x64]
test byte [ebx + 0x1a5], 0x20
movzx edx, byte [ecx + 1]
mov dword [ebp - 0x60], edx
movzx eax, byte [ecx]
movzx edx, byte [ecx + 2]
movzx ecx, byte [ecx + 3]
mov dword [ebp - 0x5c], ecx
je 0x491e56
shl edx, 8
or ecx, edx
mov edx, dword [ebp - 0x60]
shl edx, 0x10
shl eax, 0x18
or ecx, edx
or ecx, eax
mov dword [ebp - 0x5c], ecx
jmp 0x491e6e
mov ecx, dword [ebp - 0x60]
shl ecx, 8
shl edx, 0x10
or eax, ecx
or eax, edx
mov edx, dword [ebp - 0x5c]
shl edx, 0x18
or edx, eax
mov dword [ebp - 0x5c], edx
cmp dword [ebp - 0x5c], 0
jl 0x491e80
movzx eax, byte [ebx + 0x1aa]
and eax, 0xffffffdf
jmp 0x491e8d
movzx eax, byte [ebx + 0x1aa]
neg dword [ebp - 0x5c]
or eax, 0x20
mov byte [ebx + 0x1aa], al
mov eax, dword [ebp - 0x5c]
movzx edx, byte [ebx + 0x1ac]
and edx, 0xfffffffe
mov dword [ebx + 0x17c], eax
mov dword [ebp - 0x4c], edx
cmp dword [ebx + 0x164], 0xb
jne 0x491ef5
and edx, 4
shr edx, 2
je 0x491ed2
test byte [ebp - 0x4c], 0x40
je 0x491ed2
mov eax, dword [ebp - 0x4c]
inc eax
mov dword [ebp - 0x4c], eax
mov byte [ebx + 0x1ac], al
jmp 0x491f5a
mov eax, dword [ebx + 0x168]
test eax, eax
jne 0x491ee1
mov eax, 0x20000
cmp eax, dword [ebp - 0x5c]
jae 0x491eea
test edx, edx
je 0x491ec0
mov eax, dword [ebp - 0x4c]
mov byte [ebx + 0x1ac], al
jmp 0x491f5a
mov eax, edx
mov byte [ebx + 0x1ac], al
jmp 0x491f5a
cmp edi, 2
jne 0x491f47
mov eax, dword [ebx + 0x64]
movzx edx, byte [eax + 1]
shl edx, 8
movzx ecx, byte [eax]
or ecx, edx
movsx eax, cx
mov dword [ebp - 0x5c], eax
cmp eax, 1
je 0x492cc6
movzx eax, byte [ebx + 0x1ac]
mov edx, dword [ebp - 0x5c]
mov dword [ebp - 0x4c], eax
and edx, 0x80000001
jge 0x491f3e
sub edx, 1
or edx, 0xfffffffe
inc edx
xor eax, eax
cmp eax, edx
adc esi, 0
jmp 0x491f5a
mov eax, dword [ebx + 0x118]
movzx edx, byte [ebx + 0x1ac]
mov dword [ebp - 0x5c], eax
mov dword [ebp - 0x4c], edx
mov edx, dword [ebp - 0x5c]
lea eax, [esi + edx]
mov edx, dword [ebp - 0x4c]
and edx, 1
mov dword [ebp - 0x38], eax
cmp eax, dword [ebp - 0x48]
jbe 0x49320b
test edx, edx
jne 0x49320b
test byte [ebx + 0x1a0], 1
jne 0x492fe2
cmp dword [ebp - 0x54], 0
je 0x492fe2
mov edx, eax
sub edx, esi
mov eax, dword [ebx + 0x10c]
mov dword [ebp - 0x60], edx
cmp edx, eax
jae 0x491faf
test byte [ebx + 0x1a7], 0x40
je 0x492fe2
cmp dword [ebp + 0xc], 0
je 0x493492
mov edx, dword [ebp + 0xc]
movsx edx, byte [edx + 1]
cmp edx, 5
je 0x493465
cmp edx, 7
je 0x493443
cmp dword [ebp - 0x50], 0
je 0x492fd7
movzx eax, byte [ebx + 0x1aa]
not eax
mov edx, dword [ebp - 0x48]
and eax, 0x20
sub edx, edi
shr eax, 5
mov dword [ebp - 0x3c], eax
cmp edx, dword [ebp - 0x14]
jb 0x492061
mov eax, dword [ebx + 0x64]
lea edx, [edi + eax]
cmp edx, dword [ebp - 0x50]
jb 0x492014
mov ecx, dword [ebp - 0x50]
mov esi, dword [ebp - 0x14]
add ecx, esi
cmp ecx, edx
ja 0x492021
cmp edx, dword [ebp - 0x50]
ja 0x49202f
mov ecx, dword [ebp - 0x14]
lea esi, [edi + ecx]
add esi, eax
cmp esi, dword [ebp - 0x50]
jbe 0x49202f
push dword [ebp - 0x14]
push edx
push dword [ebp - 0x50]
call fcn.004cd870
jmp 0x49203b
push dword [ebp - 0x14]
push edx
push dword [ebp - 0x50]
call fcn.004c6aa0
add esp, 0xc
mov eax, dword [ebx + 0xb0]
mov edx, dword [ebp - 0x14]
sub eax, edi
sub dword [ebx + 0x17c], edx
sub eax, edx
xor edx, edx
mov dword [ebx + 0xb0], eax
mov dword [ebp - 0x14], edx
jmp 0x4920e9
mov ecx, dword [ebx + 0x64]
lea eax, [edi + ecx]
cmp eax, dword [ebp - 0x50]
jb 0x49207d
mov esi, dword [ebp - 0x50]
sub esi, edi
add esi, dword [ebp - 0x48]
cmp esi, eax
ja 0x492087
cmp eax, dword [ebp - 0x50]
ja 0x492093
mov esi, dword [ebp - 0x48]
add esi, ecx
cmp esi, dword [ebp - 0x50]
jbe 0x492093
push edx
push eax
push dword [ebp - 0x50]
call fcn.004cd870
jmp 0x49209d
push edx
push eax
push dword [ebp - 0x50]
call fcn.004c6aa0
add esp, 0xc
mov eax, dword [ebx + 0xb0]
mov ecx, eax
mov edx, dword [ebp - 0x60]
sub ecx, edi
mov esi, edx
sub esi, ecx
mov dword [ebp - 0x48], esi
mov esi, dword [ebp - 0x14]
sub esi, ecx
add eax, dword [ebx + 0x64]
add dword [ebp - 0x50], ecx
mov dword [ebp - 0x14], esi
mov dword [ebx + 0x50], eax
mov dword [ebx + 0xb0], 0
mov dword [ebx + 0x64], 0
mov dword [ebp - 0x28], edx
test esi, esi
mov esi, dword [ebp - 0x48]
jg 0x49266d
mov edx, 1
or byte [ebx + 0x1a7], 0x40
test edx, edx
je 0x492103
mov eax, esi
add esi, edi
cdq
mov ecx, edx
adc ecx, 0
jmp 0x49224a
mov eax, dword [ebx + 0x68]
mov edx, dword [ebx + 0x4c]
mov dword [ebp - 0x44], eax
sub eax, edx
mov dword [ebp - 0x40], edx
cmp eax, dword [ebp - 0x38]
jg 0x49223d
mov esi, dword [ebp - 0x38]
mov eax, esi
mov ecx, dword [ebp - 0x44]
cdq
mov eax, ecx
mov dword [ebp - 0x4c], edx
cdq
mov eax, dword [ebp - 0x40]
mov ebx, edx
cdq
sub ecx, eax
mov dword [ebp - 0x20], edi
sbb ebx, edx
sub esi, ecx
mov ecx, dword [ebp - 0x4c]
sbb ecx, ebx
mov ebx, dword [ebp + 8]
movzx edx, byte [eax]
mov dword [ebp - 0x54], edx
movzx edi, byte [ebx + 0x1a5]
and edi, 0x20
movzx edx, byte [eax + 2]
mov dword [ebp - 0x58], edx
movzx edx, byte [eax + 3]
mov dword [ebp - 0x60], edx
shr edi, 5
mov dword [ebp - 0x50], edi
movzx edi, byte [eax + 1]
mov dword [ebp - 0x5c], edi
mov edi, dword [ebp - 0x20]
je 0x49218d
mov eax, dword [ebp - 0x58]
shl eax, 8
or edx, eax
mov eax, dword [ebp - 0x5c]
shl eax, 0x10
or edx, eax
mov eax, dword [ebp - 0x54]
shl eax, 0x18
or edx, eax
mov dword [ebp - 0x60], edx
jmp 0x4921ab
mov eax, dword [ebp - 0x5c]
shl eax, 8
mov edx, dword [ebp - 0x54]
or edx, eax
mov eax, dword [ebp - 0x58]
shl eax, 0x10
or edx, eax
mov eax, dword [ebp - 0x60]
shl eax, 0x18
or eax, edx
mov dword [ebp - 0x60], eax
mov eax, dword [ebp - 0x60]
cdq
add eax, 8
mov dword [ebp - 0x60], eax
adc edx, 0
sub eax, dword [ebp - 0x38]
mov dword [ebp - 0x5c], edx
mov ebx, dword [ebp + 8]
sbb edx, dword [ebp - 0x4c]
jge 0x49224a
mov dword [ebp - 0x20], edi
mov dword [ebp - 0x48], esi
mov edi, dword [ebp - 0x5c]
mov eax, dword [ebp - 0x60]
mov edx, dword [ebp - 0x40]
cmp edx, dword [ebp - 0x44]
jae 0x492232
add edx, eax
add dword [ebp - 0x48], eax
mov dword [ebp - 0x40], edx
adc ecx, edi
movzx edi, byte [edx]
movzx esi, byte [edx + 1]
movzx ebx, byte [edx + 2]
movzx eax, byte [edx + 3]
cmp dword [ebp - 0x50], 0
je 0x49220e
shl ebx, 8
shl esi, 0x10
or eax, ebx
shl edi, 0x18
or eax, esi
or eax, edi
jmp 0x49221d
shl esi, 8
shl ebx, 0x10
or edi, esi
shl eax, 0x18
or edi, ebx
or eax, edi
cdq
add eax, 8
mov edi, edx
mov ebx, eax
adc edi, 0
sub ebx, dword [ebp - 0x38]
mov esi, edi
sbb esi, dword [ebp - 0x4c]
jl 0x4921d6
mov esi, dword [ebp - 0x48]
mov edi, dword [ebp - 0x20]
mov ebx, dword [ebp + 8]
jmp 0x49224a
mov esi, dword [ebp - 0x38]
xor ecx, ecx
sub esi, edi
sub esi, dword [ebx + 0x160]
mov edx, 1
mov dword [esp + 4], esi
mov eax, dword [ebx + 0x104]
mov dword [esp + 8], ecx
call fcn.0046c830
mov ecx, eax
mov eax, 0xffffffff
sub ecx, eax
sub edx, eax
or ecx, edx
je 0x4929b3
mov ecx, edi
lea eax, [ebx + 0xb0]
mov dword [ebp - 0x20], eax
mov dword [esp + 0xc], eax
movzx eax, byte [ebx + 0x1a8]
and eax, 0x80
shr eax, 7
mov dword [esp + 0x10], eax
movzx eax, byte [ebx + 0x1a9]
and eax, 1
mov dword [esp + 0x14], eax
mov eax, dword [ebx + 0x16c]
mov dword [esp + 0x18], eax
mov eax, dword [ebx + 0x104]
mov edx, dword [ebx + 0x4c]
mov dword [esp + 0x1c], ebx
call fcn.0049366c
movzx edx, byte [ebx + 0x1a5]
cmp dword [ebp - 0x3c], 0
je 0x4922d6
mov eax, dword [ebx + 0x4c]
jmp 0x492552
mov eax, dword [ebx + 0x4c]
movzx ecx, byte [eax]
movzx esi, byte [eax + 1]
movzx edi, byte [eax + 2]
movzx eax, byte [eax + 3]
test dl, 0x20
je 0x4922fe
shl edi, 8
shl esi, 0x10
or eax, edi
shl ecx, 0x18
or eax, esi
or eax, ecx
jmp 0x49230d
shl esi, 8
shl edi, 0x10
or ecx, esi
shl eax, 0x18
or ecx, edi
or eax, ecx
xor esi, esi
cdq
mov edi, eax
lea ecx, [ebp - 0x38]
xor edi, edx
test eax, eax
push 1
push ecx
mov dword [ecx], 0
jl 0x492329
mov esi, 1
sub edi, edx
sub edi, dword [ebx + 0xb0]
add edi, 8
push edi
push dword [ebx + 0x104]
mov dword [ebp - 0x3c], edi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov dword [ebp - 0x3c], eax
cmp eax, 0xffffffff
je 0x492d83
cmp eax, 0xffffffff
je 0x49264d
mov ecx, dword [ebx + 0x104]
mov dword [ebp - 0x30], ecx
movzx ecx, byte [ebx + 0x1a8]
and ecx, 0x80
movzx eax, byte [ebx + 0x1a9]
shr ecx, 7
and eax, 1
mov edx, dword [ebx + 0x16c]
mov edi, dword [ebx + 0x4c]
mov dword [ebp - 0x2c], eax
mov dword [ebx + 0xb0], 0
cmp dword [ebx + 0x28], 0xfffffffc
je 0x492d64
cmp dword [0x22072dc], 0
je 0x492448
lea eax, [edx - 1]
cmp eax, 1
jbe 0x49264d
test ecx, ecx
je 0x492440
cmp edx, 0xfffffffa
je 0x492d34
test edx, edx
je 0x492cf5
cmp dword [ebp - 0x2c], 0
je 0x492448
mov dword [ebp - 0x4c], 0
push dword [ebp - 0x34]
mov dword [ebp - 0x54], edx
call fcn.004cb4d0
push dword [ebp - 0x34]
call fcn.004cb4f0
mov edx, dword [ebp - 0x54]
add esp, 8
cmp dword [ebp - 0x4c], 0
je 0x492448
push dword [ebp - 0x34]
push 4
push edi
call fcn.004cb4d0
add esp, 0xc
mov dword [ebx + 0xb0], eax
cmp eax, 0xffffffff
je 0x49264d
push 0
push dword [ebp - 0x34]
push 2
push 0x5063f0
mov dword [ebp - 0x48], eax
call fcn.004cb4d0
mov eax, dword [ebp - 0x48]
add esp, 0x10
mov byte [eax + edi], 0xa
inc dword [ebx + 0xb0]
jmp 0x4924fc
test edx, edx
je 0x492cf5
mov dword [ebp - 0x54], edx
push 0
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov eax, dword [ebx + 0x168]
mov edx, dword [ebp - 0x54]
mov dword [ebx + 0xb0], 0
test eax, eax
je 0x4924d9
cmp eax, 4
jae 0x4924d9
test edx, edx
je 0x4924d9
test eax, eax
mov dword [ebp - 0x60], esi
jne 0x49247f
mov eax, 0x20000
mov edx, 4
mov ebx, edi
mov edi, eax
mov esi, edx
push 0
lea ecx, [ebp - 0x5c]
push ecx
push edi
push ebx
push dword [ebp - 0x30]
mov dword [ebp - 0x58], edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x4924aa
mov esi, dword [ebp - 0x60]
mov ebx, dword [ebp + 8]
jmp 0x4924f4
mov ecx, dword [ebp - 0x20]
mov edx, dword [ebp - 0x5c]
sub esi, edx
add ebx, edx
add dword [ecx], edx
mov ecx, dword [ebp + 8]
mov ecx, dword [ecx + 0x168]
test ecx, ecx
jne 0x4924c8
mov ecx, 0x20000
cmp esi, ecx
ja 0x4924ce
mov edi, esi
test esi, esi
je 0x4924a2
cmp edx, dword [ebp - 0x58]
je 0x49248a
jmp 0x4924a2
push 0
lea eax, [ebp - 0x5c]
push eax
push 4
push edi
push dword [ebp - 0x30]
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov edx, dword [ebp - 0x5c]
mov dword [ebx + 0xb0], edx
test eax, eax
je 0x49264d
mov eax, dword [ebx + 0x4c]
movzx edx, byte [ebx + 0x1a5]
mov dword [ebp - 0x44], edx
mov dword [ebp - 0x40], eax
movzx edx, byte [eax]
movzx ecx, byte [eax + 1]
movzx edi, byte [eax + 2]
movzx eax, byte [eax + 3]
mov ebx, dword [ebp + 8]
test byte [ebp - 0x44], 0x20
je 0x492535
shl edi, 8
shl ecx, 0x10
or eax, edi
shl edx, 0x18
or eax, ecx
or eax, edx
jmp 0x492544
shl ecx, 8
shl edi, 0x10
or edx, ecx
shl eax, 0x18
or edx, edi
or eax, edx
test esi, esi
je 0x49230f
mov eax, dword [ebp - 0x40]
mov edx, dword [ebp - 0x44]
mov esi, dword [ebx + 0xb0]
or edx, 2
mov dword [ebx + 0x64], eax
mov byte [ebx + 0x1a5], dl
cmp dword [ebp - 0x14], 0
lea ecx, [eax + esi]
mov dword [ebp - 0x18], ecx
mov dword [ebx + 0x68], ecx
mov dword [ebx + 0x50], ecx
je 0x49257e
test esi, esi
je 0x49364b
mov edi, dword [ebx + 0x58]
mov dword [ebx + 0x12c], 0
cmp edi, dword [ebp - 0x18]
je 0x4925db
movsx eax, byte [ebx + 0x18c]
add eax, 0xfffffffa
test eax, 0xfffffffd
jne 0x4925db
mov eax, edi
dec eax
je 0x492d50
cmp byte [edi - 1], 0xd
jne 0x4925bc
mov edi, dword [ebp - 0x18]
cmp edi, eax
ja 0x4925b9
mov edi, eax
mov dword [ebx + 0x58], edi
test byte [ebx + 0x1aa], 0x10
je 0x4925db
cmp edi, dword [ebp - 0x18]
jbe 0x4925db
mov eax, dword [ebp - 0x18]
cmp byte [edi - 1], 0xd
jne 0x4925db
dec edi
mov dword [ebx + 0x58], edi
cmp edi, eax
ja 0x4925cd
test byte [ebx + 0x1a0], 4
je 0x492605
test byte [ebx + 0x1a2], 0x40
je 0x492605
test byte [ebx + 0x1a3], 8
je 0x492605
cmp byte [ebx + 0x18c], 1
jne 0x492605
add edi, 0xfffffffe
mov dword [ebx + 0x58], edi
sub edi, dword [ebp - 0x18]
cmp edi, 1
jne 0x492643
movzx eax, byte [ebx + 0x1a2]
test al, 0x40
jne 0x492637
test eax, 0x80
jne 0x49262e
movzx eax, byte [ebx + 0x1a8]
test al, 1
jne 0x49262e
test al, 2
je 0x492643
cmp byte [ebx + 0x18c], 4
jne 0x492643
mov eax, dword [ebp - 0x18]
cmp byte [eax], 0x1a
je 0x492cd3
xor eax, eax
lea esp, [ebp - 0xc]
pop ebx
pop edi
pop esi
pop ebp
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebx + 0x108], eax
and byte [ebx + 0x1ad], 0xfe
mov eax, 0x27
lea esp, [ebp - 0xc]
pop ebx
pop edi
pop esi
pop ebp
ret
mov dword [ebp - 0x20], edi
mov edi, dword [ebp - 0x14]
cmp esi, edi
mov ecx, esi
mov eax, dword [ebx + 0x104]
lea edx, [ebp - 0x1c]
mov dword [esp + 0xc], edx
movzx edx, byte [ebx + 0x1a8]
jl 0x49268f
mov ecx, edi
and edx, 0x80
shr edx, 7
mov dword [esp + 0x10], edx
movzx edx, byte [ebx + 0x1a9]
and edx, 1
mov dword [esp + 0x14], edx
mov edx, dword [ebx + 0x16c]
mov dword [esp + 0x18], edx
mov dword [esp + 0x1c], ebx
mov edx, dword [ebp - 0x50]
call fcn.0049366c
mov dword [ebp - 0x54], eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x3e3
je 0x492fc4
cmp dword [ebp - 0x54], 0
je 0x492f88
mov edx, dword [ebp - 0x1c]
test edx, edx
je 0x492f59
sub edi, edx
sub esi, edx
add dword [ebp - 0x50], edx
test edi, edi
jle 0x492f49
movzx eax, byte [ebx + 0x1a8]
lea esi, [ebp - 0x1c]
and eax, 0x80
mov ecx, dword [ebx + 0x16c]
movzx edx, byte [ebx + 0x1a9]
mov dword [esp + 0xc], esi
and edx, 1
shr eax, 7
mov dword [esp + 0x10], eax
mov dword [esp + 0x14], edx
lea edx, [ebp - 0x24]
mov dword [esp + 0x18], ecx
mov dword [esp + 0x1c], ebx
mov eax, dword [ebx + 0x104]
mov ecx, dword [ebp - 0x20]
call fcn.0049366c
mov esi, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x3e3
je 0x492f36
test esi, esi
je 0x492efa
cmp dword [ebp - 0x1c], 0
je 0x492ecb
cmp dword [ebp - 0x20], 4
je 0x492e7a
mov eax, dword [ebp - 0x24]
cdq
xor eax, edx
lea esi, [ebp - 0x1c]
sub eax, edx
mov dword [ebp - 0x24], eax
movzx eax, byte [ebx + 0x1a8]
and eax, 0x80
mov ecx, dword [ebx + 0x16c]
movzx edx, byte [ebx + 0x1a9]
mov dword [esp + 0xc], esi
and edx, 1
shr eax, 7
mov dword [esp + 0x10], eax
mov dword [esp + 0x14], edx
lea edx, [ebp - 0x28]
mov dword [esp + 0x18], ecx
mov dword [esp + 0x1c], ebx
mov eax, dword [ebx + 0x104]
mov ecx, dword [ebp - 0x20]
call fcn.0049366c
mov esi, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x3e3
je 0x492e67
test esi, esi
je 0x492e2b
cmp dword [ebp - 0x1c], 0
je 0x492dfc
cmp dword [ebp - 0x20], 4
je 0x492da5
mov esi, dword [ebp - 0x28]
test esi, esi
js 0x492802
mov dword [ebp - 0x3c], 1
jmp 0x492673
neg esi
mov dword [ebp - 0x28], esi
mov dword [ebp - 0x3c], 0
jmp 0x492673
lea esp, [ebp - 0xc]
pop ebx
pop edi
pop esi
pop ebp
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebx + 0x108], eax
mov eax, 0x26
lea esp, [ebp - 0xc]
pop ebx
pop edi
pop esi
pop ebp
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebx + 0x108], eax
mov eax, 0x27
lea esp, [ebp - 0xc]
pop ebx
pop edi
pop esi
pop ebp
ret
mov eax, 0x18
lea esp, [ebp - 0xc]
pop ebx
pop edi
pop esi
pop ebp
ret
mov eax, dword [ebx + 0x50]
cmp byte [eax + 2], 0x1a
jne 0x491f22
add dword [ebx + 0xb8], 1
adc dword [ebx + 0xbc], 0
mov eax, 0x18
and byte [ebx + 0x1a7], 0xfb
lea esp, [ebp - 0xc]
pop ebx
pop edi
pop esi
pop ebp
ret
mov dword [ebp - 0x54], edx
mov dword [ebp - 0x50], ecx
call fcn.004cb4f0
mov ecx, dword [ebp - 0x50]
mov edx, dword [ebp - 0x54]
mov dword [ebp - 0x34], eax
cmp dword [0x22072dc], 0
je 0x4923fa
test ecx, ecx
je 0x4923fa
cmp dword [ebp - 0x2c], 0
je 0x4923fa
mov dword [ebp - 0x4c], 1
jmp 0x4923db
mov eax, dword [ebp - 0x30]
mov dword [ebp - 0x34], eax
cmp dword [ebp - 0x2c], 0
je 0x4923fa
mov dword [ebp - 0x4c], 1
jmp 0x4923db
push 0x13bc
push str.for_get.c
push str.terminator_minus_one
call fcn.004d236a
mov dword [ebp - 0x54], edx
mov dword [ebp - 0x50], ecx
call fcn.0047f8a0
mov ecx, dword [ebp - 0x50]
mov edx, dword [ebp - 0x54]
cmp eax, 1
jg 0x4924fc
jmp 0x49239c
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
je 0x492d9d
mov eax, 0xffffffff
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x38], eax
jmp 0x492350
mov eax, dword [ebp - 0x3c]
jmp 0x492350
test byte [ebx + 0x1a5], 0x20
je 0x492dd5
movzx edx, byte [ebp - 0x26]
shl edx, 8
movzx esi, byte [ebp - 0x25]
movzx ecx, byte [ebp - 0x27]
or esi, edx
shl ecx, 0x10
movzx edx, byte [ebp - 0x28]
or esi, ecx
shl edx, 0x18
or esi, edx
mov dword [ebp - 0x28], esi
jmp 0x4927f2
movzx edx, byte [ebp - 0x27]
shl edx, 8
movzx esi, byte [ebp - 0x28]
movzx ecx, byte [ebp - 0x26]
or esi, edx
shl ecx, 0x10
movzx edx, byte [ebp - 0x25]
or esi, ecx
shl edx, 0x18
or esi, edx
mov dword [ebp - 0x28], esi
jmp 0x4927f2
and byte [ebx + 0x1ad], 0xfe
cmp dword [ebx + 0x124], 0xfffffffc
jne 0x492c5e
call fcn.0047f8a0
cmp eax, 1
jle 0x492c5e
mov eax, 0x30d
lea esp, [ebp - 0xc]
pop ebx
pop edi
pop esi
pop ebp
ret
and byte [ebx + 0x1ad], 0xfe
mov dword [ebx + 0x108], eax
cmp eax, 0x26
je 0x492c5e
cmp eax, 0x6d
jne 0x492e5a
push 0xfffffffffffffff6
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
cmp eax, dword [ebx + 0x104]
je 0x492c5e
mov eax, 0x27
lea esp, [ebp - 0xc]
pop ebx
pop edi
pop esi
pop ebp
ret
mov dword [ebp - 0x60], eax
push 0
call dword [sym.imp.KERNEL32.dll_Sleep]
mov eax, dword [ebp - 0x60]
jmp 0x4927d3
test byte [ebx + 0x1a5], 0x20
je 0x492ea7
movzx edx, byte [ebp - 0x22]
shl edx, 8
movzx eax, byte [ebp - 0x21]
movzx ecx, byte [ebp - 0x23]
or eax, edx
shl ecx, 0x10
movzx esi, byte [ebp - 0x24]
or eax, ecx
shl esi, 0x18
or eax, esi
jmp 0x492771
movzx edx, byte [ebp - 0x23]
shl edx, 8
movzx eax, byte [ebp - 0x24]
movzx ecx, byte [ebp - 0x22]
or eax, edx
shl ecx, 0x10
movzx esi, byte [ebp - 0x21]
or eax, ecx
shl esi, 0x18
or eax, esi
jmp 0x492771
and byte [ebx + 0x1ad], 0xfe
cmp dword [ebx + 0x124], 0xfffffffc
jne 0x492c5e
call fcn.0047f8a0
cmp eax, 1
jle 0x492c5e
mov eax, 0x30d
lea esp, [ebp - 0xc]
pop ebx
pop edi
pop esi
pop ebp
ret
and byte [ebx + 0x1ad], 0xfe
mov dword [ebx + 0x108], eax
cmp eax, 0x26
je 0x492c5e
cmp eax, 0x6d
jne 0x492f29
push 0xfffffffffffffff6
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
cmp eax, dword [ebx + 0x104]
je 0x492c5e
mov eax, 0x27
lea esp, [ebp - 0xc]
pop ebx
pop edi
pop esi
pop ebp
ret
mov dword [ebp - 0x5c], eax
push 0
call dword [sym.imp.KERNEL32.dll_Sleep]
mov eax, dword [ebp - 0x5c]
jmp 0x492752
mov dword [ebp - 0x14], edi
mov edx, 1
mov edi, dword [ebp - 0x20]
jmp 0x4920e9
and byte [ebx + 0x1ad], 0xfe
cmp dword [ebx + 0x124], 0xfffffffc
jne 0x492c5e
call fcn.0047f8a0
cmp eax, 1
jle 0x492c5e
mov eax, 0x30d
lea esp, [ebp - 0xc]
pop ebx
pop edi
pop esi
pop ebp
ret
and byte [ebx + 0x1ad], 0xfe
mov dword [ebx + 0x108], eax
cmp eax, 0x26
je 0x492c5e
cmp eax, 0x6d
jne 0x492fb7
push 0xfffffffffffffff6
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
cmp eax, dword [ebx + 0x104]
je 0x492c5e
mov eax, 0x27
lea esp, [ebp - 0xc]
pop ebx
pop edi
pop esi
pop ebp
ret
mov dword [ebp - 0x58], eax
push 0
call dword [sym.imp.KERNEL32.dll_Sleep]
mov eax, dword [ebp - 0x58]
jmp 0x4926d4
mov eax, dword [ebp + 0x10]
test eax, eax
je 0x4932ba
cmp dword [ebp - 0x58], 0
mov ecx, dword [ebx + 0x98]
mov eax, dword [ebx + 0x4c]
jne 0x492ff3
mov ecx, eax
mov edx, dword [ebx + 0x64]
mov dword [ebp - 0x60], ecx
cmp ecx, edx
je 0x493053
cmp dword [ebp - 0x48], 0
jbe 0x493042
cmp edx, dword [ebp - 0x60]
jb 0x493018
mov eax, ecx
mov ecx, dword [ebp - 0x48]
add eax, ecx
cmp eax, edx
ja 0x493022
cmp edx, dword [ebp - 0x60]
ja 0x493030
mov eax, dword [ebp - 0x48]
add eax, edx
cmp eax, dword [ebp - 0x60]
jbe 0x493030
push dword [ebp - 0x48]
push edx
push dword [ebp - 0x60]
call fcn.004cd870
jmp 0x49303c
push dword [ebp - 0x48]
push edx
push dword [ebp - 0x60]
call fcn.004c6aa0
add esp, 0xc
mov eax, dword [ebx + 0x4c]
cmp eax, dword [ebp - 0x60]
jne 0x493053
mov edx, dword [ebx + 0x64]
sub edx, dword [ebp - 0x60]
mov dword [ebx + 0x64], eax
sub dword [ebx + 0x58], edx
mov ecx, dword [ebx + 0x10c]
cmp ecx, dword [ebp - 0x38]
jae 0x4930f4
cmp dword [ebp - 0x54], 0
jne 0x493075
mov eax, 0x16
lea esp, [ebp - 0xc]
pop ebx
pop edi
pop esi
pop ebp
ret
mov edx, dword [ebp - 0x5c]
lea eax, [ebx + 0x4c]
push ecx
push eax
lea eax, [esi + edx + 0x14]
push eax
call fcn.00480f00
add esp, 0xc
test eax, eax
je 0x49309b
mov eax, 0x62
lea esp, [ebp - 0xc]
pop ebx
pop edi
pop esi
pop ebp
ret
mov eax, dword [ebp - 0x5c]
lea edx, [esi + eax + 4]
mov eax, dword [ebx + 0x4c]
mov dword [ebx + 0x118], edx
mov dword [ebx + 0x10c], edx
mov dword [edx + eax], 0x23332340
mov dword [ebp - 0x60], eax
mov edx, dword [ebx + 0x4c]
mov eax, dword [ebx + 0x10c]
mov dword [eax + edx + 4], 0x23372335
mov edx, dword [ebx + 0x4c]
mov eax, dword [ebx + 0x10c]
mov dword [eax + edx + 8], 0x23302339
mov edx, dword [ebx + 0x4c]
mov eax, dword [ebx + 0x10c]
mov dword [eax + edx + 0xc], 0x352333
mov ecx, dword [ebx + 0x10c]
mov eax, dword [ebx + 0xb0]
sub ecx, eax
mov edx, dword [ebp - 0x60]
add edx, eax
lea eax, [ebp - 0x1c]
mov dword [ebp - 0x60], edx
mov dword [esp + 0xc], eax
movzx eax, byte [ebx + 0x1a8]
and eax, 0x80
shr eax, 7
mov dword [esp + 0x10], eax
movzx eax, byte [ebx + 0x1a9]
and eax, 1
mov dword [esp + 0x14], eax
mov eax, dword [ebx + 0x16c]
mov dword [esp + 0x18], eax
mov eax, dword [ebx + 0x104]
mov dword [esp + 0x1c], ebx
call fcn.0049366c
mov dword [ebp - 0x5c], eax
mov eax, dword [ebp - 0x1c]
mov edx, dword [ebp - 0x60]
add dword [ebx + 0xb0], eax
mov dword [ebx + 0x50], edx
add edx, eax
mov eax, dword [ebx + 0x4c]
mov dword [ebx + 0x68], edx
mov dword [ebx + 0x64], eax
mov dword [ebx + 0x58], 0
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x3e3
je 0x4932a7
cmp dword [ebp - 0x5c], 0
jne 0x4931bc
and byte [ebx + 0x1ad], 0xfe
mov dword [ebx + 0x108], eax
cmp eax, 0x26
je 0x492c5e
cmp eax, 0x6d
jne 0x4931af
push 0xfffffffffffffff6
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
cmp eax, dword [ebx + 0x104]
je 0x492c5e
mov eax, 0x27
lea esp, [ebp - 0xc]
pop ebx
pop edi
pop esi
pop ebp
ret
cmp dword [ebp - 0x1c], 0
jne 0x4931df
and byte [ebx + 0x1ad], 0xfe
cmp dword [ebx + 0x124], 0xfffffffc
je 0x493247
mov eax, 0x18
lea esp, [ebp - 0xc]
pop ebx
pop edi
pop esi
pop ebp
ret
cmp dword [ebp - 0x58], 0
je 0x4931ec
or byte [ebx + 0x1a7], 0x40
mov eax, dword [ebx + 0xb0]
mov dword [ebp - 0x48], eax
cmp eax, dword [ebp - 0x38]
jb 0x492660
movzx edx, byte [ebx + 0x1ac]
mov dword [ebp - 0x4c], edx
and edx, 1
mov eax, dword [ebx + 0x64]
sub dword [ebp - 0x48], edi
lea ecx, [edi + eax]
mov dword [ebp - 0x18], ecx
mov dword [ebx + 0x50], ecx
cmp edx, 1
je 0x49325e
mov edx, dword [ebp - 0x38]
add eax, edx
neg edx
add edx, edi
sub edi, esi
add edx, dword [ebp - 0x48]
add edi, eax
mov dword [ebx + 0x64], eax
mov dword [ebx + 0xb0], edx
mov dword [ebx + 0x58], edi
or byte [ebx + 0x1a5], 2
jmp 0x492581
call fcn.0047f8a0
cmp eax, 1
jle 0x4931d2
mov eax, 0x30d
lea esp, [ebp - 0xc]
pop ebx
pop edi
pop esi
pop ebp
ret
mov edx, dword [ebp - 0x48]
mov dword [ebx + 0xb0], edx
test byte [ebp - 0x4c], 0x40
je 0x493297
cmp edx, dword [ebp - 0x38]
jb 0x493286
mov edi, edx
mov edx, dword [ebp - 0x38]
add edx, eax
mov dword [ebx + 0x64], edx
add edi, eax
mov dword [ebx + 0x58], edi
jmp 0x492581
mov edi, dword [ebx + 0x4c]
add edi, dword [ebx + 0x10c]
mov dword [ebx + 0x58], edi
jmp 0x492581
sub esi, edi
add eax, dword [ebp - 0x48]
lea edi, [esi + eax]
mov dword [ebx + 0x58], edi
jmp 0x492581
mov dword [ebp - 0x60], eax
push 0
call dword [sym.imp.KERNEL32.dll_Sleep]
mov eax, dword [ebp - 0x60]
jmp 0x49317a
mov eax, dword [ebp + 0xc]
cmp byte [eax], 1
jne 0x492fe2
mov dword [ebp - 0x20], edi
lea edx, [ebx + 0xb0]
mov dword [ebp - 0x60], edx
mov eax, dword [ebp - 0x48]
mov edi, dword [ebp - 0x38]
mov edx, 1
sub edi, eax
mov dword [esp + 4], edi
mov eax, dword [ebx + 0x104]
mov dword [esp + 8], 0
call fcn.0046c830
mov ecx, eax
mov eax, 0xffffffff
sub ecx, eax
sub edx, eax
or ecx, edx
je 0x4929b3
test byte [ebx + 0x1aa], 0x20
je 0x4933d2
movzx edi, byte [ebx + 0x1a8]
mov esi, dword [ebp - 0x60]
and edi, 0x80
mov edx, dword [ebx + 0x16c]
movzx eax, byte [ebx + 0x1a9]
mov dword [esp + 0xc], esi
and eax, 1
shr edi, 7
mov dword [esp + 0x10], edi
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], edx
mov dword [esp + 0x1c], ebx
mov eax, dword [ebx + 0x104]
mov edx, dword [ebx + 0x4c]
mov ecx, dword [ebp - 0x20]
call fcn.0049366c
mov eax, dword [ebx + 0xb0]
mov edi, dword [ebx + 0x4c]
mov dword [ebx + 0x50], edi
test byte [ebx + 0x1a5], 0x20
lea edx, [eax + edi]
mov dword [ebx + 0x68], edx
movzx edx, byte [edi]
movzx ecx, byte [edi + 1]
movzx esi, byte [edi + 2]
movzx edi, byte [edi + 3]
je 0x49339b
shl esi, 8
shl ecx, 0x10
or edi, esi
shl edx, 0x18
or edi, ecx
or edi, edx
jl 0x4933b8
jmp 0x4933ac
shl ecx, 8
shl esi, 0x10
or edx, ecx
shl edi, 0x18
or edx, esi
or edi, edx
jl 0x4933b8
movzx edx, byte [ebx + 0x1aa]
and edx, 0xffffffdf
jmp 0x4933c4
movzx edx, byte [ebx + 0x1aa]
neg edi
or edx, 0x20
mov byte [ebx + 0x1aa], dl
add edi, 8
jmp 0x4932d8
movzx eax, byte [ebx + 0x1a8]
mov edx, dword [ebp - 0x60]
and eax, 0x80
mov edi, dword [ebp - 0x20]
mov ecx, edi
mov dword [esp + 0xc], edx
shr eax, 7
mov dword [esp + 0x10], eax
movzx eax, byte [ebx + 0x1a9]
and eax, 1
mov dword [esp + 0x14], eax
mov eax, dword [ebx + 0x16c]
mov dword [esp + 0x18], eax
mov eax, dword [ebx + 0x104]
mov edx, dword [ebx + 0x4c]
mov dword [esp + 0x1c], ebx
call fcn.0049366c
mov edx, dword [ebx + 0x4c]
mov eax, dword [ebx + 0xb0]
mov dword [ebx + 0x64], edx
add eax, edx
add edx, edi
mov dword [ebx + 0x68], eax
mov dword [ebp - 0x18], edx
mov dword [ebx + 0x50], edx
or byte [ebx + 0x1a5], 2
mov edi, dword [ebx + 0x58]
jmp 0x492581
mov eax, dword [ebp + 0xc]
cmp byte [eax + 2], 1
jne 0x491fd2
mov eax, dword [ebx + 0x50]
mov edi, dword [ebx + 0x58]
or byte [ebx + 0x1a7], 0x20
mov dword [ebp - 0x18], eax
jmp 0x492581
mov edx, dword [ebp + 0xc]
cmp byte [edx + 2], 1
jne 0x491fd2
mov edx, dword [ebp + 0x10]
cmp eax, dword [edx]
ja 0x491fd2
mov eax, dword [ebx + 0x50]
mov edi, dword [ebx + 0x58]
or byte [ebx + 0x1a7], 0x20
mov dword [ebp - 0x18], eax
jmp 0x492581
cmp dword [ebp - 0x50], 0
jne 0x491fdc
jmp 0x492fe2
cmp dword [ebp - 0x48], 0
jbe 0x4934e5
mov eax, dword [ebx + 0x64]
mov edx, dword [ebx + 0x4c]
cmp edx, eax
ja 0x4934be
mov ecx, dword [ebp - 0x48]
add ecx, edx
cmp ecx, eax
ja 0x4934c7
cmp edx, eax
jb 0x4934d6
mov ecx, dword [ebp - 0x48]
add ecx, eax
cmp edx, ecx
jae 0x4934d6
push dword [ebp - 0x48]
push eax
push edx
call fcn.004cd870
add esp, 0xc
jmp 0x493509
push dword [ebp - 0x48]
push eax
push edx
call fcn.004c6aa0
add esp, 0xc
jmp 0x493509
movzx eax, byte [ebx + 0x1ac]
test al, 0x40
je 0x493502
and eax, 0x7f
mov byte [ebx + 0x1ac], al
mov dword [ebp - 0x48], 0
jmp 0x493509
mov dword [ebp - 0x48], 0
mov edx, dword [ebx + 0x4c]
mov eax, dword [ebp - 0x48]
add edx, eax
mov ecx, dword [ebx + 0x10c]
mov dword [ebp - 0x58], 0
sub ecx, eax
lea eax, [ebp - 0x1c]
mov dword [esp + 0xc], eax
movzx eax, byte [ebx + 0x1a8]
and eax, 0x80
shr eax, 7
mov dword [esp + 0x10], eax
movzx eax, byte [ebx + 0x1a9]
and eax, 1
mov dword [esp + 0x14], eax
mov eax, dword [ebx + 0x16c]
mov dword [esp + 0x18], eax
mov eax, dword [ebx + 0x104]
mov dword [esp + 0x1c], ebx
call fcn.0049366c
mov dword [ebp - 0x60], eax
mov edx, dword [ebp - 0x48]
add edx, dword [ebp - 0x1c]
mov ecx, dword [ebx + 0x4c]
mov dword [ebx + 0xb0], edx
mov dword [ebx + 0x64], ecx
mov dword [ebx + 0x50], ecx
lea eax, [ecx + edx]
add edx, ecx
mov dword [ebx + 0x68], eax
mov dword [ebx + 0x58], edx
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x5c], eax
cmp dword [ebp - 0x5c], 0x3e3
je 0x493623
cmp dword [ebp - 0x60], 0
je 0x4935e3
cmp dword [ebp - 0x1c], 0
je 0x4935b4
mov eax, dword [ebx + 0xb0]
mov dword [ebp - 0x48], eax
jmp 0x491e0c
and byte [ebx + 0x1ad], 0xfe
cmp dword [ebx + 0x124], 0xfffffffc
jne 0x492c5e
call fcn.0047f8a0
cmp eax, 1
jle 0x492c5e
mov eax, 0x30d
lea esp, [ebp - 0xc]
pop ebx
pop edi
pop esi
pop ebp
ret
mov eax, dword [ebp - 0x5c]
and byte [ebx + 0x1ad], 0xfe
mov dword [ebx + 0x108], eax
cmp eax, 0x26
je 0x492c5e
cmp dword [ebp - 0x5c], 0x6d
jne 0x493616
push 0xfffffffffffffff6
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
cmp eax, dword [ebx + 0x104]
je 0x492c5e
mov eax, 0x27
lea esp, [ebp - 0xc]
pop ebx
pop edi
pop esi
pop ebp
ret
push 0
call dword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x49359a
call fcn.0047f8a0
cmp eax, 1
jle 0x4912b9
mov eax, 0x30d
lea esp, [ebp - 0xc]
pop ebx
pop edi
pop esi
pop ebp
ret
mov eax, 0x43
lea esp, [ebp - 0xc]
pop ebx
pop edi
pop esi
pop ebp
ret