Function at 0x40185a
Capabilities:
Get file size

Disassembly:
push ebp
lea ebp, [esp - 0x8c]
sub esp, 0x10c
mov eax, dword [0x42a43c]
xor eax, ebp
mov dword [ebp + 0x88], eax
push ebx
mov ebx, dword [ebp + 0x94]
push esi
push edi
push 0
lea eax, [ebx + 0x10]
push 0x440568
push eax
lea esi, [ebx + 0xf0]
mov dword [ebx + 0xec], 0x63538263
call fcn.004073d1
add esp, 0xc
test byte [0x429c34], 1
mov edi, eax
mov dword [ebp - 0x80], edi
je 0x4018b4
mov eax, dword [edi]
mov dword [ebx + 0x14], eax
xor eax, eax
mov dword [ebp - 0x7c], eax
jmp 0x4018be
mov edi, dword [ebp - 0x80]
cmp byte [eax + 0x42905c], 0
je 0x4018d9
mov cl, byte [eax + 0x429058]
mov byte [esi], cl
mov cl, byte [eax + 0x42905c]
inc esi
mov byte [esi], cl
inc esi
mov eax, dword [eax + 0x429058]
cmp eax, 0x2c
ja 0x4019ff
je 0x4019f5
dec eax
je 0x4019eb
dec eax
dec eax
je 0x4019d5
sub eax, 3
je 0x4019f5
dec eax
je 0x4019c1
sub eax, 6
je 0x401955
dec eax
dec eax
jne 0x401aad
cmp byte [0x440674], al
je 0x401aad
mov edi, 0x440674
mov byte [esi], 0xf
push edi
inc esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov byte [esi], al
movzx eax, al
push eax
lea eax, [esi + 1]
push edi
push eax
call fcn.0040e730
movzx eax, byte [esi]
add esp, 0xc
lea esi, [esi + eax + 1]
jmp 0x401aad
lea eax, [ebx + 0x1c]
push eax
push dword [ebx + 0x10]
lea eax, [ebp - 0x78]
push eax
push 0x440574
call fcn.004027cc
add esp, 0x10
push 0
push 0x80
push 3
push 0
push 1
push bind
lea eax, [ebp - 0x78]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, 0xffffffff
je 0x401aad
mov byte [esi], 0xd
inc esi
push 0
mov byte [esi], 2
push edi
inc esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
shr eax, 9
inc eax
push eax
call dword [sym.imp.WS2_32.dll_htons]
mov word [esi], ax
inc esi
push edi
inc esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x401aad
test byte [0x429c34], 8
je 0x401aad
mov eax, dword [edi]
jmp 0x401aab
mov eax, dword [0x440570]
cmp eax, 0xffffffff
jne 0x401aab
mov eax, dword [ebx + 0x10]
jmp 0x401aab
mov eax, dword [0x440568]
jmp 0x401aab
mov eax, dword [0x44056c]
jmp 0x401aab
cmp eax, 0x33
je 0x401a9c
cmp eax, 0x35
je 0x401a92
cmp eax, 0x36
je 0x4019ce
cmp eax, 0x39
jbe 0x401aad
cmp eax, 0x3b
jbe 0x401a86
cmp eax, 0xfe
je 0x401a3f
cmp eax, 0xff
jne 0x401aad
mov byte [esi], al
inc esi
mov byte [esi], 0
inc esi
mov byte [esi], 0
inc esi
jmp 0x401aad
xor edi, edi
lea eax, [edi + 0x4406fc]
cmp dword [eax], 0
je 0x401a76
mov al, byte [eax]
mov byte [esi], al
lea eax, [ebx + 0x1c]
push eax
push dword [ebx + 0x10]
lea eax, [edi + 0x440700]
push eax
inc esi
lea eax, [esi + 1]
push 0x40
push eax
call fcn.0040346a
mov byte [esi], al
movzx eax, al
add esp, 0x14
lea esi, [esi + eax + 1]
add edi, 0x84
cmp edi, 0x528
jb 0x401a41
jmp 0x401aad
mov eax, dword [0x4406f4]
cdq
sub eax, edx
sar eax, 1
jmp 0x401aa1
mov al, byte [ebp + 0x98]
mov byte [esi], al
jmp 0x401aad
mov eax, dword [0x4406f4]
imul eax, eax, 0x3c
push eax
call dword [sym.imp.WS2_32.dll_htonl]
mov dword [esi], eax
mov eax, dword [ebp - 0x7c]
movsx ecx, byte [eax + 0x42905c]
add eax, 8
add esi, ecx
mov dword [ebp - 0x7c], eax
cmp eax, 0x70
jb 0x4018bb
mov ecx, dword [ebp + 0x88]
pop edi
mov eax, esi
sub eax, ebx
pop esi
xor ecx, ebp
pop ebx
call fcn.0040e208
add ebp, 0x8c
leave
ret