Function at 0x140059d90
Capabilities:
Create directory

Disassembly:
push rbp
push rsi
push rdi
lea rbp, [rsp - 0x480]
sub rsp, 0x580
mov qword [rsp + 0x40], 0xfffffffffffffffe
mov qword [rsp + 0x5b0], rbx
mov rax, qword [0x140109010]
xor rax, rsp
mov qword [rbp + 0x470], rax
mov rbx, rdx
mov rsi, rcx
mov rax, qword [rdx + 0x10]
dec rax
cmp rax, 0x102
ja 0x140059fd3
lea rcx, [rsp + 0x20]
call fcn.140069ba0
lea rcx, [rsp + 0x20]
call fcn.140036630
movzx edi, al
mov rdx, qword [rsp + 0x38]
cmp rdx, 8
jb 0x140059e3a
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x20]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140059e35
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140059e35
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.140093ce8
test dil, dil
jne 0x140059fd3
xor edx, edx
mov r8d, 0x20a
lea rcx, [rbp + 0x50]
call sub.VCRUNTIME140.dll_memset
mov r8, rbx
cmp qword [rbx + 0x18], 8
jb 0x140059e61
mov r8, qword [rbx]
mov edx, 0x105
lea rcx, [rbp + 0x50]
call qword [sym.imp.huawei_secure_c.dll_wcscpy_s]
test eax, eax
jne 0x140059fd3
lea rcx, [rbp + 0x50]
call qword [sym.imp.KERNEL32.dll_lstrlenW]
dec eax
cmp eax, 0x102
ja 0x140059fd3
cdqe
lea rcx, [rax + rax]
movzx eax, word [rbp + rcx + 0x50]
xor edi, edi
cmp ax, 0x5c
je 0x140059ea8
cmp ax, 0x2f
jne 0x140059eba
cmp rcx, 0x20a
jae 0x14005a0e5
mov word [rbp + rcx + 0x50], di
mov edx, 0x104
lea rcx, [rbp + 0x50]
call qword [sym.imp.api_ms_win_core_path_l1_1_0.dll_PathCchRemoveFileSpec]
test eax, eax
jne 0x140059fd3
lea rcx, [rbp + 0x50]
call qword [sym.imp.SHLWAPI.dll_PathIsDirectoryW]
test eax, eax
jne 0x140059ff7
movdqa xmm0, xmmword [0x1400cbd30]
movdqu xmmword [rsp + 0x30], xmm0
mov word [rsp + 0x20], di
lea rdx, [rbp + 0x50]
lea rcx, [rsp + 0x20]
call sym.HwSettings.exe_public:_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t______ptr64___cdecl_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::assign_wchar_t_const__const___ptr64____ptr64
nop
lea rdx, [rsp + 0x20]
mov rcx, rsi
call fcn.140059d90
test al, al
sete dil
mov rdx, qword [rsp + 0x38]
cmp rdx, 8
jb 0x140059f5d
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x20]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140059f58
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140059f58
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.140093ce8
test dil, dil
je 0x140059ff7
lea rcx, [rsp + 0x50]
call fcn.1400124e0
nop
lea rdx, str.CreateDirectory_parentDir_failed.
lea rcx, [rsp + 0x60]
call fcn.140013a90
mov rcx, rax
lea rdx, [0x1400b7d10]
call fcn.1400138a0
mov rcx, rax
lea rdx, str.Hwa::Ux::HwSettingWnd::CreateRecursiveDirectory
call fcn.140013a90
mov rcx, rax
lea rdx, [0x1400b7d0c]
call fcn.1400138a0
call qword [sym.imp.LogHelper.dll_public:_static_class_HwLogger____ptr64___cdecl_HwLogger::GetInstance_void_]
mov rcx, rax
lea r8, [rsp + 0x50]
mov edx, 4
call qword [sym.imp.LogHelper.dll_public:_void___cdecl_HwLogger::Log_enum_LOG_MESSAGE_LEVEL__class_std::basic_stringstream_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t______ptr64____ptr64]
nop
lea rcx, [rsp + 0x50]
call fcn.14000e840
xor al, al
mov rcx, qword [rbp + 0x470]
xor rcx, rsp
call fcn.140093940
mov rbx, qword [rsp + 0x5b0]
add rsp, 0x580
pop rdi
pop rsi
pop rbp
ret
xor edx, edx
mov r8d, 0x208
lea rcx, [rbp + 0x260]
call sub.VCRUNTIME140.dll_memset
mov r8, rbx
cmp qword [rbx + 0x18], 8
jb 0x14005a018
mov r8, qword [rbx]
mov edx, 0x104
lea rcx, [rbp + 0x260]
call qword [sym.imp.api_ms_win_core_path_l1_1_0.dll_PathCchCanonicalize]
mov edi, eax
test eax, eax
je 0x14005a0cb
lea rcx, [rsp + 0x50]
call fcn.1400124e0
nop
cmp qword [rbx + 0x18], 8
jb 0x14005a049
mov rbx, qword [rbx]
lea rdx, str.PathCchCanonicalize_fail_srcPath:
lea rcx, [rsp + 0x60]
call fcn.140013a90
mov rcx, rax
mov rdx, rbx
call fcn.1400138a0
mov rcx, rax
lea rdx, str._error:
call fcn.140013a90
mov rcx, rax
mov edx, edi
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64___cdecl_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t__::operator___long_int____ptr64]
mov rcx, rax
lea rdx, [0x1400b7d10]
call fcn.1400138a0
mov rcx, rax
lea rdx, str.Hwa::Ux::HwSettingWnd::CreateRecursiveDirectory
call fcn.140013a90
mov rcx, rax
lea rdx, [0x1400b7d0c]
call fcn.1400138a0
call qword [sym.imp.LogHelper.dll_public:_static_class_HwLogger____ptr64___cdecl_HwLogger::GetInstance_void_]
mov rcx, rax
lea r8, [rsp + 0x50]
mov edx, 4
call qword [sym.imp.LogHelper.dll_public:_void___cdecl_HwLogger::Log_enum_LOG_MESSAGE_LEVEL__class_std::basic_stringstream_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t______ptr64____ptr64]
nop
jmp 0x140059fc9
xor edx, edx
lea rcx, [rbp + 0x260]
call qword [sym.imp.KERNEL32.dll_CreateDirectoryW]
cmp eax, 1
sete al
jmp 0x140059fd5
call fcn.1400941d8
int3