Function at 0x140003350
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
push rdi
push r12
push r14
push r15
lea rbp, [rsp - 0x20]
sub rsp, 0x120
xor r12d, r12d
mov qword [rsp + 0x158], rsi
mov dword [rbp + 0x50], r12d
mov rdi, rcx
movzx eax, byte [rcx + 0x31]
cmp byte [rcx + 0x30], r12b
je 0x140003591
test al, al
mov byte [rcx + 0x30], r12b
lea rax, [rbp + 0x50]
mov qword [rbp + 0x50], rdx
lea r9, [rbp + 0x58]
lea r8, [rbp + 0x50]
je 0x14000349a
mov byte [rsp + 0x58], r12b
cmp rax, r9
je 0x1400033f6
lea rdx, [rsp + 0x58]
nop dword [rax]
nop dword [rax + rax]
movzx eax, byte [r8]
movzx ecx, al
and cl, 0xf
or cl, 0x30
mov byte [rdx - 1], cl
cmp cl, 0x39
jbe 0x1400033db
add cl, 7
mov byte [rdx - 1], cl
sub rdx, 2
shr al, 4
or al, 0x30
mov byte [rdx], al
cmp al, 0x39
jbe 0x1400033ee
add al, 7
mov byte [rdx], al
inc r8
cmp r8, r9
jne 0x1400033c0
mov rax, qword [0x1400b5948]
mov ebx, reloc.WS2_32.dll_recv
mov qword [rsp + 0x38], rbx
test rax, rax
jne 0x140003424
xor r8d, r8d
lea ecx, [rbx - 0xf]
mov edx, 0x100000
call qword [sym.imp.KERNEL32.dll_HeapCreate]
mov qword [0x1400b5948], rax
xor edx, edx
mov qword [rsp + 0x30], reloc.WS2_32.dll_recvfrom
mov rcx, rax
lea r8d, [rdx + 0x11]
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov rsi, rax
mov qword [rsp + 0x40], rax
lea rax, [rsp + 0x48]
cmp rsi, rax
je 0x14000347c
lea r8, [rsp + 0x48]
mov rcx, rsi
sub r8, rsi
mov edx, 2
nop
mov rax, qword [r8 + rcx]
mov qword [rcx], rax
lea rcx, [rcx + 8]
sub rdx, 1
jne 0x140003460
lea rcx, [rsi + rbx]
movzx eax, byte [rcx + r8]
mov byte [rcx], al
lea r8, [rsp + 0x30]
mov rcx, rdi
lea rdx, [rbp + 8]
call fcn.1400047c0
mov rcx, rax
mov ebx, listen
jmp 0x14000357b
mov byte [rsp + 0x40], r12b
cmp rax, r9
je 0x1400034e6
lea rdx, [rsp + 0x40]
nop dword [rax]
movzx eax, byte [r8]
movzx ecx, al
and cl, 0xf
or cl, 0x30
mov byte [rdx - 1], cl
cmp cl, 0x39
jbe 0x1400034cb
add cl, 7
mov byte [rdx - 1], cl
sub rdx, 2
shr al, 4
or al, 0x30
mov byte [rdx], al
cmp al, 0x39
jbe 0x1400034de
add al, 7
mov byte [rdx], al
inc r8
cmp r8, r9
jne 0x1400034b0
mov rax, qword [0x1400b5948]
mov ebx, reloc.WS2_32.dll_recv
mov qword [rsp + 0x68], rbx
test rax, rax
jne 0x140003514
xor r8d, r8d
lea ecx, [rbx - 0xf]
mov edx, 0x100000
call qword [sym.imp.KERNEL32.dll_HeapCreate]
mov qword [0x1400b5948], rax
xor edx, edx
mov qword [rsp + 0x60], reloc.WS2_32.dll_recvfrom
mov rcx, rax
lea r8d, [rdx + 0x11]
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov r9, rax
mov qword [rsp + 0x70], rax
lea rax, [rsp + 0x30]
cmp r9, rax
je 0x14000356c
lea r8, [rsp + 0x30]
mov rcx, r9
sub r8, r9
mov edx, 2
nop
mov rax, qword [r8 + rcx]
mov qword [rcx], rax
lea rcx, [rcx + 8]
sub rdx, 1
jne 0x140003550
lea rcx, [r9 + rbx]
movzx eax, byte [rcx + r8]
mov byte [rcx], al
mov rsi, qword [rsp + 0x40]
lea rcx, [rsp + 0x60]
mov ebx, recv
mov rax, qword [rcx + 8]
mov qword [rbp - 0x68], rax
mov rax, qword [rcx + 0x10]
mov qword [rbp - 0x60], rax
lea rax, [rbp - 0x70]
jmp 0x1400035df
test al, al
je 0x1400035b4
lea rcx, [rbp - 0x10]
call fcn.14000e4e0
mov r8, rax
lea rdx, [rbp - 0x28]
mov rcx, rdi
call fcn.140004670
mov ebx, 0xb0
jmp 0x1400035c2
lea rcx, [rbp - 0x40]
call fcn.14000e4e0
mov ebx, 0xc0
mov rsi, qword [rsp + 0x40]
mov rcx, rax
mov rax, qword [rax + 8]
mov qword [rbp - 0x80], rax
mov rax, qword [rcx + 0x10]
mov qword [rbp - 0x78], rax
lea rax, [rsp + 0x78]
mov rdx, qword [rcx]
mov r14, qword [rax + 8]
mov r15, qword [rax + 0x10]
mov qword [rcx + 0x10], r12
mov qword [rcx + 8], r12
mov qword [rcx], r12
mov qword [rbp - 0x58], rdx
mov qword [rbp - 0x50], r14
mov qword [rbp - 0x48], r15
mov qword [rax], r12
mov qword [rax + 8], r12
mov qword [rax + 0x10], r12
test bl, bl
jns 0x140003627
mov r8, qword [rbp - 0x78]
btr ebx, 7
mov rcx, qword [0x1400b5948]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
test bl, 0x40
je 0x140003642
mov r8, qword [rbp - 0x30]
and ebx, 0xffffffbf
mov rcx, qword [0x1400b5948]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
test bl, 0x20
je 0x14000365d
mov r8, qword [rbp - 0x18]
and ebx, 0xffffffdf
mov rcx, qword [0x1400b5948]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
test bl, 0x10
je 0x140003678
mov r8, qword [rbp]
and ebx, 0xffffffef
mov rcx, qword [0x1400b5948]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
test bl, 8
je 0x140003693
mov r8, qword [rbp - 0x60]
and ebx, 0xfffffff7
mov rcx, qword [0x1400b5948]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
test bl, 4
je 0x1400036ac
mov r8, qword [rsp + 0x70]
xor edx, edx
mov rcx, qword [0x1400b5948]
call qword [sym.imp.KERNEL32.dll_HeapFree]
test bl, 2
je 0x1400036c4
mov r8, qword [rbp + 0x18]
xor edx, edx
mov rcx, qword [0x1400b5948]
call qword [sym.imp.KERNEL32.dll_HeapFree]
test bl, 1
je 0x1400036db
mov rcx, qword [0x1400b5948]
mov r8, rsi
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov rsi, qword [rsp + 0x158]
cmp byte [rdi + 0x40], r12b
je 0x1400036fa
lea rdx, [rbp - 0x58]
mov rcx, rdi
call fcn.14000f9e0
jmp 0x14000379a
mov rax, qword [rdi + 0x18]
cmp rax, 1
jne 0x14000372c
mov rcx, qword [rdi]
lea r9, [0x1400b5958]
mov r8d, r14d
mov qword [rsp + 0x20], r12
mov rdx, r15
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov rdx, r14
mov rcx, rdi
call fcn.140004900
jmp 0x14000379a
mov rcx, rdi
test rax, rax
jne 0x140003759
mov rdx, r14
call fcn.140004900
mov rcx, qword [rdi]
lea r9, [0x1400b5958]
mov r8d, r14d
mov qword [rsp + 0x20], r12
mov rdx, r15
call qword [sym.imp.KERNEL32.dll_WriteFile]
jmp 0x14000379a
mov rbx, qword [rdi + 0x10]
xor r8d, r8d
shr rbx, 1
mov rdx, rbx
call fcn.140004b20
mov rcx, qword [rdi]
lea r9, [0x1400b5958]
mov r8d, r14d
mov qword [rsp + 0x20], r12
mov rdx, r15
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov edx, dword [rdi + 0x10]
mov r8b, 1
and edx, 1
mov rcx, rdi
add rdx, rbx
call fcn.140004b20
mov rcx, qword [0x1400b5948]
mov r8, r15
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov rbx, qword [rsp + 0x160]
mov rax, rdi
add rsp, 0x120
pop r15
pop r14
pop r12
pop rdi
pop rbp
ret