Function at 0x14002e4f0
Capabilities:
Acquire debug privileges
Check if file exists
Create directory
Terminate process

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
mov qword [rsp + 0x20], rsi
push rdi
push r14
push r15
sub rsp, 0x80
mov rax, qword [0x14036e3c8]
xor rax, rsp
mov qword [rsp + 0x70], rax
mov rdi, rcx
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov rcx, rax
lea r8, [rsp + 0x30]
mov edx, 0x20
call qword [sym.imp.ADVAPI32.dll_OpenProcessToken]
xor r15d, r15d
test eax, eax
je 0x14002e5d4
mov dword [rsp + 0x60], 1
lea r8, [rsp + 0x64]
lea rdx, str.SeDebugPrivilege
xor ecx, ecx
call qword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueW]
test eax, eax
jne 0x14002e57b
lea r8, str.test
lea rdx, str.Cant_lookup_privilege_value._n
lea rcx, [0x140289688]
call fcn.140039ff0
mov dword [rsp + 0x6c], 2
mov qword [rsp + 0x28], r15
mov qword [rsp + 0x20], r15
mov r9d, reloc.WS2_32.dll_recv
lea r8, [rsp + 0x60]
xor edx, edx
mov rcx, qword [rsp + 0x30]
call qword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
test eax, eax
jne 0x14002e5c3
lea r8, str.test
lea rdx, str.Cant_adjust_privilege_value._n
lea rcx, [0x140289688]
call fcn.140039ff0
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rcx, qword [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov r14, 0xffffffffffffffff
cmp byte [rdi + 0x68], r15b
jne 0x14002e70a
call fcn.140025ee0
lea rcx, [rsp + 0x40]
call fcn.140034df0
nop
mov rdx, qword [rax]
lea rcx, [rsp + 0x48]
call fcn.14002e130
mov rsi, r15
mov rax, qword [rsp + 0x50]
mov rcx, qword [rsp + 0x48]
sub rax, rcx
sar rax, 2
test rax, rax
je 0x14002e6a7
nop
mov ebp, dword [rcx + rsi*4]
mov r8d, ebp
xor edx, edx
mov ecx, 0x1fffff
call qword [sym.imp.KERNEL32.dll_OpenProcess]
mov rbx, rax
test rax, rax
je 0x14002e652
mov edx, 0xfa0
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov r8d, ebp
xor edx, edx
lea ecx, [rdx + 1]
call qword [sym.imp.KERNEL32.dll_OpenProcess]
mov rbx, rax
test rax, rax
je 0x14002e68a
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_TerminateProcess]
mov edx, 0x3e8
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
inc rsi
mov rax, qword [rsp + 0x50]
mov rcx, qword [rsp + 0x48]
sub rax, rcx
sar rax, 2
cmp rsi, rax
jb 0x14002e620
test rcx, rcx
je 0x14002e6eb
mov rax, qword [rsp + 0x58]
sub rax, rcx
sar rax, 2
lea rdx, [rax*4]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14002e6e5
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x14002e901
call fcn.1402434a4
nop
mov rdx, qword [rsp + 0x40]
add rdx, 0xffffffffffffffe8
mov eax, r14d
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x14002e70a
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + ioctlsocket]
mov rcx, qword [rdi]
test rcx, rcx
je 0x14002e736
lea r8, [0x140368408]
cmp qword [reloc.WS2_32.dll_getsockopt], 8
cmovae r8, qword [0x140368408]
xor r9d, r9d
mov edx, 0x603
call fcn.140077720
mov rcx, qword [rdi + 0x70]
call qword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x14002e750
xor edx, edx
mov rcx, qword [rdi + 0x70]
call qword [sym.imp.KERNEL32.dll_CreateDirectoryW]
mov rcx, qword [rdi + 0x70]
call fcn.140032330
test eax, eax
jne 0x14002e795
lea r8, [0x140284a60]
mov rdx, qword [rdi + 0x70]
lea rcx, str.directory_has_no_privileges
call fcn.140039ff0
mov rcx, qword [rdi]
test rcx, rcx
je 0x14002e7ec
lea r8, [0x1403684c8]
cmp qword [reloc.WS2_32.dll_getsockopt], 8
cmovae r8, qword [0x1403684c8]
jmp 0x14002e7dc
mov rcx, qword [rdi + 0x78]
call qword [sym.imp.SHLWAPI.dll_PathFileExistsW]
mov rdx, qword [rdi + 0x80]
test eax, eax
jne 0x14002e7f3
mov r8, rdx
mov rdx, qword [rdi + 0x78]
lea rcx, str.non_from_dir
call fcn.140039ff0
mov rcx, qword [rdi]
test rcx, rcx
je 0x14002e7ec
lea r8, [0x1403684e8]
cmp qword [reloc.WS2_32.dll_getsockopt], 8
cmovae r8, qword [0x1403684e8]
mov r9d, 1
mov edx, 0x603
call fcn.140077720
xor eax, eax
jmp 0x14002e8d7
mov rcx, rdi
call fcn.14001e7e0
mov rdx, qword [rdi + 0x80]
lea r8, [0x140284a60]
test eax, eax
jne 0x14002e820
lea rcx, str.clean_Directory_error
call fcn.140039ff0
xor eax, eax
jmp 0x14002e8d7
lea rcx, str.clean_Directory_succeed
call fcn.140039ff0
mov rcx, qword [rdi]
test rcx, rcx
je 0x14002e845
xor r9d, r9d
mov edx, 0x601
lea r8d, [r9 + 3]
call fcn.140077720
mov rcx, qword [rdi + 0x88]
sub rcx, 0x18
call fcn.14000d080
add rax, 0x18
mov qword [rsp + 0x38], rax
lea rdx, str.courgette.dll
mov rax, r14
nop dword [rax + rax]
inc rax
cmp word [rdx + rax*2], 0
jne 0x14002e870
mov r8d, eax
lea rcx, [rsp + 0x38]
call fcn.1400127b0
mov rbx, qword [rsp + 0x38]
mov rcx, rbx
call fcn.14003b0f0
test al, al
jne 0x14002e8b4
lea r8, [0x140284a60]
mov rdx, qword [rdi + 0x88]
lea rcx, str.init_courgette_fail.
call fcn.140039ff0
jmp 0x14002e8ba
mov r15d, 1
lea rdx, [rbx - 0x18]
lock xadd dword [rdx + 0x10], r14d
sub r14d, 1
jg 0x14002e8d4
mov rcx, qword [rdx]
mov r8, qword [rcx]
call qword [rioctlsocket + 8]
mov eax, r15d
mov rcx, qword [rsp + 0x70]
xor rcx, rsp
call fcn.1402435c0
lea r11, [rsp + 0x80]
mov rbx, qword [r11 + 0x28]
mov rbp, qword [r11 + 0x30]
mov rsi, qword [r11 + 0x38]
mov rsp, r11
pop r15
pop r14
pop rdi
ret
call fcn.14024a84c
nop
int3