Function at 0x40d130
Capabilities:
Get file size

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x427e6e
mov eax, dword fs:[0]
push eax
sub esp, 0x2d8
mov eax, dword [0x438070]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov dword [ebp - 0x2a8], edi
mov eax, dword [ebp + 8]
mov dword [ebp - 0x2ac], eax
push 0
push 0x80
push 3
push 0
mov dword [ebp - 4], 0
lea eax, [ebp + 0xc]
cmp dword [ebp + 0x20], 8
push 5
cmovae eax, dword [ebp + 0xc]
push 0x120089
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
cmp esi, 0xffffffff
je 0x40d551
lea eax, [ebp - 0x2bc]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x40d54a
cmp dword [ebp - 0x2b8], 0
jg 0x40d54a
jl 0x40d1da
cmp dword [ebp - 0x2bc], 0x2000000
ja 0x40d54a
push 0x100
mov dword [ebp - 0x298], 0x100
call fcn.0040feb7
mov ebx, eax
add esp, 4
mov dword [ebp - 0x2b0], ebx
push 0
push ebx
lea eax, [ebp - 0x298]
mov byte [ebp - 4], 1
push eax
mov eax, dword [edi + 0xc]
push esi
call eax
test eax, eax
jne 0x40d25d
push dword [ebp - 0x298]
call fcn.0040feb7
mov ecx, ebx
add esp, 4
mov ebx, eax
mov dword [ebp - 0x2b0], ebx
test ecx, ecx
je 0x40d238
push ecx
call fcn.0040f9e5
add esp, 4
mov eax, ebx
push 0
push eax
lea eax, [ebp - 0x298]
push eax
mov eax, dword [edi + 0xc]
push esi
call eax
test eax, eax
jne 0x40d25d
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edi, 1
jmp 0x40d53b
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0
lea eax, [ebp - 0x6c]
mov dword [ebp - 0x2a0], 0x800b0100
push eax
lea eax, [ebp - 0x29c]
mov dword [ebp - 0x29c], 0
push eax
mov eax, dword [edi + 0x10]
mov dword [ebp - 0x6c], 0xf750e6c3
mov dword [ebp - 0x68], 0x11d138ee
mov dword [ebp - 0x64], 0xc000e585
mov dword [ebp - 0x60], 0xee95c24f
call eax
test eax, eax
jne 0x40d2b2
lea edi, [eax + 1]
jmp 0x40d53b
mov eax, dword [ebp - 0x298]
xor ecx, ecx
mov edx, 2
lea eax, [eax*2 + 1]
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0040feb7
add esp, 4
mov dword [ebp - 0x2a4], eax
mov byte [ebp - 4], 2
lea edi, [ebp - 0x5c]
mov ecx, 0x11
mov esi, str.0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ_________._:_________
rep movsd dword es:[edi], dword [esi]
mov ecx, dword [ebp - 0x298]
xor edx, edx
movsw word es:[edi], word [esi]
test ecx, ecx
je 0x40d32c
nop
movzx ecx, byte [edx + ebx]
shr ecx, 4
movsx ecx, byte [ebp + ecx - 0x5c]
mov word [eax + edx*4], cx
movzx ecx, byte [edx + ebx]
and ecx, 0xf
movsx ecx, byte [ebp + ecx - 0x5c]
mov word [eax + edx*4 + 2], cx
inc edx
mov ecx, dword [ebp - 0x298]
cmp edx, ecx
jb 0x40d300
mov edi, dword [ebp - 0x2a8]
xor edx, edx
push edx
push edx
mov word [eax + ecx*4], dx
push dword [ebp - 0x298]
mov eax, dword [edi + 0x14]
push ebx
push dword [ebp - 0x29c]
call eax
mov esi, eax
mov dword [ebp - 0x2a8], esi
test esi, esi
je 0x40d50e
push 0x20c
lea eax, [ebp - 0x294]
push 0
push eax
call fcn.00412b70
add esp, 0xc
lea eax, [ebp - 0x294]
push 0
push eax
mov eax, dword [edi + 0x18]
push esi
call eax
mov esi, dword [ebp - 0x2a4]
test eax, eax
je 0x40d4f9
xor eax, eax
mov dword [ebp - 0x2e0], 0x24
cmp dword [ebp + 0x20], 8
mov dword [ebp - 0x2dc], eax
mov dword [ebp - 0x2cc], eax
mov dword [ebp - 0x2c8], eax
mov dword [ebp - 0x2c4], eax
mov dword [ebp - 0x2c0], eax
lea eax, [ebp - 0x290]
mov dword [ebp - 0x2d8], eax
lea eax, [ebp + 0xc]
cmovae eax, dword [ebp + 0xc]
push 0x2c
mov dword [ebp - 0x2d0], eax
lea eax, [ebp - 0x44]
push 0
push eax
mov dword [ebp - 0x2d4], esi
call fcn.00412b70
add esp, 0xc
mov dword [ebp - 0x48], 0x30
lea eax, [ebp - 0x2e0]
mov dword [ebp - 0x3c], 2
mov dword [ebp - 0x38], 1
mov dword [ebp - 0x34], 2
mov dword [ebp - 0x2c], 1
mov dword [ebp - 0x30], eax
call fcn.00406880
cmp eax, 3
jl 0x40d42b
or dword [ebp - 0x20], 0x1000
jmp 0x40d42f
or dword [ebp - 0x20], 0x10
lea eax, [ebp - 0x48]
push eax
lea eax, [ebp - 0x6c]
push eax
mov eax, dword [edi + 0x2c]
push 0
call eax
mov ecx, dword [ebp - 0x2ac]
mov dword [ebp - 0x2a0], eax
test ecx, ecx
je 0x40d4e3
cmp eax, 0x800b0100
je 0x40d4d7
push dword [ebp - 0x28]
lea eax, [ebp - 0x84]
mov ecx, edi
push eax
call fcn.0040cbf0
mov ecx, dword [ebp - 0x2ac]
push eax
call fcn.00409bb0
mov eax, dword [ebp - 0x70]
cmp eax, 8
jb 0x40d4e3
mov ecx, dword [ebp - 0x84]
inc eax
cmp eax, 0x7fffffff
jbe 0x40d495
call fcn.00418f5c
add eax, eax
cmp eax, 0x1000
jb 0x40d4cc
test cl, 0x1f
je 0x40d4a8
call fcn.00418f5c
mov eax, dword [ecx - 4]
cmp eax, ecx
jb 0x40d4b4
call fcn.00418f5c
sub ecx, eax
cmp ecx, 4
jae 0x40d4c0
call fcn.00418f5c
cmp ecx, 0x23
jbe 0x40d4ca
call fcn.00418f5c
mov ecx, eax
push ecx
call fcn.0040fea4
add esp, 4
jmp 0x40d4e3
push 0
push 0x434940
call fcn.00403fd7
lea eax, [ebp - 0x48]
mov dword [ebp - 0x2c], 2
push eax
lea eax, [ebp - 0x6c]
push eax
mov eax, dword [edi + 0x2c]
push 0
call eax
mov eax, dword [edi + 0x1c]
push 0
push dword [ebp - 0x2a8]
push dword [ebp - 0x29c]
call eax
jmp 0x40d514
mov esi, dword [ebp - 0x2a4]
mov eax, dword [edi + 0x20]
push 0
push dword [ebp - 0x29c]
call eax
mov ecx, dword [ebp - 0x2a0]
call fcn.0040c550
mov edi, eax
test esi, esi
je 0x40d53b
push esi
call fcn.0040f9e5
add esp, 4
test ebx, ebx
je 0x40d556
push ebx
call fcn.0040f9e5
add esp, 4
jmp 0x40d556
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edi, 1
mov eax, dword [ebp + 0x20]
cmp eax, 8
jb 0x40d5ae
mov ecx, dword [ebp + 0xc]
inc eax
cmp eax, 0x7fffffff
jbe 0x40d56e
call fcn.00418f5c
add eax, eax
cmp eax, 0x1000
jb 0x40d5a5
test cl, 0x1f
je 0x40d581
call fcn.00418f5c
mov eax, dword [ecx - 4]
cmp eax, ecx
jb 0x40d58d
call fcn.00418f5c
sub ecx, eax
cmp ecx, 4
jae 0x40d599
call fcn.00418f5c
cmp ecx, 0x23
jbe 0x40d5a3
call fcn.00418f5c
mov ecx, eax
push ecx
call fcn.0040fea4
add esp, 4
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.0040f9d4
mov esp, ebp
pop ebp
ret 0x1c