Function at 0x494c60
Capabilities:
Get common file path
Link many functions at runtime
Set current directory

Disassembly:
push ebp
lea ebp, [esp - 0x3110]
mov eax, 0x3110
call fcn.004f8350
push 0xffffffffffffffff
push 0x514e18
mov eax, dword fs:[0]
push eax
sub esp, 0x7c
mov eax, dword [0x544354]
xor eax, ebp
mov dword [ebp + 0x310c], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 0x3118]
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp + 0x311c]
test eax, eax
jne 0x494cb4
xor ebx, ebx
jmp 0x494ccc
push 0x400
lea ecx, [ebp + 0x2800]
push ecx
push eax
call fcn.004979e0
lea ebx, [ebp + 0x2800]
push 0x800
lea eax, [ebp + 0x1000]
mov dword [ebp - 0x18], ebx
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
test eax, eax
je 0x4950bc
push 0x800
lea eax, [ebp + 0x1000]
push eax
push str.MAPI32.DLL
push eax
call fcn.0047d340
lea eax, [ebp + 0x1000]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov esi, eax
mov dword [ebp - 0x20], esi
test esi, esi
je 0x4950bc
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.MAPISendMail
push esi
call edi
push str.MAPIResolveName
push esi
mov dword [ebp - 0x24], eax
call edi
push str.MAPIFreeBuffer
push dword [ebp - 0x20]
mov esi, eax
mov dword [ebp - 0x40], esi
call edi
cmp dword [ebp - 0x24], 0
mov dword [ebp - 0x14], eax
je 0x4950b3
test esi, esi
je 0x4950b3
test eax, eax
je 0x4950b3
test ebx, ebx
je 0x494d7c
cmp byte [ebx], 0x2e
jne 0x494d7c
movsx eax, byte [ebx + 1]
inc ebx
neg eax
mov byte [ebp - 0xd], 1
sbb eax, eax
and ebx, eax
mov dword [ebp - 0x18], ebx
jmp 0x494d80
mov byte [ebp - 0xd], 0
push str.kernel32
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov esi, eax
test esi, esi
je 0x494da9
push str.SetDllDirectoryW
push esi
call edi
test eax, eax
je 0x494da1
push 0
call eax
push str.SetDefaultDllDirectories
push esi
call edi
lea eax, [ebp]
push eax
push 0x800
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
push 0x800
lea eax, [ebp + 0x2000]
push eax
push dword [ebp - 0x1c]
call fcn.004979e0
push 1
lea eax, [ebp + 0x2000]
push eax
call fcn.0047d470
lea eax, [ebp - 0x3c]
push eax
lea eax, [ebp + 0x3008]
push eax
push 0x104
lea eax, [ebp + 0x2000]
push eax
call dword [sym.imp.KERNEL32.dll_GetFullPathNameA]
mov esi, dword [ebp - 0x3c]
xor eax, eax
mov dword [ebp - 0x58], eax
mov dword [ebp - 0x54], eax
mov dword [ebp - 0x44], eax
lea eax, [ebp + 0x3008]
push 0x30
mov dword [ebp - 0x4c], eax
lea eax, [ebp - 0x88]
push 0
push eax
mov dword [ebp - 0x50], 0xffffffff
mov dword [ebp - 0x48], esi
call fcn.004fa860
mov dword [ebp - 0x80], esi
lea eax, [ebp - 0x58]
mov dword [ebp - 0x84], esi
xor edi, edi
xor esi, esi
mov dword [ebp - 0x60], 1
mov dword [ebp - 0x38], esi
add esp, 0xc
mov dword [ebp - 0x34], edi
mov dword [ebp - 0x30], esi
mov dword [ebp - 0x5c], eax
mov dword [ebp - 0x2c], esi
mov byte [ebp - 0x28], 0
mov dword [ebp - 4], edi
test ebx, ebx
je 0x494fb3
mov esi, ebx
mov ebx, dword [ebp - 0x14]
push 1
lea ecx, [ebp - 0x38]
call fcn.0044b3b0
mov eax, dword [ebp - 0x68]
mov edi, dword [ebp - 0x38]
push 0x405
push str.SMTP:
lea eax, [eax + eax*2]
lea edi, [edi + eax*8]
xor eax, eax
mov dword [edi], eax
mov dword [edi + 4], eax
mov dword [edi + 8], eax
mov dword [edi + 0xc], eax
mov dword [edi + 0x10], eax
mov dword [edi + 0x14], eax
lea eax, [ebp + 0x2c00]
push eax
call fcn.004946e0
push 0x405
push esi
lea eax, [ebp + 0x2c00]
push eax
call fcn.00494690
push 0x526328
push esi
call fcn.00503710
mov esi, eax
add esp, 8
test esi, esi
je 0x494edf
lea ebx, [ebx]
movsx ecx, byte [esi + 1]
inc esi
push ecx
call fcn.004943b0
test al, al
jne 0x494ed0
lea eax, [ebp + 0x2c00]
push 0x526328
push eax
call fcn.00503710
add esp, 8
test eax, eax
je 0x494efa
mov byte [eax], 0
lea eax, [ebp - 0x14]
mov dword [edi + 4], 1
push eax
push 0
push 1
lea eax, [ebp + 0x2c05]
push eax
push 0
push 0
call dword [ebp - 0x40]
test eax, eax
jne 0x494f8a
mov eax, dword [ebp - 0x14]
mov eax, dword [eax]
mov dword [edi], eax
mov eax, dword [ebp - 0x14]
mov ecx, dword [eax + 8]
test ecx, ecx
je 0x494f3b
push ecx
call fcn.0050515b
mov dword [edi + 8], eax
add esp, 4
mov eax, dword [ebp - 0x14]
mov ecx, dword [eax + 0xc]
test ecx, ecx
je 0x494f51
push ecx
call fcn.0050515b
mov dword [edi + 0xc], eax
add esp, 4
mov eax, dword [ebp - 0x14]
mov eax, dword [eax + 0x10]
mov dword [edi + 0x10], eax
mov eax, dword [ebp - 0x14]
cmp dword [eax + 0x14], 0
je 0x494f85
mov ecx, dword [eax + 0x10]
test ecx, ecx
je 0x494f85
push ecx
call fcn.004fe8be
mov dword [edi + 0x14], eax
mov ecx, dword [ebp - 0x14]
push dword [ecx + 0x10]
push dword [ecx + 0x14]
push eax
call fcn.004fa2e0
mov eax, dword [ebp - 0x14]
add esp, 0x10
push eax
call ebx
jmp 0x494f9c
lea eax, [ebp + 0x2c00]
push eax
call fcn.0050515b
add esp, 4
mov dword [edi + 0xc], eax
inc dword [ebp - 0x68]
test esi, esi
jne 0x494e65
mov esi, dword [ebp - 0x38]
mov edi, dword [ebp - 0x34]
mov ebx, dword [ebp - 0x18]
mov dword [ebp - 0x64], esi
xor eax, eax
test ebx, ebx
push 0
sete al
lea eax, [eax*8 + 1]
push eax
lea eax, [ebp - 0x88]
push eax
push 0
push 0
call dword [ebp - 0x24]
test eax, eax
je 0x494fdf
cmp eax, 1
je 0x494fdf
xor bl, bl
jmp 0x494fe1
mov bl, 1
test edi, edi
je 0x49501f
add esi, 0xc
mov eax, dword [esi - 4]
test eax, eax
je 0x494ff8
push eax
call fcn.004fe8b9
add esp, 4
mov eax, dword [esi]
test eax, eax
je 0x495007
push eax
call fcn.004fe8b9
add esp, 4
mov eax, dword [esi + 8]
test eax, eax
je 0x495017
push eax
call fcn.004fe8b9
add esp, 4
add esi, 0x18
sub edi, 1
jne 0x494fe8
lea eax, [ebp]
push eax
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
push dword [ebp - 0x20]
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
push str.kernel32
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov esi, eax
test esi, esi
je 0x495064
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.SetDllDirectoryW
push esi
call edi
test eax, eax
je 0x49505c
push 0x51787c
call eax
push str.SetDefaultDllDirectories
push esi
call edi
test bl, bl
je 0x495078
cmp byte [ebp - 0xd], 0
je 0x495082
push dword [ebp - 0x1c]
call fcn.0046c6d0
jmp 0x495082
push dword [ebp - 0x1c]
push 0x4e
call fcn.00412af0
mov dword [ebp - 4], 0xffffffff
mov edi, dword [ebp - 0x38]
test edi, edi
je 0x4950af
cmp byte [ebp - 0x28], 0
je 0x4950a6
mov eax, dword [ebp - 0x30]
lea eax, [eax + eax*2]
shl eax, 3
push eax
push edi
call fcn.00491e00
push edi
call fcn.004fe8b9
add esp, 4
mov al, bl
jmp 0x4950be
push dword [ebp - 0x20]
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
xor al, al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x310c]
xor ecx, ebp
call fcn.004f833c
lea esp, [ebp + 0x3110]
pop ebp
ret 8