Function at 0x40a470
Capabilities:
Get file size

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2c
mov eax, dword [0x43a004]
xor eax, ebp
mov dword [ebp - 4], eax
test dword [0x43c4c0], 0x80000000
push ebx
push esi
mov bx, cx
push edi
mov word [ebp - 0x26], bx
je 0x40af96
cmp dword [0x43bd04], 0
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x1c], edi
jne 0x40a4cd
mov edx, dword [0x43c184]
mov ecx, 0x43bd04
push 0x800000e6
call fcn.00417780
test eax, eax
je 0x40a4fd
or word [0x43ac6a], 1
push 0x47c
call fcn.0041d6de
mov edi, eax
add esp, 4
test edi, edi
jne 0x40a538
movzx eax, word [0x43ad06]
sub eax, 7
je 0x40a50c
sub eax, 2
je 0x40a505
sub eax, 1
jne 0x40a505
mov eax, dword [str.El_sistema_no_puede_asignar_suficiente_memoria]
jmp 0x40a511
mov ebx, dword [ebp - 0x20]
jmp 0x40af38
mov eax, dword [str.The_system_cannot_allocate_enough_memory]
jmp 0x40a511
mov eax, dword [str.Der_Speicher_reicht_nicht]
push eax
push 0xa8010f00
call fcn.00413190
add esp, 8
push 0xe
call dword [sym.imp.KERNEL32.dll_SetLastError]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004194d8
mov esp, ebp
pop ebp
ret
push 0x47c
push 0
push edi
call fcn.0041b050
lea eax, [edi + 0x27c]
mov dword [edi + 0xc], 0xffffffff
mov dword [edi + 0x24], eax
add esp, 0xc
movzx eax, bx
mov dword [edi], eax
sub eax, 0x9c6a
je 0x40a580
sub eax, 1
je 0x40a579
sub eax, 1
jne 0x40af96
mov eax, 0x43a9d0
jmp 0x40a585
mov eax, 0x43a9ec
jmp 0x40a585
mov eax, 0x43a9b4
mov dword [edi + 4], eax
mov ebx, dword [0x43c4c0]
mov esi, dword [0x43c4d8]
mov edx, dword [0x43c4d0]
test ebx, ebx
js 0x40a5a5
mov ecx, 1
jmp 0x40a5bf
mov eax, dword [esi + edx*4]
movzx ecx, byte [eax + 0xf]
shr ecx, 4
and ecx, 1
test bl, bl
js 0x40a5bf
mov eax, 1
sub eax, ecx
mov ecx, eax
mov dword [edi + 0x24c], ecx
test bl, bl
js 0x40a5d5
mov eax, dword [esi + edx*4]
cmp dword [eax + 0x1c], 0
jge 0x40a5d5
mov edx, dword [eax + 0x18]
test edx, edx
jle 0x40a5e5
mov eax, dword [esi + edx*4]
test byte [eax + 0xf], 8
je 0x40a5e5
mov edx, dword [eax + 0x18]
lea eax, [edi + 0x238]
mov dword [edi + 0x248], edx
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemTime]
mov esi, dword [edi + 4]
mov ecx, dword [esi + 8]
test ecx, ecx
je 0x40a662
cmp dword [esi + 0xc], 0
je 0x40a662
mov edx, 4
call fcn.00411510
mov edx, dword [esi + 8]
mov ecx, dword [0x43bd04]
mov dword [ebp - 0x24], eax
call fcn.004118d0
mov edx, dword [ebp - 0x24]
mov ebx, eax
push ecx
push 0x2d
push dword [esi + 0xc]
mov ecx, ebx
call fcn.004125f0
mov dword [ebp - 8], eax
mov eax, dword [ebp - 0x24]
test eax, eax
je 0x40a648
push eax
call fcn.0041d6c3
add esp, 4
test ebx, ebx
je 0x40a655
push ebx
call fcn.0041d6c3
add esp, 4
cmp dword [ebp - 8], 0
jne 0x40a662
mov ebx, edi
jmp 0x40af35
mov ecx, dword [esi + 0x10]
test ecx, ecx
je 0x40a6c3
mov edx, 4
call fcn.00411510
mov edx, dword [esi + 0x10]
mov ecx, dword [0x43bd04]
mov dword [ebp - 8], eax
call fcn.004118d0
push ecx
push dword [esi + 0x18]
mov ebx, eax
push dword [esi + 0x14]
mov esi, dword [ebp - 8]
mov ecx, ebx
mov edx, esi
call fcn.004125f0
mov dword [ebp - 8], eax
test esi, esi
je 0x40a6a9
push esi
call fcn.0041d6c3
add esp, 4
test ebx, ebx
je 0x40a6b6
push ebx
call fcn.0041d6c3
add esp, 4
cmp dword [ebp - 8], 0
jne 0x40a6c3
mov ebx, edi
jmp 0x40af35
mov ecx, dword [edi + 4]
xor ebx, ebx
mov ecx, dword [ecx + 4]
lea edx, [ebx + 4]
call fcn.00411510
mov ecx, eax
mov dword [ebp - 0x2c], eax
call fcn.00411bc0
mov esi, eax
cmp esi, 0xffffffff
je 0x40a7ca
lea eax, [ebp - 8]
mov dword [ebp - 8], ebx
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [ebp - 0x20], eax
cmp eax, 0xffffffff
jne 0x40a717
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
je 0x40a712
mov ecx, 0xe0010010
jmp 0x40a7bf
mov eax, dword [ebp - 0x20]
jmp 0x40a720
cmp dword [ebp - 8], ebx
jne 0x40a7ba
add eax, 2
cmp eax, 1
jae 0x40a72f
xor ebx, ebx
jmp 0x40a7ca
push eax
call fcn.0041d6de
mov ebx, eax
add esp, 4
mov dword [ebp - 0x24], ebx
test ebx, ebx
jne 0x40a785
movzx eax, word [0x43ad06]
sub eax, 7
je 0x40a765
sub eax, 2
je 0x40a757
sub eax, 1
je 0x40a75e
mov eax, dword [str.The_system_cannot_allocate_enough_memory]
jmp 0x40a76a
mov eax, dword [str.El_sistema_no_puede_asignar_suficiente_memoria]
jmp 0x40a76a
mov eax, dword [str.Der_Speicher_reicht_nicht]
push eax
push 0xa8010f00
call fcn.00413190
add esp, 8
push 0xe
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov ebx, dword [ebp - 0x24]
jmp 0x40a7ca
push 0x20010010
lea eax, [ebp - 0x20]
mov dword [ebp - 0x24], ebx
push eax
push dword [ebp - 0x20]
mov edx, ebx
mov ecx, esi
call fcn.00412150
add esp, 0xc
test eax, eax
je 0x40a7ad
mov eax, dword [ebp - 0x20]
mov byte [ebx + eax], 0
jmp 0x40a7ca
push ebx
call fcn.0041d6c3
add esp, 4
xor ebx, ebx
jmp 0x40a7ca
mov ecx, 0xa001001f
push esi
xor edx, edx
call fcn.00411f50
add esp, 4
mov eax, dword [ebp - 0x2c]
test eax, eax
je 0x40a7da
push eax
call fcn.0041d6c3
add esp, 4
cmp esi, 0xffffffff
je 0x40a7f4
push esi
call dword [ebp - 0x1c]
test eax, eax
jne 0x40a7f4
push esi
xor edx, edx
xor ecx, ecx
call fcn.00411f50
add esp, 4
mov dword [edi + 0x18], ebx
mov dword [ebp - 0x20], edi
test ebx, ebx
je 0x40af32
mov eax, 0x9c6a
mov dword [edi + 0x1c], ebx
cmp word [ebp - 0x26], ax
jne 0x40a82b
mov eax, dword [edi + 4]
push dword [0x43a984]
push dword [eax]
push 0x43bee0
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0xc
jmp 0x40a879
lea eax, [ebp - 0x18]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemTime]
movzx eax, word [ebp - 0xc]
push eax
movzx eax, word [ebp - 0xe]
mov esi, dword [sym.imp.USER32.dll_wsprintfW]
push eax
movzx eax, word [ebp - 0x10]
push eax
movzx eax, word [ebp - 0x12]
push eax
movzx eax, word [ebp - 0x16]
push eax
movzx eax, word [ebp - 0x18]
push eax
push str._.4u__.2u__.2u__.2u_.2u_.2u
push 0x43c540
call esi
mov eax, dword [edi + 4]
push 0x43c540
push dword [eax]
push 0x43bee0
call esi
add esp, 0x2c
mov esi, dword [0x43bd04]
mov ebx, 0x43bee0
test esi, esi
je 0x40a8d0
mov edx, esi
lea ecx, [edx + 2]
nop dword [eax]
mov ax, word [edx]
add edx, 2
test ax, ax
jne 0x40a890
sub edx, ecx
sar edx, 1
je 0x40a8d0
xor eax, eax
mov ecx, 0x437434
cmp word [esi + edx*2 - 2], 0x5c
cmove ecx, eax
cmp word [0x43bee0], 0x5c
mov eax, 0x43bee2
cmovne eax, ebx
push eax
push esi
push ecx
call fcn.00414380
add esp, 0xc
mov esi, eax
jmp 0x40a8d2
xor esi, esi
mov ecx, dword [0x43bd20]
mov ebx, dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov dword [edi + 8], esi
test ecx, ecx
je 0x40a8f6
call ebx
mov ecx, dword [0x43bd20]
cmp ecx, eax
mov eax, dword [0x43acbc]
je 0x40a8fb
mov eax, dword [0x43ac6c]
mov dword [ebp - 8], eax
test ecx, ecx
je 0x40a911
call ebx
cmp dword [0x43bd20], eax
mov eax, 0x43acbc
je 0x40a916
mov eax, 0x43ac6c
or dword [eax], 0x200000
xor edx, edx
lea eax, [ebp - 0x2c]
mov ecx, esi
push eax
call fcn.00411a30
mov esi, eax
cmp esi, 1
jb 0x40a939
push dword [ebp - 0x2c]
call dword [sym.imp.KERNEL32.dll_FindClose]
cmp dword [0x43bd20], 0
je 0x40a951
call ebx
cmp dword [0x43bd20], eax
mov eax, 0x43acbc
je 0x40a956
mov eax, 0x43ac6c
mov ecx, dword [ebp - 8]
mov ebx, edi
mov dword [eax], ecx
cmp esi, 0xffffffff
je 0x40af35
cmp esi, 1
je 0x40a976
cmp esi, 2
je 0x40af35
jmp 0x40a98f
push dword [edi + 8]
push 0x20010012
call fcn.00413190
add esp, 8
cmp eax, 6
jne 0x40af35
mov eax, 0x9c6c
cmp word [ebp - 0x26], ax
jne 0x40a9bb
push 0
push 0
mov edx, str.eBookImages
call fcn.00401970
add esp, 8
mov dword [edi + 0x254], eax
mov ebx, edi
test eax, eax
js 0x40af35
push 0
push ecx
mov ecx, dword [edi + 8]
mov edx, 2
push 0
push 0
call fcn.00411d20
mov dword [edi + 0xc], eax
mov ebx, edi
cmp eax, 0xffffffff
je 0x40af35
inc dword [0x43a984]
or word [0x43ac6a], 1
mov dword [ebp - 0x20], edi
nop
mov ebx, dword [edi + 0xc]
mov dword [ebp - 0x28], ebx
push str._INPUT_
push dword [edi + 0x1c]
call fcn.0041a3d0
add esp, 8
mov dword [ebp - 0x2c], eax
test eax, eax
je 0x40aa51
lea ebx, [eax + 7]
push 0x23
push ebx
call fcn.0041a640
add esp, 8
mov dword [ebp - 8], eax
test eax, eax
je 0x40aa4e
mov byte [eax], 0
mov esi, 0x50
nop word [eax + eax]
mov eax, dword [esi*4 + 0x43aa04]
dec esi
test eax, eax
je 0x40aa4a
push ebx
push eax
call fcn.0041d722
add esp, 8
test eax, eax
je 0x40aa63
test esi, esi
jne 0x40aa30
mov ebx, dword [ebp - 0x28]
mov edx, dword [edi + 0x1c]
test edx, edx
jne 0x40aeb1
xor ecx, ecx
jmp 0x40aebf
cmp esi, 0xffffffff
je 0x40aa4e
mov eax, dword [ebp - 0x2c]
mov byte [eax], 0
mov edx, dword [edi + 0x1c]
test edx, edx
jne 0x40aa79
xor ecx, ecx
jmp 0x40aa89
mov ecx, edx
lea ebx, [ecx + 1]
nop
mov al, byte [ecx]
inc ecx
test al, al
jne 0x40aa80
sub ecx, ebx
push 0x20010016
push 0
push ecx
mov ecx, dword [ebp - 0x28]
call fcn.00412150
add esp, 0xc
test eax, eax
je 0x40aed1
mov eax, dword [ebp - 8]
inc eax
mov dword [edi + 0x1c], eax
lea eax, [esi + 1]
mov ecx, dword [edi + 0x24]
mov dword [edi + 0x258], esi
mov dword [edi + 0x28], ecx
mov dword [edi + 0x2c], 0
cmp eax, 0x10
ja case.default.0x40aaca
jmp dword [eax*4 + 0x40afa8]
mov eax, dword [0x43c4a4]
jmp 0x40adf7
mov eax, dword [0x43c4a8]
jmp 0x40adf7
mov eax, dword [0x43c494]
jmp 0x40adf7
mov eax, dword [0x43c49c]
jmp 0x40adf7
mov edx, dword [edi + 0x248]
call fcn.004091d0
jmp 0x40adfa
mov eax, dword [0x43a984]
dec eax
push eax
push 0x436764
push ecx
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
jmp 0x40adfa
mov eax, dword [0x43c194]
jmp 0x40adf7
mov eax, dword [0x43c18c]
jmp 0x40adf7
movzx eax, word [edi + 0x242]
push eax
movzx eax, word [edi + 0x240]
push eax
movzx eax, word [edi + 0x23e]
push eax
movzx eax, word [edi + 0x23a]
push eax
movzx eax, word [edi + 0x238]
push eax
push str._.4u__.2u__.2uT_.2u:_.2u
push ecx
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x1c
jmp 0x40adfa
cmp dword [edi + 0x24c], 0
mov eax, 0x436f78
mov ecx, 0x436f7c
cmovne eax, ecx
jmp 0x40ae7c
mov eax, dword [edi + 0x24c]
mov eax, dword [eax*4 + 0x43c110]
jmp 0x40adf7
mov eax, dword [0x43c190]
jmp 0x40adf7
mov ecx, edi
call fcn.0040a2e0
jmp 0x40a9f0
mov edx, dword [edi + 0x248]
xor ecx, ecx
test edx, edx
mov dword [edi + 0x25c], 0
cmovns ecx, edx
cmp edx, dword [0x43c4d4]
jge 0x40ac02
mov esi, dword [0x43c4d8]
cmp ecx, edx
jge 0x40abee
nop
mov eax, dword [esi + ecx*4]
test byte [eax + 0xf], 2
jne 0x40ac02
inc ecx
cmp ecx, edx
jl 0x40abe0
mov eax, dword [esi + ecx*4]
mov eax, dword [eax + 0x28]
mov dword [edi + 0x25c], eax
mov ecx, dword [esi + ecx*4]
call fcn.00411050
mov ecx, dword [edi + 0x25c]
call fcn.004142e0
mov ebx, eax
mov dword [edi + 0x26c], ebx
test ebx, ebx
je 0x40ac48
xor esi, esi
cmp dword [0x43bd0c], esi
jbe 0x40ac48
mov eax, dword [0x43bd08]
push dword [eax + esi*4]
push ebx
call fcn.0041a159
add esp, 8
test eax, eax
jne 0x40ac43
inc esi
cmp esi, dword [0x43bd0c]
jb 0x40ac23
jmp 0x40ac48
xor ecx, ecx
mov word [eax], cx
mov eax, dword [0x43c188]
lea ecx, [edi + 0x260]
mov dword [edi + 0x268], eax
mov edx, 0x39d
mov byte [edi + 0x270], 1
movzx eax, byte [ecx + 0x10]
sub eax, 1
je 0x40ac75
sub eax, 1
je 0x40ac7a
jmp 0x40ac8b
mov edx, 0x39e
push ecx
mov ecx, dword [0x43ad10]
push 0x417230
call fcn.004156b0
mov eax, dword [edi + 0x26c]
test eax, eax
je 0x40aca8
push eax
call fcn.0041d6c3
add esp, 4
mov dword [edi + 0x26c], 0
mov edx, dword [edi + 0x278]
lea ebx, [edi + 0x278]
test edx, edx
je 0x40a9f0
mov ecx, edx
lea esi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x40acc1
sub ecx, esi
sar ecx, 1
lea eax, [edx + ecx*2]
cmp eax, edx
je 0x40ace9
sub eax, 2
cmp word [eax], 0x20
ja 0x40ace9
xor ecx, ecx
mov word [eax], cx
cmp eax, edx
jne 0x40acd7
mov ecx, dword [ebx]
call fcn.004142e0
mov dword [ebp - 0x24], eax
xor esi, esi
nop word [eax + eax]
push dword [esi + 0x4365a0]
mov edx, dword [esi + 0x4365b0]
lea ecx, [ebp - 0x24]
call fcn.00414550
cmp eax, 0xffffffff
je 0x40ad3b
add esi, 4
cmp esi, 0x10
jl 0x40ad00
mov esi, dword [ebp - 0x24]
test esi, esi
je 0x40ad4b
mov eax, dword [ebx]
test eax, eax
je 0x40ad37
push eax
call fcn.0041d6c3
add esp, 4
mov dword [ebx], esi
jmp 0x40ad4b
mov eax, dword [ebp - 0x24]
test eax, eax
je 0x40ad4b
push eax
call fcn.0041d6c3
add esp, 4
push 0x436f80
mov edx, 0x436320
mov ecx, ebx
call fcn.00414550
push 0x436f80
mov edx, 0x436f90
mov ecx, ebx
call fcn.00414550
mov ebx, dword [edi + 0xc]
push 0
push 0xfde9
push dword [edi + 0x278]
call fcn.00416da0
mov esi, eax
test esi, esi
je 0x40adb6
mov edx, esi
lea ecx, [edx + 1]
nop dword [eax]
mov al, byte [edx]
inc edx
test al, al
jne 0x40ad90
sub edx, ecx
mov ecx, ebx
push 0x20010016
push 0
push edx
mov edx, esi
call fcn.00412150
add esp, 0xc
push esi
call fcn.0041d6c3
add esp, 4
mov eax, dword [edi + 0x278]
test eax, eax
je 0x40a9f0
push eax
call fcn.0041d6c3
add esp, 4
mov dword [edi + 0x278], 0
jmp 0x40a9f0
mov dword [edi + 0x2c], 0x43c540
mov eax, 0x43c540
jmp 0x40ae05
mov eax, dword [edi + 0x254]
mov eax, dword [eax*4 + 0x43a930]
mov dword [edi + 0x2c], eax
mov eax, dword [edi + 0x2c]
test eax, eax
je 0x40ae7f
cmp word [eax], 0
je 0x40a9f0
mov ebx, dword [edi + 0xc]
push 0
push 0xfde9
push eax
call fcn.00416da0
mov esi, eax
test esi, esi
je 0x40a9f0
mov edx, esi
lea ecx, [edx + 1]
nop
mov al, byte [edx]
inc edx
test al, al
jne 0x40ae30
sub edx, ecx
mov ecx, ebx
push 0x20010016
push 0
push edx
mov edx, esi
call fcn.00412150
add esp, 0xc
push esi
call fcn.0041d6c3
add esp, 4
jmp 0x40a9f0
mov eax, dword [esi*4 + 0x43aa08]
movzx ecx, byte [eax + 1]
movzx eax, byte [eax]
shl ecx, 3
sub eax, ecx
movzx eax, byte [eax + 0x43c59f]
mov eax, dword [eax*4 + 0x4363cc]
mov dword [edi + 0x28], eax
mov edx, dword [edi + 0x28]
test edx, edx
jne 0x40ae8a
xor ecx, ecx
jmp 0x40ae99
mov ecx, edx
lea esi, [ecx + 1]
nop
mov al, byte [ecx]
inc ecx
test al, al
jne 0x40ae90
sub ecx, esi
push 0x20010016
push 0
push ecx
mov ecx, dword [edi + 0xc]
call fcn.00412150
add esp, 0xc
jmp 0x40a9f0
mov ecx, edx
lea esi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x40aeb6
sub ecx, esi
push 0x20010016
push 0
push ecx
mov ecx, ebx
call fcn.00412150
add esp, 0xc
mov eax, dword [edi + 0x24]
mov dword [edi + 0x2c], 0
mov dword [edi + 0x28], eax
mov dword [edi + 0x258], 0xffffffff
mov esi, dword [edi + 0xc]
cmp esi, 0xffffffff
je 0x40af0c
push esi
call dword [ebp - 0x1c]
test eax, eax
jne 0x40af05
push esi
xor edx, edx
xor ecx, ecx
call fcn.00411f50
add esp, 4
mov dword [edi + 0xc], 0xffffffff
test byte [0x43a95c], 0x20
je 0x40af22
push ecx
mov ecx, dword [edi + 8]
call fcn.004148e0
test eax, eax
jne 0x40af32
push dword [edi + 8]
push 0x200f000c
call fcn.00413190
add esp, 8
mov ebx, dword [ebp - 0x20]
mov edi, dword [ebp - 0x1c]
mov eax, dword [ebx + 0x18]
test eax, eax
je 0x40af4f
push eax
call fcn.0041d6c3
add esp, 4
mov dword [ebx + 0x18], 0
mov eax, dword [ebx + 8]
test eax, eax
je 0x40af66
push eax
call fcn.0041d6c3
add esp, 4
mov dword [ebx + 8], 0
mov esi, dword [ebx + 0xc]
cmp esi, 0xffffffff
je 0x40af89
push esi
call edi
test eax, eax
jne 0x40af82
push esi
xor edx, edx
xor ecx, ecx
call fcn.00411f50
add esp, 4
mov dword [ebx + 0xc], 0xffffffff
test ebx, ebx
je 0x40af96
push ebx
call fcn.0041d6c3
add esp, 4
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004194d8
mov esp, ebp
pop ebp
ret