Function at 0x4d5fa0
Capabilities:
Check os version

Disassembly:
sub esp, 0x510
push ebx
push ebp
push esi
push edi
call fcn.004d93f0
mov ecx, dword [0x56b308]
mov edx, ecx
and edx, 1
cmp dl, 1
jne 0x4d5fd4
mov edx, eax
and edx, 1
cmp dl, 1
jne 0x4d5fd4
mov esi, 1
mov dword [esp + 0x14], esi
jmp 0x4d5ff7
and ecx, 2
cmp cl, 2
jne 0x4d6540
and eax, 2
cmp al, cl
jne 0x4d6540
mov dword [esp + 0x14], 2
mov esi, dword [esp + 0x14]
lea eax, [esp + 0x2ec]
mov dword [esp + 0x2ec], 0x94
push eax
call dword [sym.imp.kernel32.dll_GetVersionExA]
cmp dword [esp + 0x2fc], 2
je 0x4d606a
cmp esi, 2
jne 0x4d6087
mov ecx, dword [esp + 0x53c]
mov edx, dword [esp + 0x538]
mov eax, dword [esp + 0x534]
push ecx
mov ecx, dword [esp + 0x534]
push edx
mov edx, dword [esp + 0x534]
push eax
mov eax, dword [esp + 0x534]
push ecx
mov ecx, dword [esp + 0x534]
push edx
push eax
push ecx
call fcn.004d5870
add esp, 0x1c
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x510
ret
cmp esi, 2
jne 0x4d6087
push 0x3e8
push esi
push 6
call fcn.004d5490
mov ebp, eax
add esp, 0xc
mov dword [esp + 0x10], ebp
jmp 0x4d609b
push 0x11
push 2
push 2
call fcn.004d5490
add esp, 0xc
mov dword [esp + 0x10], eax
mov ebp, eax
or ebx, 0xffffffff
cmp ebp, ebx
jne 0x4d60b2
pop edi
pop esi
pop ebp
mov eax, 0x3f
pop ebx
add esp, 0x510
ret
push ebp
call fcn.004d5780
add esp, 4
push 1
call fcn.004d5770
push eax
call fcn.004d6e10
add esp, 8
cmp eax, ebx
jne 0x4d60e5
push ebp
call sub.wsock32.dll_closesocket
pop edi
pop esi
pop ebp
mov eax, 0x41
pop ebx
add esp, 0x510
ret
mov edx, dword [0x57489c]
push edx
call fcn.004d4950
add esp, 4
test eax, eax
jne 0x4d612b
mov eax, dword [0x57489c]
push eax
call fcn.004d4960
mov ax, word [eax]
add esp, 4
cmp ax, 6
jne 0x4d6114
cmp esi, 2
je 0x4d612b
cmp ax, 2
jne 0x4d611f
cmp esi, 1
je 0x4d612b
mov dword [0x56b450], 1
jmp 0x4d6138
mov eax, dword [0x56b450]
test eax, eax
je 0x4d6245
push 0x57489c
call fcn.004d4980
add esp, 4
cmp esi, 2
jne 0x4d6194
push 0xe
call fcn.004fa109
mov esi, eax
add esp, 4
test esi, esi
je 0x4d61a4
mov edx, esi
xor ecx, ecx
mov dword [edx], ecx
mov dword [edx + 4], ecx
mov dword [edx + 8], ecx
mov word [edx + 0xc], cx
mov word [esi], 6
call fcn.004d5790
push eax
call fcn.004d55c0
mov word [esi + 0xc], ax
lea eax, [esi + 2]
lea edx, [esi + 6]
mov ecx, ebx
mov dword [eax], 0
mov dword [edx], ecx
mov word [edx + 4], cx
jmp 0x4d61f0
push 0x10
call fcn.004fa109
mov esi, eax
add esp, 4
test esi, esi
jne 0x4d61ca
push 0
call fcn.004d5770
push eax
call fcn.004d6e10
add esp, 8
push ebp
call sub.wsock32.dll_closesocket
pop edi
pop esi
pop ebp
mov eax, 0x40
pop ebx
add esp, 0x510
ret
mov ecx, esi
xor eax, eax
mov dword [ecx], eax
mov dword [ecx + 4], eax
mov dword [ecx + 8], eax
mov dword [ecx + 0xc], eax
mov word [esi], 2
call fcn.004d5790
push eax
call fcn.004d55c0
mov word [esi + 2], ax
mov dword [esi + 4], ebx
push esi
push 0x57489c
call fcn.004d4990
mov eax, dword [0x57489c]
add esp, 0xc
mov dword [0x574898], eax
push eax
call fcn.004d4950
add esp, 4
test eax, eax
je 0x4d623b
push 0
call fcn.004d5770
push eax
call fcn.004d6e10
add esp, 8
push ebp
call sub.wsock32.dll_closesocket
pop edi
pop esi
pop ebp
mov eax, 0x41
pop ebx
add esp, 0x510
ret
mov dword [0x56b450], 0
push 0
call fcn.004fbea1
add esp, 4
test eax, eax
jge 0x4d6263
pop edi
pop esi
pop ebp
mov eax, 0x4a
pop ebx
add esp, 0x510
ret
push 0
call fcn.004fbea1
and eax, 0x80001fff
jns 0x4d6278
dec eax
or eax, 0xffffe000
inc eax
mov esi, dword [esp + 0x52c]
mov dword [esp + 0x154], eax
mov ecx, 0x64
xor eax, eax
lea edi, [esp + 0x160]
mov dword [esp + 0x15c], ebx
mov dword [esp + 0x150], 0x6e
mov dword [esp + 0x158], 0
rep stosd dword es:[edi], eax
mov edi, esi
mov ecx, ebx
repne scasb al, byte es:[edi]
not ecx
mov edx, ecx
lea edi, [esp + 0x160]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov esi, dword [0x57489c]
push esi
call fcn.004d4950
add esp, 8
test eax, eax
jne 0x4d632c
push esi
call fcn.004d4960
add esp, 4
push 0x10
push eax
push 0
lea eax, [esp + 0x158]
push 0x1a0
push eax
call fcn.004d5770
push eax
call fcn.004d5540
add esp, 0x18
cmp eax, 0x1a0
jne 0x4d63eb
push esi
call fcn.004d4970
mov esi, eax
push esi
call fcn.004d4950
add esp, 8
test eax, eax
je 0x4d62e3
push 0
call fcn.004fbea1
mov ecx, dword [esp + 0x530]
mov edi, dword [esp + 0x540]
mov ebp, dword [esp + 0x53c]
mov ebx, dword [esp + 0x538]
mov esi, dword [esp + 0x534]
add esp, 4
add eax, ecx
mov dword [esp + 0x1c], eax
push 0
mov dword [esp + 0x28], 0
call fcn.004fbea1
mov ecx, dword [esp + 0x20]
add esp, 4
sub ecx, eax
mov dword [esp + 0x20], ecx
jns 0x4d6385
mov dword [esp + 0x20], 0
mov dword [esp + 0x48], 0
call fcn.004d5770
mov edx, dword [esp + 0x48]
lea ecx, [esp + 0x48]
mov dword [esp + edx*4 + 0x4c], eax
mov edx, dword [esp + 0x48]
lea eax, [esp + 0x20]
inc edx
push eax
push 0
push 0
push ecx
mov dword [esp + 0x58], edx
call fcn.004d5770
inc eax
push eax
call fcn.004d54c0
add esp, 0x14
cmp eax, 0xffffffff
je 0x4d64b4
test eax, eax
je 0x4d6519
cmp dword [esp + 0x14], 2
jne 0x4d6401
lea edx, [esp + 0x18]
mov dword [esp + 0x18], 0xe
push edx
lea eax, [esp + 0x2c]
jmp 0x4d6412
push ebp
call sub.wsock32.dll_closesocket
pop edi
pop esi
pop ebp
mov eax, 0x3e
pop ebx
add esp, 0x510
ret
lea edx, [esp + 0x18]
mov dword [esp + 0x18], 0x10
push edx
lea eax, [esp + 0x3c]
push eax
push 0
lea ecx, [esp + 0x38c]
push 0x1a0
push ecx
call fcn.004d5770
push eax
call fcn.004d5580
add esp, 0x18
cmp eax, 0xffffffff
je 0x4d635f
mov edx, dword [esp + 0x384]
mov eax, dword [esp + 0x150]
cmp edx, eax
jne 0x4d635f
mov eax, dword [esp + 0x38c]
mov ecx, dword [esp + 0x158]
cmp eax, ecx
jne 0x4d635f
cmp dword [esp + 0x14], 2
jne 0x4d6478
lea ecx, [esp + 0x28]
push ecx
call fcn.004d9590
jmp 0x4d6482
mov edx, dword [esp + 0x3c]
push edx
call fcn.004d5470
add esp, 4
push edi
push ebp
push ebx
push esi
push eax
lea eax, [esp + 0x3a4]
push eax
call fcn.004d5d20
add esp, 0x18
cmp esi, 4
jne 0x4d64a6
cmp word [edi + 0x20], 0
ja 0x4d6519
cmp eax, 0x40
je 0x4d64c5
test eax, eax
je 0x4d6519
jmp 0x4d635f
call sub.wsock32.dll_WSAGetLastError
cmp eax, 0x2714
jne 0x4d64df
jmp 0x4d635f
mov ecx, dword [esp + 0x10]
push ecx
call sub.wsock32.dll_closesocket
pop edi
pop esi
pop ebp
mov eax, 0x40
pop ebx
add esp, 0x510
ret
call sub.wsock32.dll_WSAGetLastError
cmp eax, 0x2714
je 0x4d64fb
push 0
call fcn.004d5770
push eax
call fcn.004d6e10
add esp, 8
mov edx, dword [esp + 0x10]
push edx
call sub.wsock32.dll_closesocket
mov ecx, dword [ebx]
xor eax, eax
pop edi
pop esi
test ecx, ecx
pop ebp
pop ebx
setle al
add esp, 0x510
ret
push 0
call fcn.004d5770
push eax
call fcn.004d6e10
mov eax, dword [esp + 0x18]
add esp, 8
push eax
call sub.wsock32.dll_closesocket
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x510
ret
pop edi
pop esi
pop ebp
mov eax, 0x4c
pop ebx
add esp, 0x510
ret