Function at 0x50bd10
Capabilities:
Get file size

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x61d8b5
mov eax, dword fs:[0]
push eax
sub esp, 0x18c
mov eax, dword [0x653af8]
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 dword [ebp - 0x10], esp
mov eax, ecx
mov dword [ebp - 0x7c], eax
mov edi, dword [ebp + 0xc]
xorps xmm0, xmm0
mov ecx, dword [ebp + 0x1c]
mov dword [ebp - 0x18], eax
mov eax, dword [ebp + 0x18]
mov dword [ebp - 0x78], eax
xor al, al
movups xmmword [ebp - 0x70], xmm0
mov dword [ebp - 0x80], edi
movups xmmword [ebp - 0x60], xmm0
mov dword [ebp - 0x84], ecx
mov byte [ebp - 0x72], 0
mov byte [ebp - 0x73], al
mov byte [ebp - 0x74], al
mov dword [ebp - 0x70], 0xffffffff
mov dword [ebp - 0x6c], getpeername
mov dword [ebp - 0x58], 0
mov dword [ebp - 0x54], 0xf
mov byte [ebp - 0x68], al
mov eax, dword [ebp + 8]
mov dword [ebp - 4], 0
cmp eax, 1
je 0x50bf70
mov esi, dword [ebp + 0x10]
cmp esi, 0xc
jb 0x50c1db
test eax, eax
jne 0x50bdce
push dword [ebp - 0x18]
lea eax, [ebp - 0x70]
push ecx
push esi
push edi
push eax
call fcn.0050b850
add esp, 0x14
jmp 0x50bec8
cmp eax, 2
jne 0x50bfd0
xor al, al
movlpd qword [ebp - 0x2c], xmm0
mov byte [ebp - 0x71], al
mov dword [ebp - 0x24], 0
mov dword [ebp - 0x20], 0
nop
test al, al
jne 0x50bebe
push dword [ebp - 0x18]
lea eax, [ebp - 0x70]
mov byte [ebp - 4], 2
push ecx
push esi
push edi
push eax
call fcn.0050b850
add esp, 0x14
mov byte [ebp - 0x72], 1
mov byte [ebp - 0x71], 1
jmp 0x50bea1
lea ecx, [ebp - 0x2c]
mov dword [ebp - 4], 0
call fcn.00510d50
mov al, byte [ebp - 0x71]
mov ecx, dword [ebp - 0x84]
jmp 0x50bdf0
cmp byte [ebp - 0x72], 0
je 0x50bfd0
push 0
push esi
lea ecx, [ebp - 0x70]
mov byte [ebp - 4], 6
call fcn.005108f0
push 0xffffffffffffffff
push dword [ebp - 0x78]
lea eax, [ebp - 0x70]
mov dword [ebp - 0x20], 0
push 0
push 0
push 0
push 0xc0000000
xorps xmm0, xmm0
lea ecx, [ebp - 0x30]
push eax
movups xmmword [ebp - 0x30], xmm0
call fcn.0050b210
mov esi, dword [ebp - 0x30]
mov ecx, 1
mov byte [ebp - 4], 7
xor eax, eax
lock cmpxchg dword [esi], ecx
test eax, eax
jne 0x50bf53
mov edx, dword [ebp - 0x30]
mov eax, dword [ebp + 0x20]
add edx, 8
sub eax, 0
je 0x50bf2f
sub eax, 1
je 0x50bf38
sub eax, 1
jne 0x50bf38
test edx, edx
je 0x50bf38
mov eax, dword [ebp + 0x24]
xchg dword [edx], eax
mov ecx, dword [ebp - 0x7c]
lea eax, [ebp - 0x30]
push eax
call fcn.00510810
mov eax, 2
xchg dword [esi], eax
lea ecx, [ebp - 0x30]
jmp 0x50c134
cmp eax, 1
je 0x50c23f
cmp eax, 2
je 0x50c23f
jmp 0x50c216
mov eax, dword [ebp + 0x14]
cmp eax, 0xc0000000
jne 0x50c02e
movups xmmword [ebp - 0x40], xmm0
mov dword [ebp - 0x38], 0
movups xmmword [ebp - 0x50], xmm0
mov dword [ebp - 0x34], 0xf
mov byte [ebp - 0x48], 0
lea eax, [ebp - 0x18]
mov byte [ebp - 4], 1
push eax
push 0xc0000000
push dword [edi]
lea ecx, [ebp - 0x50]
mov dword [ebp - 0x18], 0
push 1
call fcn.0050ff10
lea eax, [ebp - 0x70]
mov byte [ebp - 4], 0
push eax
lea ecx, [ebp - 0x50]
call fcn.00510860
lea ecx, [ebp - 0x50]
call fcn.0050d3f0
xor esi, esi
mov edi, dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
xorps xmm0, xmm0
movlpd qword [ebp - 0x1c], xmm0
movlpd qword [ebp - 0x2c], xmm0
mov dword [ebp - 0x24], 0
mov dword [ebp - 0x20], 0
lea eax, [ebp - 0x1c]
push eax
push dword [ebp - 0x70]
call edi
test eax, eax
je 0x50c1a5
lea ecx, [ebp - 0x2c]
call fcn.00510d50
mov edx, dword [ebp - 0x1c]
mov eax, edx
mov ecx, dword [ebp - 0x18]
or eax, ecx
je 0x50bff3
cmp edx, 1
jne 0x50c0af
test ecx, ecx
je 0x50c292
jmp 0x50c0af
cmp eax, 0x80000000
jne 0x50c065
push eax
push dword [edi]
movzx eax, byte [0x659cb8]
lea ecx, [ebp - 0x50]
push eax
movups xmmword [ebp - 0x50], xmm0
movups xmmword [ebp - 0x40], xmm0
call fcn.0050ca80
lea eax, [ebp - 0x70]
push eax
lea ecx, [ebp - 0x50]
call fcn.00510860
mov byte [ebp - 0x73], 1
jmp 0x50bfc8
xor esi, esi
cmp eax, 0xc0000001
jne 0x50bfd2
movzx eax, byte [0x659cb8]
lea ecx, [ebp - 0x50]
push closesocket
push dword [edi]
movups xmmword [ebp - 0x50], xmm0
push eax
movups xmmword [ebp - 0x40], xmm0
call fcn.0050ca80
lea eax, [ebp - 0x70]
push eax
lea ecx, [ebp - 0x50]
call fcn.00510860
lea ecx, [ebp - 0x50]
call fcn.0050d3f0
mov esi, 1
jmp 0x50bfd2
cmp byte [ebp - 0x73], 0
xorps xmm0, xmm0
movups xmmword [ebp - 0x44], xmm0
mov dword [ebp - 0x34], 0
je 0x50c0ca
mov esi, closesocket
jmp 0x50c0d0
add esi, 0xc0000000
push 0xffffffffffffffff
push dword [ebp - 0x78]
lea eax, [ebp - 0x70]
push 0
push 0
push 0
push esi
push eax
lea ecx, [ebp - 0x44]
call fcn.0050b210
mov esi, dword [ebp - 0x44]
mov byte [ebp - 4], 0xd
mov eax, dword [esi]
xorps xmm0, xmm0
mov dword [ebp - 0x24], 0
movlpd qword [ebp - 0x2c], xmm0
mov dword [ebp - 0x20], 0
cmp eax, 1
je 0x50c110
test eax, eax
jne 0x50c11c
lea ecx, [ebp - 0x2c]
call fcn.00510d50
mov eax, dword [esi]
jmp 0x50c107
cmp eax, 2
jne 0x50c2be
mov ecx, dword [ebp - 0x7c]
lea eax, [ebp - 0x44]
push eax
call fcn.00510810
lea ecx, [ebp - 0x44]
call fcn.0050d2c0
mov eax, dword [ebp - 0x70]
mov dword [ebp - 4], 0xf
cmp eax, 0xffffffff
je 0x50c14f
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, dword [ebp - 0x54]
cmp edx, 0x10
jb 0x50c187
mov ecx, dword [ebp - 0x68]
inc edx
mov eax, ecx
mov byte [ebp - 4], 0x10
cmp edx, 0x1000
jb 0x50c17d
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x50c2e7
push edx
push ecx
call fcn.006024e7
add esp, 8
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.00602a00
mov esp, ebp
pop ebp
ret 0x20
call sub.KERNEL32.dll_GetLastError
push eax
lea ecx, [ebp - 0x88]
call fcn.0050c570
push 0
lea eax, [ebp - 0x88]
push eax
lea ecx, [ebp - 0x198]
call fcn.0050c5d0
push 0x635cc4
lea eax, [ebp - 0x198]
push eax
call fcn.00603d27
push 0
push 0x12
lea ecx, [ebp - 0x1c]
call fcn.0050c5b0
push eax
lea ecx, [ebp - 0xbc]
call fcn.0050c5d0
push 0x635cc4
lea eax, [ebp - 0xbc]
push eax
call fcn.00603d27
push 0
push 0
call fcn.00603d27
push 0
push 0
call fcn.00603d27
push 0
push 0x13
lea ecx, [ebp - 0x1c]
call fcn.0050c5b0
push eax
lea ecx, [ebp - 0xe8]
call fcn.0050c5d0
push 0x635cc4
lea eax, [ebp - 0xe8]
push eax
call fcn.00603d27
push 0
push 9
lea ecx, [ebp - 0x1c]
call fcn.0050c5b0
push eax
lea ecx, [ebp - 0x114]
call fcn.0050c5d0
push 0x635cc4
lea eax, [ebp - 0x114]
push eax
call fcn.00603d27
mov dword [ebp - 0x10], esp
lea eax, [ebp - 0x70]
push dword [ebp - 0x18]
mov byte [ebp - 4], 0xb
push 0
push 1
push eax
call fcn.0050c330
add esp, 0x10
push 0
push 0
mov dword [ebp - 4], 0xa
call fcn.00603d27
push 0
push 0x13
lea ecx, [ebp - 0x88]
call fcn.0050c5b0
push eax
lea ecx, [ebp - 0x140]
call fcn.0050c5d0
push 0x635cc4
lea eax, [ebp - 0x140]
push eax
call fcn.00603d27
push 0
push 0x13
lea ecx, [ebp - 0x1c]
call fcn.0050c5b0
push eax
lea ecx, [ebp - 0x16c]
call fcn.0050c5d0
push 0x635cc4
lea eax, [ebp - 0x16c]
push eax
call fcn.00603d27
call fcn.0053accc
int3