Function at 0x140005130
Capabilities:
Check if file exists
Create directory
Get file attributes

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
push rsi
push rdi
push r14
sub rsp, 0x80
mov rax, qword [0x1400cf070]
xor rax, rsp
mov qword [rsp + 0x78], rax
mov rsi, rcx
mov qword [rsp + 0x40], rcx
mov rdx, qword [rcx]
movsxd rcx, dword [rdx - 0x10]
cmp ecx, 2
jge 0x140005176
add rdx, 0xffffffffffffffe8
mov edi, 0xffffffff
jmp 0x140005455
lea r8d, [rcx - 1]
cmp r8d, ecx
jg 0x14000547a
mov edi, 0xffffffff
cmp byte [rcx + rdx - 1], 0x5c
jne 0x1400051cd
lea rdx, [rsp + 0x30]
mov rcx, rsi
call fcn.140008560
nop
mov rdx, rax
mov rcx, rsi
call fcn.140008660
nop
mov rdx, qword [rsp + 0x30]
add rdx, 0xffffffffffffffe8
mov eax, edi
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x1400051c7
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.WS2_32.dll_htonl]
mov rdx, qword [rsi]
mov ecx, dword [rdx - 0x10]
add rdx, 0xffffffffffffffe8
test ecx, ecx
jg 0x1400051da
jmp 0x140005455
cmp ecx, 3
mov rcx, rdx
jg 0x140005244
call fcn.140008980
lea rbx, [rax + 0x18]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x140005204
test al, 0x10
je 0x140005204
mov ebp, 1
jmp 0x140005206
xor ebp, ebp
lea rdx, [rbx - 0x18]
mov eax, edi
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x140005220
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.WS2_32.dll_htonl]
nop
mov rdx, qword [rsi]
sub rdx, 0x18
lock xadd dword [rdx + 0x10], edi
test ebp, ebp
je 0x14000545a
sub edi, 1
jg 0x14000529e
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.WS2_32.dll_htonl]
jmp 0x14000529e
call fcn.140008980
lea r14, [rax + 0x18]
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_GetFileAttributesA]
xor ebp, ebp
cmp eax, 0xffffffff
je 0x140005264
test al, 0x10
lea ebx, [rbp + 1]
jne 0x140005266
mov ebx, ebp
lea rdx, [r14 - 0x18]
mov eax, edi
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x14000527f
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.WS2_32.dll_htonl]
test ebx, ebx
je 0x1400052c8
mov rdx, qword [rsi]
sub rdx, 0x18
lock xadd dword [rdx + 0x10], edi
sub edi, 1
jg 0x14000529e
mov rcx, qword [rdx]
mov r8, qword [rcx]
call qword [rreloc.WS2_32.dll_htonl + 8]
mov eax, 1
mov rcx, qword [rsp + 0x78]
xor rcx, rsp
call fcn.140073640
lea r11, [rsp + 0x80]
mov rbx, qword [r11 + 0x28]
mov rbp, qword [r11 + 0x30]
mov rsp, r11
pop r14
pop rdi
pop rsi
ret
call fcn.140001a00
nop
mov rcx, rax
test rax, rax
je 0x14000546f
mov rax, qword [rax]
call qword [rax + Ordinal_26]
lea rbx, [rax + 0x18]
mov qword [rsp + 0x70], rbx
mov edx, 0x5c
mov rcx, qword [rsi]
call qword [sym.imp.api_ms_win_crt_multibyte_l1_1_0.dll__mbsrchr]
test rax, rax
jne 0x140005300
mov eax, edi
jmp 0x140005302
sub eax, dword [rsi]
mov r8d, eax
lea rdx, [rsp + 0x38]
mov rcx, rsi
call fcn.140008560
nop
mov rdx, qword [rax]
lea rcx, [rdx - 0x18]
add rbx, 0xffffffffffffffe8
cmp rcx, rbx
je 0x14000536c
cmp dword [rbx + 0x10], 0
jl 0x14000535d
mov rax, qword [rbx]
cmp qword [rcx], rax
jne 0x14000535d
call fcn.140008980
mov r14, rax
mov ecx, edi
lock xadd dword [rbx + 0x10], ecx
sub ecx, 1
jg 0x140005352
mov rcx, qword [rbx]
mov r8, qword [rcx]
mov rdx, rbx
call qword [rreloc.WS2_32.dll_htonl + 8]
lea rax, [r14 + 0x18]
mov qword [rsp + 0x70], rax
jmp 0x14000536c
mov r8d, dword [rdx - 0x10]
lea rcx, [rsp + 0x70]
call fcn.140002a90
nop
mov rdx, qword [rsp + 0x38]
add rdx, 0xffffffffffffffe8
mov eax, edi
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x14000538a
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.WS2_32.dll_htonl]
mov rax, qword [rsp + 0x70]
cmp dword [rax - 0x10], 0
jg 0x1400053b1
lea rdx, [rax - 0x18]
mov eax, edi
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x14000544e
mov rcx, qword [rdx]
jmp 0x140005447
lea rbx, [rax - 0x18]
mov rcx, rbx
call fcn.140008980
add rax, 0x18
mov qword [rsp + 0x20], rax
lea rcx, [rsp + 0x20]
call fcn.140005130
test eax, eax
je 0x140005435
mov dword [rsp + 0x58], Ordinal_27
mov qword [rsp + 0x60], rbp
mov dword [rsp + 0x68], ebp
lea rdx, [rsp + 0x58]
mov rcx, qword [rsi]
call qword [sym.imp.KERNEL32.dll_CreateDirectoryA]
cmp eax, 1
sete bpl
mov eax, edi
lock xadd dword [rbx + 0x10], eax
sub eax, 1
jg 0x140005413
mov rcx, qword [rbx]
mov rax, qword [rcx]
mov rdx, rbx
call qword [rax + reloc.WS2_32.dll_htonl]
nop
mov rdx, qword [rsi]
sub rdx, 0x18
lock xadd dword [rdx + 0x10], edi
sub edi, 1
jg 0x14000542e
mov rcx, qword [rdx]
mov r8, qword [rcx]
call qword [rreloc.WS2_32.dll_htonl + 8]
mov eax, ebp
jmp 0x1400052a3
mov eax, edi
lock xadd dword [rbx + 0x10], eax
sub eax, 1
jg 0x14000544e
mov rcx, qword [rbx]
mov rdx, rbx
mov rax, qword [rcx]
call qword [rax + reloc.WS2_32.dll_htonl]
nop
mov rdx, qword [rsi]
sub rdx, 0x18
lock xadd dword [rdx + 0x10], edi
sub edi, 1
jg 0x140005468
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.WS2_32.dll_htonl]
xor eax, eax
jmp 0x1400052a3
mov ecx, 0x80004005
call fcn.140001860
int3
mov ecx, 0x80070057
call fcn.140001860
int3