Function at 0x140002d20
Capabilities:
Write file on windows

Disassembly:
mov rax, rsp
mov qword [rax + 0x20], rbx
push rbp
push rsi
push r12
push r13
push r14
lea rbp, [rax - 0x5f]
sub rsp, 0x100
xor r13d, r13d
mov qword [rax + 0x10], rdi
mov dword [rbp + 0x67], r13d
mov r8d, edx
mov rsi, rcx
mov qword [rax + 0x18], r15
movzx eax, byte [rcx + 0x31]
cmp byte [rcx + 0x30], r13b
je 0x140002f2b
test al, al
mov byte [rcx + 0x30], r13b
lea rax, [rbp + 0x67]
mov dword [rbp + 0x67], edx
lea r9, [rbp + 0x6b]
lea r8, [rbp + 0x67]
je 0x140002e4e
mov byte [rbp - 0x79], r13b
cmp rax, r9
je 0x140002dc6
lea rdx, [rbp - 0x79]
nop word [rax + rax]
movzx eax, byte [r8]
movzx ecx, al
and cl, 0xf
or cl, 0x30
mov byte [rdx - 1], cl
cmp cl, 0x39
jbe 0x140002dab
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 0x140002dbe
add al, 7
mov byte [rdx], al
inc r8
cmp r8, r9
jne 0x140002d90
mov rax, qword [0x1400b5948]
mov qword [rsp + 0x38], 8
test rax, rax
jne 0x140002df3
xor r8d, r8d
lea ecx, [rax + 1]
mov edx, 0x100000
call qword [sym.imp.KERNEL32.dll_HeapCreate]
mov qword [0x1400b5948], rax
mov r14d, 9
xor edx, edx
mov r8d, r14d
mov qword [rsp + 0x30], r14
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov rdi, rax
mov qword [rsp + 0x40], rax
lea rax, [rsp + 0x48]
cmp rdi, rax
je 0x140002e2d
mov rcx, qword [rsp + 0x48]
mov qword [rdi], rcx
movzx ecx, byte [rbp - 0x79]
mov byte [rdi + 8], cl
lea r8, [rsp + 0x30]
mov rcx, rsi
lea rdx, [rbp + 0x1f]
call fcn.1400047c0
mov rcx, rax
mov ebx, listen
mov r14, qword [rax]
jmp 0x140002f02
mov byte [rbp - 0x69], r13b
cmp rax, r9
je 0x140002e96
lea rdx, [rbp - 0x69]
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 0x140002e7b
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 0x140002e8e
add al, 7
mov byte [rdx], al
inc r8
cmp r8, r9
jne 0x140002e60
mov rax, qword [0x1400b5948]
mov qword [rsp + 0x38], 8
test rax, rax
jne 0x140002ec3
xor r8d, r8d
lea ecx, [rax + 1]
mov edx, 0x100000
call qword [sym.imp.KERNEL32.dll_HeapCreate]
mov qword [0x1400b5948], rax
mov r14d, 9
xor edx, edx
mov r8d, r14d
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
lea rcx, [rbp - 0x71]
mov qword [rsp + 0x40], rax
cmp rax, rcx
je 0x140002ef3
mov rcx, qword [rbp - 0x71]
mov qword [rax], rcx
movzx ecx, byte [rbp - 0x69]
mov byte [rax + 8], cl
mov rdi, qword [rsp + 0x40]
lea rcx, [rsp + 0x30]
mov ebx, recv
mov rax, qword [rcx + 8]
mov qword [rbp - 0x21], rax
mov rax, qword [rcx + 0x10]
mov qword [rbp - 0x19], rax
lea rax, [rbp - 0x29]
mov qword [rcx], r13
mov qword [rcx + 8], r13
mov qword [rcx + 0x10], r13
mov r15, qword [rsp + 0x40]
jmp 0x140003166
mov ebx, 0xa
mov r9d, ebx
test al, al
je 0x14000303e
mov byte [rbp - 0x57], r13b
nop
dec r9
lea rdi, [rbp - 0x61]
add rdi, r9
mov eax, 0xcccccccd
mul r8d
shr edx, 3
movzx eax, dl
shl al, 2
lea ecx, [rax + rdx]
add cl, cl
sub r8b, cl
or r8b, 0x30
mov byte [rdi], r8b
mov r8d, edx
test edx, edx
jne 0x140002f40
mov rax, qword [0x1400b5948]
sub rbx, r9
mov qword [rsp + 0x38], rbx
test rax, rax
jne 0x140002f9d
xor r8d, r8d
lea ecx, [rax + 1]
mov edx, 0x100000
call qword [sym.imp.KERNEL32.dll_HeapCreate]
mov qword [0x1400b5948], rax
inc rbx
xor edx, edx
mov r8, rbx
mov qword [rsp + 0x30], rbx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov qword [rsp + 0x40], rax
mov r15, rax
cmp rax, rdi
je 0x140003020
test rbx, rbx
je 0x140003020
mov rdx, rbx
mov r9, r13
shr rdx, 3
test rdx, rdx
je 0x140002ff1
mov r8, rdi
mov rcx, rax
sub r8, rax
mov r9, rdx
mov rax, qword [r8 + rcx]
mov qword [rcx], rax
lea rcx, [rcx + 8]
sub rdx, 1
jne 0x140002fe0
lea rax, [r9*8]
cmp rax, rbx
jae 0x140003020
sub rdi, r15
lea rcx, [r15 + rax]
sub rbx, rax
nop dword [rax + rax]
movzx eax, byte [rdi + rcx]
mov byte [rcx], al
lea rcx, [rcx + 1]
sub rbx, 1
jne 0x140003010
lea r8, [rsp + 0x30]
mov rcx, rsi
lea rdx, [rbp + 7]
call fcn.140004670
mov rcx, rax
mov ebx, 0xb0
jmp 0x14000313f
mov byte [rbp - 0x47], r13b
nop dword [rax]
nop word [rax + rax]
dec r9
lea rdi, [rbp - 0x51]
add rdi, r9
mov eax, 0xcccccccd
mul r8d
shr edx, 3
movzx eax, dl
shl al, 2
lea ecx, [rax + rdx]
add cl, cl
sub r8b, cl
or r8b, 0x30
mov byte [rdi], r8b
mov r8d, edx
test edx, edx
jne 0x140003050
mov rax, qword [0x1400b5948]
sub rbx, r9
mov qword [rsp + 0x38], rbx
test rax, rax
jne 0x1400030ad
xor r8d, r8d
lea ecx, [rax + 1]
mov edx, 0x100000
call qword [sym.imp.KERNEL32.dll_HeapCreate]
mov qword [0x1400b5948], rax
inc rbx
xor edx, edx
mov r8, rbx
mov qword [rsp + 0x30], rbx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov qword [rsp + 0x40], rax
mov r9, rax
cmp rax, rdi
je 0x140003130
test rbx, rbx
je 0x140003130
mov rdx, rbx
mov r10, r13
shr rdx, 3
test rdx, rdx
je 0x140003101
mov r8, rdi
mov rcx, rax
sub r8, rax
mov r10, rdx
mov rax, qword [r8 + rcx]
mov qword [rcx], rax
lea rcx, [rcx + 8]
sub rdx, 1
jne 0x1400030f0
lea rax, [r10*8]
cmp rax, rbx
jae 0x140003130
sub rdi, r9
lea rcx, [r9 + rax]
sub rbx, rax
nop dword [rax + rax]
movzx eax, byte [rdi + rcx]
mov byte [rcx], al
lea rcx, [rcx + 1]
sub rbx, 1
jne 0x140003120
mov r15, qword [rsp + 0x40]
lea rcx, [rsp + 0x30]
mov ebx, 0xc0
mov rax, qword [rcx + 8]
mov r14, qword [rcx]
mov qword [rbp - 0x39], rax
mov rax, qword [rcx + 0x10]
mov qword [rbp - 0x31], rax
lea rax, [rbp - 0x41]
mov qword [rcx], r13
mov qword [rcx + 8], r13
mov qword [rcx + 0x10], r13
mov rdi, qword [rsp + 0x40]
mov r12, qword [rax + 0x10]
mov qword [rbp - 0x11], r14
mov r14, qword [rax + 8]
mov qword [rbp - 9], r14
mov qword [rbp - 1], r12
mov qword [rax], r13
mov qword [rax + 8], r13
mov qword [rax + 0x10], r13
test bl, bl
jns 0x1400031a0
mov r8, qword [rbp - 0x31]
btr ebx, 7
mov rcx, qword [0x1400b5948]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
test bl, 0x40
je 0x1400031bc
mov r8, qword [rsp + 0x40]
and ebx, 0xffffffbf
mov rcx, qword [0x1400b5948]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
test bl, 0x20
je 0x1400031d7
mov r8, qword [rbp + 0x17]
and ebx, 0xffffffdf
mov rcx, qword [0x1400b5948]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
test bl, 0x10
je 0x1400031f1
mov rcx, qword [0x1400b5948]
and ebx, 0xffffffef
mov r8, r15
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov r15, qword [rsp + 0x140]
test bl, 8
je 0x140003214
mov r8, qword [rbp - 0x19]
and ebx, 0xfffffff7
mov rcx, qword [0x1400b5948]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
test bl, 4
je 0x14000322d
mov r8, qword [rsp + 0x40]
xor edx, edx
mov rcx, qword [0x1400b5948]
call qword [sym.imp.KERNEL32.dll_HeapFree]
test bl, 2
je 0x140003245
mov r8, qword [rbp + 0x2f]
xor edx, edx
mov rcx, qword [0x1400b5948]
call qword [sym.imp.KERNEL32.dll_HeapFree]
test bl, 1
je 0x14000325c
mov rcx, qword [0x1400b5948]
mov r8, rdi
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov rdi, qword [rsp + 0x138]
cmp byte [rsi + 0x40], r13b
je 0x14000327b
lea rdx, [rbp - 0x11]
mov rcx, rsi
call fcn.14000f9e0
jmp 0x14000331b
mov rax, qword [rsi + 0x18]
cmp rax, 1
jne 0x1400032ad
mov rcx, qword [rsi]
lea r9, [0x1400b5958]
mov r8d, r14d
mov qword [rsp + 0x20], r13
mov rdx, r12
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov rdx, r14
mov rcx, rsi
call fcn.140004900
jmp 0x14000331b
mov rcx, rsi
test rax, rax
jne 0x1400032da
mov rdx, r14
call fcn.140004900
mov rcx, qword [rsi]
lea r9, [0x1400b5958]
mov r8d, r14d
mov qword [rsp + 0x20], r13
mov rdx, r12
call qword [sym.imp.KERNEL32.dll_WriteFile]
jmp 0x14000331b
mov rbx, qword [rsi + 0x10]
xor r8d, r8d
shr rbx, 1
mov rdx, rbx
call fcn.140004b20
mov rcx, qword [rsi]
lea r9, [0x1400b5958]
mov r8d, r14d
mov qword [rsp + 0x20], r13
mov rdx, r12
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov edx, dword [rsi + 0x10]
mov r8b, 1
and edx, 1
mov rcx, rsi
add rdx, rbx
call fcn.140004b20
mov rcx, qword [0x1400b5948]
mov r8, r12
xor edx, edx
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov rbx, qword [rsp + 0x148]
mov rax, rsi
add rsp, 0x100
pop r14
pop r13
pop r12
pop rsi
pop rbp
ret