Function at 0x140004010
Capabilities:
Get system information on windows
Write file on windows

Disassembly:
push rbp
push rbx
push rdi
push r15
lea rbp, [rsp - 0x88]
sub rsp, 0x188
mov rax, qword [0x14000b008]
xor rax, rsp
mov qword [rbp + 0x68], rax
mov ebx, edx
mov rdi, r8
xor edx, edx
mov r15, rcx
lea r8d, [rdx + 1]
call qword [sym.imp.dbghelp.dll_SymInitializeW]
test eax, eax
jne 0x140004058
call qword [sym.imp.KERNEL32.dll_GetLastError]
xor eax, eax
jmp 0x140004628
mov qword [rsp + 0x180], rsi
mov esi, 0x1000
mov qword [rsp + 0x178], r12
xor r12d, r12d
mov qword [rsp + 0x60], r12
mov qword [rsp + 0x68], r12
mov qword [rsp + 0x50], r12
mov dword [rsp + 0x58], r12d
mov qword [rbp - 0x78], r12
mov qword [rbp - 0x70], r12
mov qword [rbp - 0x68], r12
mov qword [rbp - 0x60], r12
mov dword [rbp - 0x80], r12d
mov qword [rsp + 0x78], rdi
mov dword [rsp + 0x38], ebx
mov qword [rsp + 0x40], r15
mov dword [rsp + 0x70], 0x822
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
xor edx, edx
mov r8d, esi
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov rdi, rax
test rax, rax
je 0x140004616
xor r9d, r9d
lea ecx, [r12 + 5]
mov r8d, esi
mov rdx, rax
call fcn.140005550
cmp eax, 0xc0000004
jne 0x140004126
add esi, esi
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r9d, esi
mov r8, rdi
mov rcx, rax
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov rdi, rax
test rax, rax
je 0x140004616
xor r9d, r9d
mov r8d, esi
mov rdx, rax
lea ecx, [r9 + 5]
call fcn.140005550
cmp eax, 0xc0000004
je 0x1400040e8
test eax, eax
jne 0x140004602
mov edx, dword [rsp + 0x38]
mov rcx, rdi
cmp dword [rdi + 0x50], edx
je 0x140004152
nop word [rax + rax]
mov eax, dword [rcx]
test eax, eax
je 0x140004602
add rcx, rax
cmp dword [rcx + 0x50], edx
jne 0x140004140
mov eax, dword [rcx + 4]
mov dword [rsp + 0x58], eax
lea rbx, [rax + rax*2]
shl rbx, 2
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8, rbx
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov qword [rsp + 0x50], rax
test rax, rax
je 0x140004602
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8, rdi
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov rcx, qword [rsp + 0x40]
lea r8, [rsp + 0x30]
lea rdx, [0x140003e30]
call qword [sym.imp.dbghelp.dll_EnumerateLoadedModulesW64]
mov edx, dword [rbp - 0x80]
xor r9d, r9d
mov rcx, qword [rsp + 0x78]
xor r8d, r8d
mov dword [rbp - 0x20], 0x504d444d
mov dword [rbp - 0x1c], 0xa793
mov dword [rbp - 0x18], 4
mov qword [rbp - 0x14], 0x20
mov qword [rbp - 8], 0x822
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
mov rcx, qword [rsp + 0x78]
lea r9, [rbp - 0x28]
mov r8d, 0x20
mov qword [rsp + 0x20], r12
lea rdx, [rbp - 0x20]
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [rbp - 0x80]
lea rcx, [rbp + 0x38]
add eax, 0x50
mov dword [rbp - 0x40], 7
mov dword [rbp - 0x80], eax
mov dword [rbp - 0x38], eax
call qword [sym.imp.KERNEL32.dll_GetSystemInfo]
lea rcx, [0x1400087c8]
call qword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov rcx, rax
lea rdx, str.RtlGetNtVersionNumbers
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
lea r8, [rbp - 0x4c]
lea rdx, [rbp - 0x2c]
lea rcx, [rbp - 0x30]
call rax
movzx r9d, word [rbp - 0x4c]
lea rcx, str.OS_Version:__d._d._d_n
mov r8d, dword [rbp - 0x2c]
mov edx, dword [rbp - 0x30]
mov dword [rbp - 0x4c], r9d
call fcn.140001100
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
movzx eax, word [rbp + 0x38]
mov ebx, r12d
mov word [rbp], ax
movzx eax, word [rbp + 0x64]
mov word [rbp + 2], ax
movzx eax, word [rbp + 0x66]
mov word [rbp + 4], ax
movzx eax, byte [rbp + 0x58]
mov byte [rbp + 6], al
mov eax, dword [rbp - 0x30]
mov dword [rbp + 8], eax
mov eax, dword [rbp - 0x2c]
mov dword [rbp + 0xc], eax
mov eax, dword [rbp - 0x4c]
mov dword [rbp + 0x10], eax
mov eax, dword [rbp - 0x80]
add eax, 0x38
mov dword [rbp + 0x1c], r12d
mov dword [rbp + 0x18], eax
mov eax, 0x10
mov word [rbp + 0x1c], ax
mov byte [rbp + 7], 1
mov dword [rbp + 0x14], 2
mov qword [rbp + 0x20], r12
mov qword [rbp + 0x28], r12
mov ecx, ebx
call qword [sym.imp.KERNEL32.dll_IsProcessorFeaturePresent]
test eax, eax
je 0x1400042ec
mov rcx, qword [rbp + 0x20]
mov eax, ebx
bts rcx, rax
mov qword [rbp + 0x20], rcx
inc ebx
cmp ebx, 0x40
jb 0x1400042d2
mov edx, dword [rbp - 0x80]
xor r9d, r9d
mov rcx, qword [rsp + 0x78]
xor r8d, r8d
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
mov rcx, qword [rsp + 0x78]
lea r9, [rbp - 0x50]
mov r8d, 0x38
mov qword [rsp + 0x20], r12
lea rdx, [rbp]
call qword [sym.imp.KERNEL32.dll_WriteFile]
add dword [rbp - 0x80], 0x38
lea rcx, [0x140008810]
call qword [sym.imp.KERNEL32.dll_lstrlenW]
mov rcx, qword [rsp + 0x78]
lea r9, [rbp - 0x28]
add eax, eax
mov qword [rsp + 0x20], r12
mov r8d, 4
mov dword [rbp - 0x48], eax
lea rdx, [rbp - 0x48]
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov r8d, dword [rbp - 0x48]
lea r9, [rbp - 0x28]
mov rcx, qword [rsp + 0x78]
lea rdx, [0x140008810]
mov qword [rsp + 0x20], r12
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [rbp - 0x48]
xor r9d, r9d
mov edx, dword [rbp - 0x14]
add eax, 4
mov rcx, qword [rsp + 0x78]
xor r8d, r8d
add dword [rbp - 0x80], eax
mov dword [rbp - 0x3c], 0x38
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
mov rcx, qword [rsp + 0x78]
lea r9, [rbp - 0x50]
mov r8d, 0xc
mov qword [rsp + 0x20], r12
lea rdx, [rbp - 0x40]
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [rbp - 0x80]
lea rcx, [rsp + 0x30]
mov dword [rbp - 0x38], eax
mov dword [rbp - 0x40], 4
call fcn.140003b50
mov edx, dword [rbp - 0x14]
xor r9d, r9d
mov rcx, qword [rsp + 0x78]
add rdx, 0xc
xor r8d, r8d
mov dword [rbp - 0x3c], eax
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
mov rcx, qword [rsp + 0x78]
lea r9, [rbp - 0x50]
mov r8d, 0xc
mov qword [rsp + 0x20], r12
lea rdx, [rbp - 0x40]
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov rcx, qword [rsp + 0x40]
lea r8, [rbp + 0x38]
mov r9d, 0x30
xor edx, edx
mov rdi, r12
call qword [sym.imp.KERNEL32.dll_VirtualQueryEx]
test rax, rax
je 0x140004514
mov qword [rsp + 0x170], r14
nop word [rax + rax]
cmp dword [rbp + 0x58], 0x1000
jne 0x1400044d7
mov rcx, qword [rbp - 0x68]
mov rsi, qword [rbp + 0x50]
mov r14, qword [rbp + 0x38]
test rcx, rcx
jne 0x14000447e
mov dword [rbp - 0x5c], 0x20
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
xor edx, edx
mov r8d, 0x200
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
jmp 0x1400044a9
mov eax, dword [rbp - 0x5c]
cmp dword [rbp - 0x60], eax
jb 0x1400044b0
add eax, eax
mov ebx, eax
shl rbx, 4
mov dword [rbp - 0x5c], eax
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8, qword [rbp - 0x68]
mov r9, rbx
mov rcx, rax
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov qword [rbp - 0x68], rax
mov rcx, rax
test rcx, rcx
je 0x1400044d3
mov eax, dword [rbp - 0x60]
add rax, rax
mov qword [rcx + rax*8], r14
mov ecx, dword [rbp - 0x60]
mov rax, qword [rbp - 0x68]
add rcx, rcx
mov qword [rax + rcx*8 + 8], rsi
inc dword [rbp - 0x60]
jmp 0x1400044d7
mov qword [rbp - 0x60], r12
mov rcx, qword [rbp + 0x50]
lea rax, [rcx + rdi]
cmp rax, rdi
jb 0x14000450c
mov rdi, qword [rbp + 0x38]
lea r8, [rbp + 0x38]
add rdi, rcx
mov r9d, 0x30
mov rcx, qword [rsp + 0x40]
mov rdx, rdi
call qword [sym.imp.KERNEL32.dll_VirtualQueryEx]
test rax, rax
jne 0x140004440
mov r14, qword [rsp + 0x170]
mov eax, dword [rbp - 0x80]
lea rcx, [rsp + 0x30]
mov dword [rbp - 0x38], eax
mov dword [rbp - 0x40], 9
call fcn.140003930
mov edx, dword [rbp - 0x14]
xor r9d, r9d
mov rcx, qword [rsp + 0x78]
add rdx, 0x18
xor r8d, r8d
mov dword [rbp - 0x3c], eax
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
mov rcx, qword [rsp + 0x78]
lea r9, [rbp - 0x50]
mov r8d, 0xc
mov qword [rsp + 0x20], r12
lea rdx, [rbp - 0x40]
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov edx, dword [rbp - 0x14]
xor r9d, r9d
mov rcx, qword [rsp + 0x78]
add edx, 0x24
xor r8d, r8d
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
mov rcx, qword [rsp + 0x78]
lea r9, [rbp - 0x50]
mov r8d, 0xc
mov qword [rsp + 0x20], r12
lea rdx, [0x140008778]
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov rcx, r15
call qword [sym.imp.dbghelp.dll_SymCleanup]
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8, qword [rbp - 0x78]
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapFree]
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8, qword [rbp - 0x68]
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapFree]
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8, qword [rsp + 0x60]
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapFree]
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8, qword [rsp + 0x50]
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov eax, 1
jmp 0x140004618
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 + 0x180]
mov r12, qword [rsp + 0x178]
mov rcx, qword [rbp + 0x68]
xor rcx, rsp
call fcn.1400055d0
add rsp, 0x188
pop r15
pop rdi
pop rbx
pop rbp
ret