Function at 0x140004990
Capabilities:
Create directory

Disassembly:
mov qword [rsp + 8], rcx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x30
mov qword [rsp + 0x28], 0xfffffffffffffffe
mov qword [rsp + 0x78], rbx
mov rbx, rdx
call fcn.14000ab7c
mov rdx, rax
xor r12d, r12d
mov ecx, r12d
test rax, rax
setne cl
test ecx, ecx
jne 0x1400049d8
mov ecx, 0x80004005
call fcn.140005bc0
int3
mov rax, qword [rax]
mov rcx, rdx
call qword [rax + reloc.OLEAUT32.dll_SafeArrayGetElement]
lea rdi, [rax + 0x18]
mov qword [rsp + 0x80], rdi
or r15, 0xffffffffffffffff
test rbx, rbx
je 0x140004a32
test rbx, 0xffffffffffff0000
jne 0x140004a23
movzx ebx, bx
mov ecx, ebx
call fcn.14000a58c
test rax, rax
je 0x140004a50
mov r8d, ebx
mov rdx, rax
lea rcx, [rsp + 0x80]
call fcn.140005620
jmp 0x140004a48
mov rax, r15
inc rax
cmp word [rbx + rax*2], 0
jne 0x140004a26
jmp 0x140004a35
mov eax, r12d
mov r8d, eax
mov rdx, rbx
lea rcx, [rsp + 0x80]
call fcn.140005940
mov rdi, qword [rsp + 0x80]
call fcn.14000ab7c
mov rdx, rax
mov ecx, r12d
test rax, rax
setne cl
test ecx, ecx
jne 0x140004a70
mov ecx, 0x80004005
call fcn.140005bc0
int3
mov rax, qword [rax]
mov rcx, rdx
call qword [rax + reloc.OLEAUT32.dll_SafeArrayGetElement]
lea rbx, [rax + 0x18]
mov qword [rsp + 0x70], rbx
lea rdx, [0x14021e440]
test rdx, 0xffffffffffff0000
jne 0x140004ab3
movzx esi, dx
mov ecx, esi
call fcn.14000a58c
test rax, rax
je 0x140004ac5
mov r8d, esi
mov rdx, rax
lea rcx, [rsp + 0x70]
call fcn.140005620
jmp 0x140004ac0
xor r8d, r8d
lea rcx, [rsp + 0x70]
call fcn.140005940
mov rbx, qword [rsp + 0x70]
mov esi, 1
lea rax, [rdi - 0x10]
mov qword [rsp + 0x20], rax
test esi, esi
js 0x140004afe
cmp esi, dword [rax]
jg 0x140004afe
movsxd rax, esi
lea rcx, [rdi + rax*2]
lea rdx, [0x14021e1bc]
call fcn.140193bd4
mov rsi, rax
test rax, rax
je 0x140004afe
sub rsi, rdi
sar rsi, 1
jmp 0x140004b01
mov esi, r15d
inc esi
mov r8d, esi
lea rdx, [rsp + 0x88]
lea rcx, [rsp + 0x80]
call fcn.140004fa0
nop
mov r13, qword [rax]
lea rcx, [r13 - 0x18]
lea rdi, [rbx - 0x18]
cmp rcx, rdi
je 0x140004c3b
cmp dword [rdi + 0x10], 0
jl 0x140004b68
mov rax, qword [rdi]
cmp qword [rcx], rax
jne 0x140004b68
call fcn.140005af0
mov rbx, rax
lock add dword [rdi + 0x10], 0xffffffff
jg 0x140004b5a
mov rcx, qword [rdi]
mov r8, qword [rcx]
mov rdx, rdi
call qword [rreloc.OLEAUT32.dll_VariantClear + 8]
lea rax, [rbx + 0x18]
mov qword [rsp + 0x70], rax
jmp 0x140004c3b
movsxd rbp, dword [r13 - 0x10]
test ebp, ebp
jne 0x140004bbe
mov r14, qword [rdi]
cmp dword [rdi + 8], ebp
je 0x140004c3b
cmp dword [rdi + 0x10], ebp
jge 0x140004b97
cmp dword [rbx - 0xc], ebp
jl 0x140004c97
mov dword [rbx - 0x10], r12d
mov word [rbx], r12w
jmp 0x140004c3b
lock add dword [rdi + 0x10], 0xffffffff
jg 0x140004baa
mov rcx, qword [rdi]
mov rax, qword [rcx]
mov rdx, rdi
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov rax, qword [r14]
mov rcx, r14
call qword [rax + reloc.OLEAUT32.dll_SafeArrayGetElement]
add rax, 0x18
mov qword [rsp + 0x70], rax
jmp 0x140004c3b
test r13, r13
je 0x140004cb8
mov r12d, dword [rbx - 0x10]
mov r14, r13
sub r14, rbx
sar r14, 1
test ebp, ebp
js 0x140004cad
mov ecx, 1
sub ecx, dword [rdi + 0x10]
mov eax, dword [rdi + 0xc]
sub eax, ebp
or eax, ecx
jge 0x140004bfe
mov edx, ebp
lea rcx, [rsp + 0x70]
call fcn.1400058e0
mov rbx, qword [rsp + 0x70]
lea rdi, [rbp*2]
movsxd rdx, dword [rbx - 0xc]
mov rcx, rbx
mov r9, rdi
add rdx, rdx
cmp r14, r12
ja 0x140004c23
lea r8, [rbx + r14*2]
call fcn.1401931e8
jmp 0x140004c2b
mov r8, r13
call fcn.140193160
cmp ebp, dword [rbx - 0xc]
jg 0x140004ca2
mov dword [rbx - 0x10], ebp
xor r12d, r12d
mov word [rdi + rbx], r12w
mov rdx, qword [rsp + 0x88]
add rdx, 0xffffffffffffffe8
lock add dword [rdx + 0x10], 0xffffffff
jg 0x140004c57
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov rbx, qword [rsp + 0x70]
movzx eax, word [rbx]
cmp ax, word [0x14021e440]
jne 0x140004c6d
mov eax, r12d
jmp 0x140004c72
sbb eax, eax
or eax, 1
test eax, eax
je 0x140004c81
xor edx, edx
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test esi, esi
jle 0x140004cc3
mov rdi, qword [rsp + 0x80]
mov rax, qword [rsp + 0x20]
jmp 0x140004ad3
mov ecx, 0x80070057
call fcn.140005bc0
int3
mov ecx, 0x80070057
call fcn.140005bc0
int3
mov ecx, 0x80070057
call fcn.140005bc0
int3
mov ecx, 0x80070057
call fcn.140005bc0
nop
lea rdx, [rbx - 0x18]
lock add dword [rdx + 0x10], 0xffffffff
jg 0x140004cd8
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
mov rdx, qword [rsp + 0x80]
add rdx, 0xffffffffffffffe8
lock add dword [rdx + 0x10], 0xffffffff
jg 0x140004cf4
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov rbx, qword [rsp + 0x78]
add rsp, 0x30
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret