Function at 0x40ad90
Capabilities:
Get file size

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5ab188
mov eax, dword fs:[0]
push eax
mov eax, 0x1024
call fcn.0053f090
mov eax, dword [0x677e70]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov ebx, dword [ebp + 8]
mov ecx, dword [ebp + 0xc]
mov edx, dword [ebp + 0x18]
mov eax, dword [ebp + 0x14]
mov dword [ebp - 0x102c], ebx
mov dword [ebp - 0x1028], ecx
mov dword [ebp - 0x1030], edx
test ebx, ebx
je 0x40b22f
test ecx, ecx
je 0x40b22f
mov ecx, ebx
test eax, eax
mov esi, 0x64f9cc
cmovne esi, eax
lea ebx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x40ae01
sub ecx, ebx
sar ecx, 1
push ecx
push dword [ebp - 0x102c]
lea ecx, [edi + 0x2c]
call fcn.00404b60
mov edx, dword [ebp - 0x1028]
mov ecx, edx
lea eax, [ecx + 2]
mov dword [ebp - 0x1024], eax
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x40ae30
sub ecx, dword [ebp - 0x1024]
sar ecx, 1
push ecx
push edx
lea ecx, [edi + 0x30]
call fcn.00404b60
test esi, esi
jne 0x40ae55
xor ecx, ecx
jmp 0x40ae6f
mov ecx, esi
lea edx, [ecx + 2]
nop word [eax + eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x40ae60
sub ecx, edx
sar ecx, 1
push ecx
push esi
lea esi, [edi + 0x34]
mov ecx, esi
call fcn.00404b60
mov eax, dword [ebp - 0x1030]
test eax, eax
jne 0x40ae89
xor ecx, ecx
jmp 0x40aea8
mov ecx, eax
lea esi, [ecx + 2]
nop
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x40ae90
mov eax, dword [ebp - 0x1030]
sub ecx, esi
sar ecx, 1
lea esi, [edi + 0x34]
push ecx
push eax
lea ecx, [edi + 0x38]
call fcn.00404b60
mov eax, dword [ebp + 0x10]
push dword [ebp - 0x102c]
mov dword [edi + 0x3c], eax
mov eax, dword [ebp + 0x1c]
mov dword [edi + 0x28], eax
lea eax, [ebp - 0x818]
push 0x6506a4
push eax
call fcn.0040cfa0
add esp, 8
mov dword [ebp - 4], 0
push dword [eax]
push 0
call fcn.0043b710
mov ecx, eax
call fcn.0043bad0
mov eax, dword [ebp - 0x818]
lea ecx, [ebp - 0x810]
cmp eax, ecx
je 0x40af08
push eax
call fcn.0053eac5
add esp, 4
mov ecx, 4
mov dword [ebp - 0x102c], 4
call fcn.0040ce70
push dword [ebp - 0x1028]
lea eax, [ebp - 0x818]
mov dword [ebp - 4], 1
push str._g0W
push 0x6506d4
push eax
call fcn.0040cfa0
add esp, 0xc
mov byte [ebp - 4], 2
push dword [eax]
push 0
call fcn.0043b710
mov ecx, eax
call fcn.0043bad0
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x810]
mov eax, dword [ebp - 0x818]
cmp eax, ecx
je 0x40af73
push eax
call fcn.0053eac5
add esp, 4
mov eax, dword [esi]
cmp dword [eax - 0xc], 0
je 0x40aff7
lea eax, [ebp - 0x818]
push str.REQ:
push eax
call fcn.0040cfa0
add esp, 4
mov byte [ebp - 4], 3
push dword [eax]
push 0
call fcn.0043b710
mov ecx, eax
call fcn.0043bad0
mov eax, dword [ebp - 0x818]
lea edx, [ebp - 0x810]
cmp eax, edx
je 0x40afc0
push eax
call fcn.0053eac5
add esp, 4
mov ecx, 4
mov dword [ebp - 0x1024], 4
call fcn.0040ce70
push ecx
mov byte [ebp - 4], 4
push dword [esi]
push 0
call fcn.0043b710
mov ecx, eax
call fcn.0043bad0
mov ecx, 0xfffffffc
mov byte [ebp - 4], 1
call fcn.0040ce70
push 0
push dword [edi + 0x30]
call fcn.005870e6
add esp, 8
cmp eax, 0xffffffff
je 0x40b1b9
mov edx, dword [edi + 0x30]
lea ecx, [ebp - 0x1024]
push 3
call fcn.0042e640
add esp, 4
mov byte [ebp - 4], 5
mov esi, dword [ebp - 0x1024]
test esi, esi
jne 0x40b038
push 0x80004005
call fcn.00404b10
push esi
push dword [edi + 0x38]
call fcn.00585c03
add esp, 8
test eax, eax
jne 0x40b0b2
push dword [ebp - 0x1028]
lea eax, [ebp - 0x818]
push 0x6506ec
push eax
call fcn.0040cfa0
add esp, 8
mov byte [ebp - 4], 6
push dword [eax]
push 0
call fcn.0043b710
mov ecx, eax
call fcn.0043bad0
mov eax, dword [ebp - 0x818]
lea ecx, [ebp - 0x810]
cmp eax, ecx
je 0x40b08f
push eax
call fcn.0053eac5
add esp, 4
mov byte [ebp - 4], 1
add esi, 0xfffffff0
or eax, 0xffffffff
lock xadd dword [esi + 0xc], eax
dec eax
test eax, eax
jg 0x40b0ab
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
xor esi, esi
jmp 0x40b18f
mov byte [ebp - 4], 1
add esi, 0xfffffff0
or eax, 0xffffffff
lock xadd dword [esi + 0xc], eax
dec eax
test eax, eax
jg 0x40b0ce
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
mov eax, dword [edi + 0x38]
cmp dword [eax - 0xc], 0
je 0x40b118
push 0
push 0x80
push 3
push 0
push 3
push SysReAllocString
push dword [edi + 0x30]
lea esi, [edi + 0x1c]
mov dword [esi], 0
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x40b118
test esi, esi
je 0x40b118
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
push ebx
mov dword [esi], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [edi + 0x1c]
cmp eax, 1
jbe 0x40b124
dec eax
mov dword [edi + 0x1c], eax
mov ecx, edi
call fcn.0040aa90
mov ebx, dword [sym.imp.KERNEL32.dll_Sleep]
mov esi, eax
cmp esi, 0x81e60006
jne 0x40b165
cmp dword [edi + 0x28], 0
je 0x40b16e
push 0x1f4
call ebx
push ecx
push 0x65074c
push 0
call fcn.0043b710
mov ecx, eax
call fcn.0043bad0
mov ecx, edi
call fcn.0040aa90
mov esi, eax
cmp esi, 1
je 0x40b16e
test esi, esi
jns 0x40b18b
cmp dword [edi + 0x1c], 0
jbe 0x40b18b
push 0x1f4
mov dword [edi + 0x1c], 0
call ebx
mov ecx, edi
call fcn.0040aa90
mov esi, eax
push 0x64
call ebx
mov ecx, 0xfffffffc
call fcn.0040ce70
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0053e4b1
mov esp, ebp
pop ebp
ret 0x18
mov ecx, dword [edi + 0x30]
call fcn.0042d960
test al, al
jne 0x40b0ce
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
lea eax, [ebp - 0x1020]
push esi
push dword [edi + 0x30]
push 0x650718
push eax
call fcn.0040cfa0
add esp, 0xc
mov byte [ebp - 4], 7
push dword [eax]
push 2
call fcn.0043b710
mov ecx, eax
call fcn.0043bad0
mov eax, dword [ebp - 0x1020]
lea ecx, [ebp - 0x1018]
cmp eax, ecx
je 0x40b216
push eax
call fcn.0053eac5
add esp, 4
cmp esi, 5
jne 0x40b225
mov esi, 0x81e60009
jmp 0x40b18f
mov esi, 0x81e6000a
jmp 0x40b18f
call fcn.0042d760
int3