Function at 0x140049a94
Capabilities:
Get common file path
Set current directory

Disassembly:
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x2140]
mov eax, 0x2240
call fcn.140059170
sub rsp, rax
mov qword [rbp - 0x80], 0xfffffffffffffffe
mov qword [rsp + 0x2290], rbx
mov rax, qword [0x1400886c0]
xor rax, rsp
mov qword [rbp + 0x2130], rax
mov rax, rdx
mov r12, rcx
test rdx, rdx
jne 0x140049ae5
xor edi, edi
jmp 0x140049b01
mov r8d, 0x400
lea rdx, [rbp + 0x530]
mov rcx, rax
call fcn.14004c418
lea rdi, [rbp + 0x530]
lea rcx, str.MAPI32.DLL
call fcn.14004a000
mov rsi, rax
mov qword [rsp + 0x48], rax
test rax, rax
je 0x140049e9d
lea rdx, str.MAPISendMail
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov r14, rax
mov qword [rsp + 0x50], rax
lea rdx, str.MAPIResolveName
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rbx, rax
mov qword [rsp + 0x38], rax
lea rdx, str.MAPIFreeBuffer
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov r13, rax
test r14, r14
je 0x140049e94
test rbx, rbx
je 0x140049e94
test rax, rax
je 0x140049e94
test rdi, rdi
je 0x140049b9a
cmp byte [rdi], 0x2e
jne 0x140049b9a
mov byte [rsp + 0x30], 1
inc rdi
mov al, byte [rdi]
neg al
sbb rcx, rcx
and rdi, rcx
jmp 0x140049b9f
mov byte [rsp + 0x30], 0
xor ecx, ecx
call fcn.14004a080
lea rdx, [rbp + 0x1130]
mov ebx, 0x800
mov ecx, ebx
call qword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
mov r8d, ebx
lea rdx, [rbp + 0x930]
mov rcx, r12
call fcn.14004c418
mov dl, 1
lea rcx, [rbp + 0x930]
call fcn.140034040
lea r9, [rsp + 0x40]
lea r8, [rbp + 0x10]
mov edx, 0x104
lea rcx, [rbp + 0x930]
call qword [sym.imp.KERNEL32.dll_GetFullPathNameA]
xor edx, edx
lea r8d, [rdx + 0x28]
lea rcx, [rbp - 0x78]
call fcn.14005b2b0
or dword [rbp - 0x70], 0xffffffff
lea rax, [rbp + 0x10]
mov qword [rbp - 0x68], rax
mov rbx, qword [rsp + 0x40]
mov qword [rbp - 0x60], rbx
xor edx, edx
lea r8d, [rdx + 0x60]
lea rcx, [rbp - 0x50]
call fcn.14005b2b0
mov dword [rbp], 1
lea rax, [rbp - 0x78]
mov qword [rbp + 8], rax
mov qword [rbp - 0x40], rbx
mov qword [rbp - 0x48], rbx
xor r15d, r15d
mov qword [rsp + 0x58], r15
xor r14d, r14d
mov qword [rsp + 0x60], r14
and qword [rsp + 0x68], r14
and qword [rsp + 0x70], r14
mov byte [rsp + 0x78], r14b
test rdi, rdi
je 0x140049de2
mov r14, rdi
mov rsi, qword [rsp + 0x38]
mov edx, 1
lea rcx, [rsp + 0x58]
call fcn.14004998c
mov eax, dword [rbp - 0x10]
lea rcx, [rax + rax*4]
mov r15, qword [rsp + 0x58]
lea rbx, [r15 + rcx*8]
xor edx, edx
lea r8d, [rdx + 0x28]
mov rcx, rbx
call fcn.14005b2b0
mov r8d, 0x405
lea rdx, str.SMTP:
lea rcx, [rbp + 0x120]
call fcn.140049544
mov r8d, 0x405
mov rdx, r14
lea rcx, [rbp + 0x120]
call fcn.140049508
lea rdx, [0x140075b30]
mov rcx, r14
call fcn.140062148
mov r14, rax
test rax, rax
je 0x140049cf1
inc r14
movsx ecx, byte [r14]
call fcn.1400491ec
test al, al
jne 0x140049ce1
lea rdx, [0x140075b34]
lea rcx, [rbp + 0x120]
call fcn.140062148
test rax, rax
je 0x140049d0c
mov byte [rax], 0
mov dword [rbx + 4], 1
lea rax, [rsp + 0x38]
mov qword [rsp + 0x28], rax
and dword [rsp + 0x20], 0
mov r9d, 1
lea r8, [rbp + 0x125]
xor edx, edx
xor ecx, ecx
call rsi
test eax, eax
jne 0x140049db8
mov rax, qword [rsp + 0x38]
mov ecx, dword [rax]
mov dword [rbx], ecx
mov rax, qword [rsp + 0x38]
mov rcx, qword [rax + 8]
test rcx, rcx
je 0x140049d5e
call fcn.140063430
mov qword [rbx + 8], rax
mov rax, qword [rsp + 0x38]
mov rcx, qword [rax + 0x10]
test rcx, rcx
je 0x140049d75
call fcn.140063430
mov qword [rbx + 0x10], rax
mov rax, qword [rsp + 0x38]
mov eax, dword [rax + 0x18]
mov dword [rbx + 0x18], eax
mov rcx, qword [rsp + 0x38]
cmp qword [rcx + 0x20], 0
je 0x140049db3
mov eax, dword [rcx + 0x18]
test eax, eax
je 0x140049db3
mov ecx, eax
call fcn.14005d6d0
mov qword [rbx + 0x20], rax
mov rdx, qword [rsp + 0x38]
mov r8d, dword [rdx + 0x18]
mov rdx, qword [rdx + 0x20]
mov rcx, rax
call fcn.14005ae60
mov rcx, qword [rsp + 0x38]
call r13
jmp 0x140049dc8
lea rcx, [rbp + 0x120]
call fcn.140063430
mov qword [rbx + 0x10], rax
inc dword [rbp - 0x10]
test r14, r14
jne 0x140049c6f
mov qword [rbp - 8], r15
mov r14, qword [rsp + 0x60]
mov rsi, qword [rsp + 0x48]
neg rdi
sbb r9d, r9d
and r9d, 0xfffffff8
add r9d, 9
and dword [rsp + 0x20], 0
lea r8, [rbp - 0x50]
xor edx, edx
xor ecx, ecx
call qword [rsp + 0x50]
cmp eax, 2
setb dil
test r14, r14
je 0x140049e44
lea rbx, [r15 + 0x10]
mov rcx, qword [rbx - 8]
test rcx, rcx
je 0x140049e1f
call fcn.14005d6c8
mov rcx, qword [rbx]
test rcx, rcx
je 0x140049e2c
call fcn.14005d6c8
mov rcx, qword [rbx + 0x10]
test rcx, rcx
je 0x140049e3a
call fcn.14005d6c8
add rbx, 0x28
sub r14, 1
jne 0x140049e11
lea rcx, [rbp + 0x1130]
call qword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
mov cl, 1
call fcn.14004a080
test dil, dil
je 0x140049e77
cmp byte [rsp + 0x30], 0
je 0x140049e85
mov rcx, r12
call fcn.1400225b0
jmp 0x140049e85
mov rdx, r12
mov ecx, 0x4e
call fcn.140001148
nop
lea rcx, [rsp + 0x58]
call fcn.140049948
mov al, dil
jmp 0x140049e9f
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
xor al, al
mov rcx, qword [rbp + 0x2130]
xor rcx, rsp
call fcn.1400591e0
mov rbx, qword [rsp + 0x2290]
add rsp, 0x2240
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret