Function at 0x4082b7
Capabilities:
Copy file
Move file
Read .ini file
Write file on windows

Disassembly:
mov eax, 0x413e80
call fcn.00413240
mov eax, 0x10c4
call fcn.00413270
mov eax, dword [0x4241a4]
xor eax, esp
push ebx
push ebp
push esi
mov dword [esp + 0x10cc], eax
push edi
mov edi, dword [sym.imp.MSVCR71.dll__wstat]
lea eax, [esp + 0x3c]
push eax
mov esi, str.C:TSLOG_CONFIGTSLOG.ini
push esi
mov ebp, ecx
call edi
test eax, eax
pop ecx
pop ecx
je 0x408354
lea eax, [esp + 0x3c]
push eax
mov ebx, str.C:TSLOG_CONFIGTSLOG.txt
push ebx
call edi
test eax, eax
pop ecx
pop ecx
je 0x40834c
lea eax, [esp + 0x3c]
push eax
push esi
call edi
test eax, eax
pop ecx
pop ecx
je 0x40833f
lea eax, [esp + 0x3c]
push eax
push ebx
call edi
test eax, eax
pop ecx
pop ecx
je 0x408337
push 0
mov ecx, ebp
call fcn.0040402f
xor eax, eax
jmp 0x408b8d
push esi
push ebx
call dword [sym.imp.KERNEL32.dll_MoveFileW]
xor ebx, ebx
push ebx
push esi
push esi
call dword [sym.imp.KERNEL32.dll_CopyFileW]
jmp 0x408356
push esi
push ebx
call dword [sym.imp.KERNEL32.dll_MoveFileW]
xor ebx, ebx
cmp dword [esp + 0x50], ebx
mov eax, dword [ebp + 0x2c]
mov dword [esp + 0x14], ebx
mov dword [esp + 0x18], eax
jne 0x4083af
push ebx
push ebx
push 4
push ebx
push 1
push 0x40000000
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
je 0x4083af
push ebx
lea eax, [esp + 0x14]
mov dword [esp + 0x14], ebx
push eax
mov ebx, str.__Output__r_n_DebugView__________________ON______ON
push ebx
call sub.MSVCR71.dll_strlen
pop ecx
push eax
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [esp + 0x14], 1
and word [esp + 0xd0], 0
xor eax, eax
mov ecx, 0x3ff
lea edi, [esp + 0xd2]
rep stosd dword es:[edi], eax
push esi
push 0x800
stosw word es:[edi], ax
lea eax, [esp + 0xd8]
push eax
mov edi, 0x418110
push edi
push 0x4180fc
push str.Output
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringW]
mov ebx, dword [sym.imp.MSVCR71.dll__wcsicmp]
lea eax, [esp + 0xd0]
push edi
push eax
call ebx
test eax, eax
pop ecx
pop ecx
je 0x40844a
lea eax, [esp + 0xd0]
push 0x4180f8
push eax
call ebx
test eax, eax
pop ecx
pop ecx
je 0x40844a
lea eax, [esp + 0xd0]
push 0x41783c
push eax
call ebx
test eax, eax
pop ecx
pop ecx
je 0x408444
lea eax, [esp + 0xd0]
push 0x4180f4
push eax
call ebx
test eax, eax
pop ecx
pop ecx
jne 0x408451
and dword [ebp + 0x28], 0
jmp 0x408451
mov dword [ebp + 0x28], 1
cmp dword [esp + 0x14], 0
je 0x408477
cmp dword [ebp + 0x28], 0
mov eax, edi
jne 0x408465
mov eax, 0x41783c
push esi
push eax
push 0x4180fc
push str.Output
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
push esi
push 0x800
lea eax, [esp + 0xd8]
push eax
push edi
push str.FileLog
push str.Output
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringW]
lea eax, [esp + 0xd0]
push edi
push eax
call ebx
test eax, eax
pop ecx
pop ecx
je 0x4084ec
lea eax, [esp + 0xd0]
push 0x4180f8
push eax
call ebx
test eax, eax
pop ecx
pop ecx
je 0x4084ec
lea eax, [esp + 0xd0]
push 0x41783c
push eax
call ebx
test eax, eax
pop ecx
pop ecx
je 0x4084e6
lea eax, [esp + 0xd0]
push 0x4180f4
push eax
call ebx
test eax, eax
pop ecx
pop ecx
jne 0x4084f3
and dword [ebp + 0x2c], 0
jmp 0x4084f3
mov dword [ebp + 0x2c], 1
cmp dword [esp + 0x14], 0
je 0x408517
cmp dword [ebp + 0x2c], 0
jne 0x408505
mov edi, 0x41783c
push esi
push edi
push str.FileLog
push str.Output
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
push esi
push 0x800
lea eax, [esp + 0xd8]
push eax
push str.TRACE
push str.Level
mov edi, str.Common
push edi
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringW]
lea eax, [esp + 0xd0]
push str.TRACE
push eax
call ebx
test eax, eax
pop ecx
pop ecx
jne 0x408558
and dword [ebp + 0x30], eax
jmp 0x4085ec
lea eax, [esp + 0xd0]
push str.DEBUG
push eax
call ebx
test eax, eax
pop ecx
pop ecx
jne 0x408576
mov dword [ebp + 0x30], 1
jmp 0x4085ec
lea eax, [esp + 0xd0]
push str.INFO
push eax
call ebx
test eax, eax
pop ecx
pop ecx
jne 0x408594
mov dword [ebp + 0x30], 2
jmp 0x4085ec
lea eax, [esp + 0xd0]
push str.WARN
push eax
call ebx
test eax, eax
pop ecx
pop ecx
jne 0x4085b2
mov dword [ebp + 0x30], 3
jmp 0x4085ec
lea eax, [esp + 0xd0]
push str.ERROR
push eax
call ebx
test eax, eax
pop ecx
pop ecx
jne 0x4085d0
mov dword [ebp + 0x30], 4
jmp 0x4085ec
lea eax, [esp + 0xd0]
push str.FATAL
push eax
call ebx
test eax, eax
pop ecx
pop ecx
jne 0x4085ec
mov dword [ebp + 0x30], 5
cmp dword [esp + 0x14], 0
je 0x408647
mov eax, dword [ebp + 0x30]
test eax, eax
je 0x408634
cmp eax, 1
jne 0x408606
mov eax, str.DEBUG
jmp 0x408639
cmp eax, 2
jne 0x408612
mov eax, str.INFO
jmp 0x408639
cmp eax, 3
jne 0x40861e
mov eax, str.WARN
jmp 0x408639
cmp eax, 4
jne 0x40862a
mov eax, str.ERROR
jmp 0x408639
cmp eax, 5
mov eax, str.FATAL
je 0x408639
mov eax, str.TRACE
push esi
push eax
push str.Level
push edi
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
lea ecx, [esp + 0xb4]
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::constructor_void_]
and dword [esp + 0x10dc], 0
lea ecx, [esp + 0x98]
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::constructor_void_]
mov byte [esp + 0x10dc], 1
lea ecx, [ebp + 0x34]
call fcn.0040180e
push esi
push 0x800
lea eax, [esp + 0xd8]
push eax
push 0x416e08
push str.Include
push edi
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringW]
lea eax, [esp + 0xd0]
push eax
lea ecx, [esp + 0xb8]
call dword [sym.imp.MSVCP71.dll_public:_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t______thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::operator_wchar_t_const__]
mov ebx, dword [sym.imp.MSVCR71.dll_wcstok]
push 0x418078
lea eax, [esp + 0xd4]
push eax
jmp 0x4086ea
push 0x416e08
push dword [esp + 0x14]
call dword [sym.imp.MSVCR71.dll__wcsicmp]
test eax, eax
pop ecx
pop ecx
lea ecx, [ebp + 0x34]
je 0x4086f8
push dword [esp + 0x10]
call fcn.00403c87
push 0x418078
push 0
call ebx
test eax, eax
pop ecx
pop ecx
mov dword [esp + 0x10], eax
jne 0x4086c2
jmp 0x408722
call fcn.0040180e
push dword [esp + 0x10]
lea ecx, [ebp + 0x34]
call fcn.00403c87
cmp dword [esp + 0x14], 0
je 0x408722
push esi
push 0x416e08
push str.Include
push edi
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
lea ecx, [ebp + 0x88]
call fcn.0040180e
push esi
push 0x800
lea eax, [esp + 0xd8]
push eax
push 0x418074
push 0x418064
push edi
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringW]
lea eax, [esp + 0xd0]
push eax
lea ecx, [esp + 0x9c]
call dword [sym.imp.MSVCP71.dll_public:_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t______thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::operator_wchar_t_const__]
lea eax, [esp + 0xd0]
push 0x418060
push eax
call ebx
test eax, eax
pop ecx
pop ecx
mov dword [esp + 0x10], eax
jne 0x408794
cmp dword [esp + 0x14], eax
je 0x4087de
push esi
push 0x418074
push 0x418064
push edi
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
jmp 0x4087de
mov edi, dword [esp + 0x10]
push 0x416e08
push edi
call dword [sym.imp.MSVCR71.dll__wcsicmp]
test eax, eax
pop ecx
pop ecx
je 0x4087c9
push edi
lea ecx, [ebp + 0x88]
call fcn.00403c87
push 0x418078
push 0
call ebx
mov edi, eax
test edi, edi
pop ecx
pop ecx
jne 0x408798
jmp 0x4087de
lea ebx, [ebp + 0x88]
mov ecx, ebx
call fcn.0040180e
push edi
mov ecx, ebx
call fcn.00403c87
lea ecx, [esp + 0x60]
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::constructor_void_]
mov byte [esp + 0x10dc], 2
push esi
lea ecx, [esp + 0x24]
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::constructor_wchar_t_const__]
mov byte [esp + 0x10dc], 3
lea eax, [esp + 0x60]
push eax
lea eax, [esp + 0x24]
push eax
call fcn.00401837
pop ecx
pop ecx
mov byte [esp + 0x10dc], 2
lea ecx, [esp + 0x20]
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
lea ecx, [esp + 0x60]
call dword [sym.imp.MSVCP71.dll_public:_char_const____thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::c_str_void_const]
lea ecx, [esp + 0x7c]
mov dword [esp + 0x10], eax
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::constructor_void_]
mov byte [esp + 0x10dc], 4
lea edi, [ebp + 0xf8]
push edi
lea ecx, [esp + 0x24]
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::constructor_char_const__]
mov byte [esp + 0x10dc], 5
lea eax, [esp + 0x7c]
push eax
lea eax, [esp + 0x24]
push eax
call fcn.004054d7
pop ecx
pop ecx
mov byte [esp + 0x10dc], 4
lea ecx, [esp + 0x20]
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::destructor_void_]
lea ecx, [esp + 0x7c]
call dword [sym.imp.MSVCP71.dll_public:_wchar_t_const____thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::c_str_void_const]
xor ebx, ebx
cmp dword [ebp + 0x2c], ebx
mov dword [esp + 0x1c], eax
je 0x408a58
cmp dword [esp + 0x18], ebx
je 0x4088a9
cmp dword [ebp + 0x23c], ebx
jne 0x408928
push dword [esp + 0x10]
mov ebx, 0x104
push ebx
push edi
push str.C:TSLOG_
push str.LogFilePath
push str.FileLogOption
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
push edi
call sub.MSVCR71.dll_strlen
test eax, eax
pop ecx
je 0x4088df
push edi
call sub.MSVCR71.dll_strlen
cmp eax, ebx
pop ecx
jb 0x4088ef
push ebx
push str.C:TSLOG_
push edi
call dword [sym.imp.MSVCR71.dll_strncpy]
add esp, 0xc
push edi
call sub.MSVCR71.dll_strlen
cmp byte [eax + ebp + 0xf7], 0x5c
pop ecx
je 0x408910
push ebx
push 0x418040
push edi
call dword [sym.imp.MSVCR71.dll_strncat]
add esp, 0xc
or dword [0x4241cc], 0xffffffff
cmp dword [esp + 0x10e8], 0
jne 0x408928
mov ecx, ebp
call fcn.004055c8
mov ebx, dword [sym.imp.KERNEL32.dll_GetPrivateProfileIntW]
push esi
push 0x5000
push str.MaxLogFileSize
mov edi, 0x418004
push edi
call ebx
cmp eax, 1
mov dword [ebp + 0xdc], eax
jb 0x408953
cmp eax, 0x1f4000
jbe 0x40896f
push esi
push str.20480
push str.MaxLogFileSize
push edi
mov dword [ebp + 0xdc], 0x5000
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
push esi
push 0x14
push str.MaxLogFileCnt
push edi
call ebx
cmp eax, 1
mov dword [ebp + 0xe0], eax
jl 0x40898c
cmp eax, 0x3e8
jle 0x4089a8
push esi
push 0x417fd4
push str.MaxLogFileCnt
push edi
mov dword [ebp + 0xe0], 0x14
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
push esi
push 0xa
push str.MaxCountOfHistroyProcess
push edi
call ebx
cmp eax, 0xffffffff
mov dword [ebp + 0xe4], eax
mov ebx, 0x417f98
jl 0x4089c8
cmp eax, 0x64
jle 0x4089e0
push esi
push ebx
push str.MaxCountOfHistroyProcess
push edi
mov dword [ebp + 0xe4], 0xa
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
cmp dword [esp + 0x14], 0
je 0x408a75
push dword [esp + 0x10]
lea eax, [ebp + 0xf8]
push eax
push str.LogFilePath
push str.FileLogOption
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringA]
cmp dword [ebp + 0xdc], 0x5000
jne 0x408a24
push esi
push str.20480
push str.MaxLogFileSize
push edi
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
cmp dword [ebp + 0xe0], 0x14
jne 0x408a3f
push esi
push 0x417fd4
push str.MaxLogFileCnt
push edi
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
cmp dword [ebp + 0xe4], 0xa
jne 0x408a75
push esi
push ebx
push str.MaxCountOfHistroyProcess
push edi
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
jmp 0x408a75
lea edi, [ebp + 0xe8]
mov eax, dword [edi]
cmp eax, 0xffffffff
je 0x408a75
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
or dword [edi], 0xffffffff
mov dword [ebp + 0xf4], ebx
xor ecx, ecx
cmp dword [esp + 0x10e8], ecx
jne 0x408b3c
mov eax, dword [ebp + 0x30]
cmp eax, ecx
je 0x408ac5
cmp eax, 1
jne 0x408a97
mov edi, str.DEBUG
jmp 0x408aca
cmp eax, 2
jne 0x408aa3
mov edi, str.INFO
jmp 0x408aca
cmp eax, 3
jne 0x408aaf
mov edi, str.WARN
jmp 0x408aca
cmp eax, 4
jne 0x408abb
mov edi, str.ERROR
jmp 0x408aca
cmp eax, 5
mov edi, str.FATAL
je 0x408aca
mov edi, str.TRACE
cmp dword [ebp + 0x2c], ecx
mov dword [esp + 0x10], 0x418110
jne 0x408adf
mov dword [esp + 0x10], 0x41783c
cmp dword [ebp + 0x28], ecx
mov ebx, 0x418110
jne 0x408aee
mov ebx, 0x41783c
push dword [ebp + 0xe4]
lea ecx, [esp + 0x9c]
push dword [ebp + 0xe0]
push dword [ebp + 0xdc]
push dword [esp + 0x28]
call dword [sym.imp.MSVCP71.dll_public:_wchar_t_const____thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::c_str_void_const]
push eax
lea ecx, [esp + 0xc8]
call dword [sym.imp.MSVCP71.dll_public:_wchar_t_const____thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::c_str_void_const]
push eax
push edi
push dword [esp + 0x2c]
push ebx
push esi
push str.TSLog_Config_File_:__s_:__r_n00000000_t00:00:00.000_t_0000___Output__r_n00000000_t00:00:00.000_t_0000__DebugView_s_r_n00000000_t00:00:00.000_t_0000__FileLog_s_r_n00000000_t00:00:00.000_t_0000___Common__r_n00000000_t00:00:00.000_t_0000__Level_s_r_n00000000_t00:00:00.000_t_0000__Include_s_r_n00000000_t00:00:00.000_t_0000__Exclude_s_r_n00000000_t00:00:00.000_t_0000___FileLogOption__r_n00000000_t00:00:00.000_t_0000__LogFilePath_s_r_n00000000_t00:00:00.000_t_0000__MaxLogFileSize_d_r_n00000000_t00:00:00.000_t_0000__MaxLogFileCnt_d_r_n00000000_t00:00:00.000_t_0000__MaxCountOfHistroyProcess_d_r_n
push ebp
call fcn.00401e69
add esp, 0x30
mov ecx, ebp
call fcn.00407ee2
mov byte [esp + 0x10dc], 2
lea ecx, [esp + 0x7c]
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
mov byte [esp + 0x10dc], 1
lea ecx, [esp + 0x60]
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::destructor_void_]
mov byte [esp + 0x10dc], 0
lea ecx, [esp + 0x98]
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
or dword [esp + 0x10dc], 0xffffffff
lea ecx, [esp + 0xb4]
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
xor eax, eax
inc eax
mov ecx, dword [esp + 0x10d4]
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
mov ecx, dword [esp + 0x10c4]
pop ebx
xor ecx, esp
call fcn.00413159
leave
ret 4