Function at 0x407f30
Capabilities:
Check if file exists
Create directory
Get common file path
Read .ini file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4365bd
mov eax, dword fs:[0]
push eax
sub esp, 0x6e0
mov eax, dword [0x45a6d0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 8]
xor ebx, ebx
push ebx
mov esi, ecx
push 0x1a
lea ecx, [ebp - 0x218]
push ecx
push ebx
mov dword [ebp - 0x6e0], eax
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
mov edi, 8
cmp dword [esi + 0x14], edi
jb 0x407f8a
mov eax, dword [esi]
jmp 0x407f8c
mov eax, esi
push eax
lea edx, [ebp - 0x218]
push edx
push str._s_s
call fcn.00404770
add esp, 0xc
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x407fc0
push ebx
lea ecx, [ebp - 0x218]
push ecx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
cmp dword [esi + 0x30], edi
lea eax, [esi + 0x1c]
jb 0x407fca
mov eax, dword [eax]
push eax
lea edx, [ebp - 0x218]
push edx
push str._s_s
call fcn.00404770
push 0x2000
call fcn.0041a77e
push 0x1000
mov edi, eax
push ebx
push edi
mov dword [ebp - 0x6d8], edi
call fcn.00426cd0
add esp, 0x1c
lea eax, [ebp - 0x218]
push eax
push 0x1000
push edi
push ebx
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringW]
push 0xa
push str.exit_false
lea ecx, [ebp - 0x660]
mov dword [ebp - 0x6e4], eax
mov byte [ebp - 0x6d1], bl
mov dword [ebp - 0x6dc], ebx
mov dword [ebp - 0x64c], 0xf
mov dword [ebp - 0x650], ebx
mov byte [ebp - 0x660], bl
call fcn.004028b2
mov dword [ebp - 4], ebx
cmp byte [ebp + 0xc], bl
je 0x408067
push 9
push str.exit_true
lea ecx, [ebp - 0x660]
call fcn.004028b2
mov dword [ebp - 0x6e8], ebx
cmp dword [ebp - 0x6e4], ebx
jbe 0x40823d
lea esp, [esp]
xor ecx, ecx
mov eax, edi
mov dword [ebp - 0x6a0], 7
mov dword [ebp - 0x6a4], ebx
mov word [ebp - 0x6b4], cx
lea edx, [eax + 2]
mov edi, edi
mov cx, word [eax]
add eax, 2
cmp cx, bx
jne 0x4080a0
sub eax, edx
sar eax, 1
push eax
mov eax, edi
lea esi, [ebp - 0x6b4]
call fcn.00409320
push 0xd
push str.WEExintStatus
mov edx, esi
push edx
mov byte [ebp - 4], 1
call fcn.00409170
cmp eax, 0xffffffff
je 0x4081e5
inc dword [ebp - 0x6dc]
push 0x206
lea ecx, [ebp - 0x41e]
xor eax, eax
push ebx
push ecx
mov word [ebp - 0x420], ax
call fcn.00426cd0
add esp, 0xc
lea edx, [ebp - 0x218]
push edx
push 0x104
lea eax, [ebp - 0x420]
push eax
push 0x43c02c
push str.ExitBrowser
push edi
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringW]
lea eax, [ebp - 0x420]
lea edx, [eax + 2]
lea ebx, [ebx]
mov cx, word [eax]
add eax, 2
cmp cx, bx
jne 0x408130
sub eax, edx
sar eax, 1
je 0x4081e5
lea ecx, [ebp - 0x420]
push ecx
lea edx, [ebp - 0x6d0]
push edx
call sym.jsService.exe_class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char_____cdecl_KpBase::ws2s_wchar_t_const__
push eax
lea eax, [ebp - 0x67c]
push eax
mov byte [ebp - 4], 2
call sym.jsService.exe_class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char_____cdecl_AyDecrypt::DecryptIni_class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char____
add esp, 0x10
mov byte [ebp - 4], 4
cmp dword [ebp - 0x6bc], 0x10
jb 0x408188
mov ecx, dword [ebp - 0x6d0]
push ecx
call fcn.0041bfc5
add esp, 4
mov esi, dword [ebp - 0x6e0]
cmp dword [esi + 0x14], 0x10
mov eax, dword [esi + 0x10]
mov dword [ebp - 0x6bc], 0xf
mov dword [ebp - 0x6c0], ebx
mov byte [ebp - 0x6d0], bl
jb 0x4081b1
mov ecx, dword [esi]
jmp 0x4081b3
mov ecx, esi
push eax
mov eax, dword [ebp - 0x66c]
lea edx, [ebp - 0x67c]
call fcn.004090b0
test eax, eax
je 0x408271
cmp dword [ebp - 0x668], 0x10
jb 0x4081e5
mov edx, dword [ebp - 0x67c]
push edx
call fcn.0041bfc5
add esp, 4
mov eax, edi
lea edx, [eax + 2]
lea ebx, [ebx]
mov cx, word [eax]
add eax, 2
cmp cx, bx
jne 0x4081f0
sub eax, edx
sar eax, 1
mov byte [ebp - 4], bl
cmp dword [ebp - 0x6a0], 8
lea edi, [edi + eax*2 + 2]
jb 0x40821e
mov eax, dword [ebp - 0x6b4]
push eax
call fcn.0041bfc5
add esp, 4
mov eax, dword [ebp - 0x6e8]
inc eax
mov dword [ebp - 0x6e8], eax
cmp eax, dword [ebp - 0x6e4]
jb 0x408080
mov edi, dword [ebp - 0x6d8]
mov esi, dword [ebp - 0x6e0]
push edi
call fcn.0041c3d5
add esp, 4
cmp byte [ebp - 0x6d1], bl
je 0x408366
cmp dword [ebp - 0x64c], 0x10
jb 0x4084d3
mov ecx, dword [ebp - 0x660]
push ecx
jmp 0x4084cb
lea ecx, [ebp - 0x660]
push ecx
lea edx, [ebp - 0x698]
push edx
call sym.jsService.exe_class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char_____cdecl_AyDecrypt::EncryptIni_class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char____
add esp, 8
mov byte [ebp - 4], 5
cmp dword [eax + 0x14], 0x10
jb 0x408293
mov eax, dword [eax]
push eax
lea eax, [ebp - 0x644]
push eax
call sym.jsService.exe_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t_____cdecl_KpBase::s2ws_char_const__
add esp, 8
cmp dword [eax + 0x14], 8
jb 0x4082ab
mov eax, dword [eax]
lea ecx, [ebp - 0x218]
push ecx
push eax
push str.ExitConnected
push edi
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
cmp dword [ebp - 0x630], 8
jb 0x4082d7
mov edx, dword [ebp - 0x644]
push edx
call fcn.0041bfc5
add esp, 4
xor eax, eax
mov edi, 0x10
mov dword [ebp - 0x630], 7
mov dword [ebp - 0x634], ebx
mov word [ebp - 0x644], ax
cmp dword [ebp - 0x684], edi
jb 0x40830c
mov ecx, dword [ebp - 0x698]
push ecx
call fcn.0041bfc5
add esp, 4
mov byte [ebp - 0x6d1], 1
cmp dword [ebp - 0x668], edi
jb 0x40832a
mov edx, dword [ebp - 0x67c]
push edx
call fcn.0041bfc5
add esp, 4
mov byte [ebp - 4], bl
cmp dword [ebp - 0x6a0], 8
mov dword [ebp - 0x668], 0xf
mov dword [ebp - 0x66c], ebx
mov byte [ebp - 0x67c], bl
jb 0x40835b
mov eax, dword [ebp - 0x6b4]
push eax
call fcn.0041bfc5
add esp, 4
mov edi, dword [ebp - 0x6d8]
jmp 0x408243
mov edx, dword [ebp - 0x6dc]
push edx
push str.WEExintStatus
push str._s__d
lea edx, [ebp - 0x628]
call fcn.00404770
lea eax, [ebp - 0x698]
push esi
push eax
call sym.jsService.exe_class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char_____cdecl_AyDecrypt::EncryptIni_class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char____
add esp, 0x14
mov byte [ebp - 4], 6
cmp dword [eax + 0x14], 0x10
jb 0x40839e
mov eax, dword [eax]
push eax
lea ecx, [ebp - 0x644]
push ecx
call sym.jsService.exe_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t_____cdecl_KpBase::s2ws_char_const__
mov edi, 8
add esp, 8
cmp dword [eax + 0x14], edi
jb 0x4083ba
mov eax, dword [eax]
mov esi, dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
lea edx, [ebp - 0x218]
push edx
push eax
push str.ExitBrowser
lea eax, [ebp - 0x628]
push eax
call esi
cmp dword [ebp - 0x630], edi
jb 0x4083ed
mov ecx, dword [ebp - 0x644]
push ecx
call fcn.0041bfc5
add esp, 4
xor edx, edx
mov byte [ebp - 4], bl
cmp dword [ebp - 0x684], 0x10
mov dword [ebp - 0x630], 7
mov dword [ebp - 0x634], ebx
mov word [ebp - 0x644], dx
jb 0x408421
mov eax, dword [ebp - 0x698]
push eax
call fcn.0041bfc5
add esp, 4
lea ecx, [ebp - 0x660]
push ecx
lea edx, [ebp - 0x698]
push edx
call sym.jsService.exe_class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char_____cdecl_AyDecrypt::EncryptIni_class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char____
add esp, 8
mov byte [ebp - 4], 7
cmp dword [eax + 0x14], 0x10
jb 0x408443
mov eax, dword [eax]
push eax
lea eax, [ebp - 0x644]
push eax
call sym.jsService.exe_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t_____cdecl_KpBase::s2ws_char_const__
add esp, 8
cmp dword [eax + 0x14], edi
jb 0x40845a
mov eax, dword [eax]
lea ecx, [ebp - 0x218]
push ecx
push eax
push str.ExitConnected
lea edx, [ebp - 0x628]
push edx
call esi
cmp dword [ebp - 0x630], edi
jb 0x408487
mov eax, dword [ebp - 0x644]
push eax
call fcn.0041bfc5
add esp, 4
xor ecx, ecx
mov esi, 0x10
mov dword [ebp - 0x630], 7
mov dword [ebp - 0x634], ebx
mov word [ebp - 0x644], cx
cmp dword [ebp - 0x684], esi
jb 0x4084bc
mov edx, dword [ebp - 0x698]
push edx
call fcn.0041bfc5
add esp, 4
cmp dword [ebp - 0x64c], esi
jb 0x4084d3
mov eax, dword [ebp - 0x660]
push eax
call fcn.0041bfc5
add esp, 4
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0041b4d6
mov esp, ebp
pop ebp
ret 8