Function at 0x140027d40
Capabilities:
Get system information on windows
Parse pe header

Disassembly:
mov qword [rsp + 0x18], r8
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
push rbx
push r12
push r13
push r15
sub rsp, 0x78
xor r12d, r12d
mov r8, rdx
mov r13, r9
mov rdx, rcx
mov ebx, r12d
mov r15d, r12d
cmp r8, 0x40
jae 0x140027d8b
mov ecx, reloc.WS2_32.dll_listen
call qword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
add rsp, 0x78
pop r15
pop r13
pop r12
pop rbx
ret
mov eax, 0x5a4d
cmp word [rcx], ax
je 0x140027dae
mov ecx, 0xc1
call qword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
add rsp, 0x78
pop r15
pop r13
pop r12
pop rbx
ret
movsxd rcx, dword [rcx + 0x3c]
lea rax, [rcx + 0x108]
cmp r8, rax
jb 0x140027d72
cmp dword [rcx + rdx], 0x4550
mov qword [rsp + 0xb8], rbp
lea rbp, [rcx + rdx]
jne 0x140027de5
mov eax, 0x8664
cmp word [rbp + 4], ax
jne 0x140027de5
mov eax, dword [rbp + 0x38]
test al, 1
je 0x140027df7
mov ecx, 0xc1
call qword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
jmp 0x1400280da
movzx ecx, word [rbp + 0x14]
mov r9, rax
movzx eax, word [rbp + 6]
add rcx, 0x24
mov qword [rsp + 0x68], rdi
cmp r12w, ax
jae 0x140027e45
add rcx, rbp
movzx r8d, ax
nop dword [rax + rax]
mov eax, dword [rcx + 4]
mov edx, dword [rcx]
test eax, eax
jne 0x140027e2f
lea rax, [r9 + rdx]
jmp 0x140027e31
add eax, edx
cmp rax, rbx
cmovbe rax, rbx
add rcx, 0x28
mov rbx, rax
sub r8, 1
jne 0x140027e20
lea rcx, [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_GetNativeSystemInfo]
mov edx, dword [rsp + 0x34]
mov eax, dword [rbp + 0x50]
lea rdi, [rdx - 1]
add rdi, rax
lea rcx, [rdx - 1]
not rcx
lea rax, [rdx - 1]
add rax, rbx
and rdi, rcx
and rax, rcx
cmp rdi, rax
je 0x140027e89
mov ecx, 0xc1
call qword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
jmp 0x1400280d5
mov rcx, qword [rbp + 0x30]
mov r9d, 4
mov rbx, qword [rsp + 0xb0]
mov r8d, 0x3000
mov qword [rsp + 0x70], rsi
mov rdx, rdi
mov rsi, qword [rsp + 0xd8]
mov qword [rsp + 0x20], rsi
mov qword [rsp + 0x60], r14
call rbx
mov r14, rax
test rax, rax
jne 0x140027ee7
lea r9d, [rax + 4]
mov qword [rsp + 0x20], rsi
mov r8d, 0x3000
mov rdx, rdi
xor ecx, ecx
call rbx
mov r14, rax
test rax, rax
je 0x1400280fc
movabs rdx, 0xffffffff00000000
lea rcx, [r14 + rdi]
mov rax, r14
and rcx, rdx
and rax, rdx
cmp rax, rcx
jae 0x140027f6d
mov ecx, reloc.WS2_32.dll_recv
call fcn.140176304
mov rbx, rax
test rax, rax
je 0x140028109
mov qword [rax], r15
mov r9d, 4
mov r8d, 0x3000
mov qword [rax + 8], r14
mov rdx, rdi
mov qword [rsp + 0x20], rsi
xor ecx, ecx
mov r15, rax
call qword [rsp + 0xb0]
mov r14, rax
test rax, rax
je 0x1400280ee
lea rcx, [rax + rdi]
movabs rdx, 0xffffffff00000000
and rcx, rdx
and rax, rdx
cmp rax, rcx
jb 0x140027f03
mov rbx, qword [rsp + 0xb0]
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov edx, 8
mov rcx, rax
lea r8d, [rdx + 0x70]
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov rdi, rax
test rax, rax
je 0x140028109
mov qword [rax + 8], r14
movzx eax, word [rbp + 0x16]
shr eax, 0xd
and eax, 1
mov qword [rdi + 0x28], rbx
mov dword [rdi + 0x20], eax
mov rax, qword [rsp + 0xc0]
mov qword [rdi + 0x38], rax
mov rax, qword [rsp + 0xc8]
mov qword [rdi + 0x40], rax
mov rax, qword [rsp + 0xd0]
mov qword [rdi + 0x48], rax
mov qword [rdi + 0x30], r13
mov qword [rdi + 0x58], rsi
mov eax, dword [rsp + 0x34]
mov dword [rdi + 0x68], eax
mov qword [rdi + 0x70], r15
mov edx, dword [rbp + 0x54]
cmp qword [rsp + 0xa8], rdx
jae 0x14002811f
mov ecx, reloc.WS2_32.dll_listen
call qword [sym.imp.KERNEL32.dll_SetLastError]
cmp dword [rdi + 0x1c], r12d
je 0x140028015
mov rax, qword [rdi]
xor r8d, r8d
mov rcx, qword [rdi + 8]
xor edx, edx
mov r9d, dword [rax + 0x28]
add r9, rcx
call r9
mov rcx, qword [rdi + 0x50]
call fcn.1401762fc
mov rcx, qword [rdi + 0x10]
test rcx, rcx
je 0x14002805d
cmp dword [rdi + 0x18], r12d
jle 0x140028058
mov rbx, r12
mov rcx, qword [rdi + 0x10]
mov rax, qword [rcx + rbx]
test rax, rax
je 0x14002804b
mov rdx, qword [rdi + 0x58]
mov rcx, rax
call qword [rdi + 0x48]
mov rcx, qword [rdi + 0x10]
inc r12d
add rbx, 8
cmp r12d, dword [rdi + 0x18]
jl 0x140028030
call fcn.1401762fc
mov rcx, qword [rdi + 8]
test rcx, rcx
je 0x140028075
mov r9, qword [rdi + 0x58]
xor edx, edx
mov r8d, 0x8000
call qword [rdi + 0x30]
mov rsi, qword [rdi + 0x70]
mov rbp, qword [rdi + 0x58]
mov r14, qword [rdi + 0x30]
test rsi, rsi
je 0x1400280b5
nop word [rax + rax]
mov rcx, qword [rsi + 8]
mov r9, rbp
xor edx, edx
mov r8d, 0x8000
call r14
mov rbx, qword [rsi]
mov rcx, rsi
call fcn.1401762fc
mov rsi, rbx
test rbx, rbx
jne 0x140028090
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8, rdi
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapFree]
xor eax, eax
mov rsi, qword [rsp + 0x70]
mov r14, qword [rsp + 0x60]
mov rdi, qword [rsp + 0x68]
mov rbp, qword [rsp + 0xb8]
add rsp, 0x78
pop r15
pop r13
pop r12
pop rbx
ret
mov rcx, rbx
mov rdx, r13
mov r8, rsi
call fcn.140027a90
mov ecx, recvfrom
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x1400280c9
mov r9, rsi
xor edx, edx
mov r8d, 0x8000
mov rcx, r14
call r13
mov rcx, r15
jmp 0x1400280f1
mov r9d, 4
mov qword [rsp + 0x20], rsi
mov r8d, 0x1000
mov rcx, r14
call rbx
mov rsi, qword [rsp + 0xa0]
mov rcx, rax
mov r8d, dword [rbp + 0x54]
mov rdx, rsi
mov rbx, rax
call fcn.140174ed0
movsxd rax, dword [rsi + 0x3c]
mov r13d, r12d
add rax, rbx
mov qword [rdi], rax
mov qword [rax + 0x30], r14
mov rcx, qword [rdi]
mov r15, qword [rdi + 8]
movzx esi, word [rcx + 0x14]
add rsi, 0x24
cmp r12w, word [rcx + 6]
jae 0x140028240
add rsi, rcx
nop dword [rax]
mov edx, dword [rsi + 4]
test edx, edx
jne 0x1400281d1
movsxd rax, dword [rbp + 0x38]
test eax, eax
jle 0x140028229
mov ecx, dword [rsi]
lea r9d, [rdx + 4]
mov rbx, rax
add rcx, r15
mov rax, qword [rdi + 0x58]
mov rdx, rbx
mov r8d, 0x1000
mov qword [rsp + 0x20], rax
call qword [rdi + 0x28]
test rax, rax
je 0x140027ff9
mov ecx, dword [rsi]
mov r8, rbx
add rcx, r15
xor edx, edx
mov dword [rsi - 4], ecx
call fcn.140174d10
jmp 0x140028229
mov eax, dword [rsi + 8]
add eax, edx
cmp qword [rsp + 0xa8], rax
jb 0x140027fee
mov ecx, dword [rsi]
mov r9d, 4
mov rax, qword [rdi + 0x58]
add rcx, r15
mov r8d, 0x1000
mov qword [rsp + 0x20], rax
call qword [rdi + 0x28]
test rax, rax
je 0x140027ff9
mov ebx, dword [rsi]
mov edx, dword [rsi + 8]
add rbx, r15
mov r8d, dword [rsi + 4]
mov rcx, rbx
add rdx, qword [rsp + 0xa0]
call fcn.140174ed0
mov dword [rsi - 4], ebx
mov rcx, qword [rdi]
inc r13d
add rsi, 0x28
movzx eax, word [rcx + 6]
cmp r13d, eax
jl 0x140028180
mov rbx, qword [rcx + 0x30]
sub rbx, qword [rbp + 0x30]
je 0x1400282e9
cmp dword [rcx + 0xb4], r12d
jne 0x14002825f
mov eax, r12d
jmp 0x1400282ee
mov rsi, qword [rdi + 8]
mov r11d, dword [rcx + 0xb0]
add r11, rsi
mov eax, dword [r11]
test eax, eax
je 0x1400282e9
nop dword [rax]
nop dword [rax + rax]
mov r9d, dword [r11 + 4]
lea rdx, [r11 + 8]
mov r10d, eax
mov r8d, r12d
add r10, rsi
lea rax, [r9 - 8]
test rax, 0xfffffffffffffffe
jbe 0x1400282dc
nop dword [rax]
movzx eax, word [rdx]
mov ecx, eax
shr eax, 0xc
and ecx, 0xfff
cmp eax, 3
je 0x1400282be
cmp eax, 0xa
jne 0x1400282c2
add qword [rcx + r10], rbx
jmp 0x1400282c2
add dword [rcx + r10], ebx
mov r9d, dword [r11 + 4]
inc r8d
add rdx, 2
mov eax, r8d
lea rcx, [r9 - 8]
shr rcx, 1
cmp rax, rcx
jb 0x1400282a0
mov eax, r9d
add r11, rax
mov eax, dword [r11]
test eax, eax
jne 0x140028280
mov eax, 1
mov rcx, rdi
mov dword [rdi + 0x24], eax
call fcn.140027610
test eax, eax
je 0x140027ff9
mov rcx, rdi
call fcn.140027870
test eax, eax
je 0x140027ff9
mov rdx, qword [rdi]
mov rcx, rdx
mov eax, dword [rdx + 0xd0]
test eax, eax
je 0x14002835c
mov rsi, qword [rdi + 8]
mov rbx, qword [rax + rsi + 0x18]
test rbx, rbx
je 0x14002835c
mov rax, qword [rbx]
test rax, rax
je 0x14002835c
nop word [rax + rax]
xor r8d, r8d
mov rcx, rsi
lea edx, [r8 + 1]
call rax
mov rax, qword [rbx + 8]
lea rbx, [rbx + 8]
test rax, rax
jne 0x140028340
mov rcx, qword [rdi]
mov eax, dword [rcx + 0x28]
test eax, eax
je 0x1400283a1
add rax, r14
cmp dword [rdi + 0x20], r12d
je 0x140028395
xor r8d, r8d
mov rcx, r14
lea edx, [r8 + 1]
call rax
test eax, eax
jne 0x140028386
mov ecx, 0x45a
jmp 0x140027ff3
mov dword [rdi + 0x1c], 1
mov rax, rdi
jmp 0x1400280cb
mov qword [rdi + 0x60], rax
mov rax, rdi
jmp 0x1400280cb
mov qword [rdi + 0x60], r12
mov rax, rdi
jmp 0x1400280cb