Function at 0x474810
Capabilities:
Get common file path
Hide graphical window
Resolve function by parsing pe exports
Set current directory

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x60db39
mov eax, dword fs:[0]
push eax
sub esp, 0x130
mov eax, dword [0x6687b8]
xor eax, esp
mov dword [esp + 0x128], eax
push ebx
push esi
push edi
mov eax, dword [0x6687b8]
xor eax, esp
push eax
lea eax, [esp + 0x140]
mov dword fs:[0], eax
mov eax, dword [ebp + 0x10]
mov esi, dword [ebp + 8]
push 1
mov ecx, str.Kernel32.dll
mov dword [esp + 0x18], eax
call fcn.00577150
add esp, 4
test eax, eax
je 0x47488a
push str.SetDllDirectoryW
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x47488a
push 0x6244e0
call eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, dword [sym.imp.KERNEL32.dll_SetErrorMode]
push 0
call edi
or eax, 0x8001
push eax
call edi
call fcn.00487570
push esi
mov dword [0x678fd0], esi
call fcn.0048f950
push 0
call dword [sym.imp.ole32.dll_OleInitialize]
push 1
mov ecx, str.riched20.dll
mov dword [esp + 0x14c], 0
call fcn.00577150
add esp, 4
mov dword [esp + 0x24], eax
mov byte [esp + 0x148], 1
call dword [sym.imp.COMCTL32.dll_InitCommonControls]
mov ecx, dword [0x67762c]
call fcn.00477620
lea ebx, [esp + 0x18]
call fcn.0047a980
mov byte [esp + 0x148], 2
mov ecx, dword [esp + 0x18]
mov eax, dword [ecx - 0xc]
test eax, eax
jle 0x474932
lea edx, [eax - 1]
test edx, edx
jl 0x4749c0
cmp edx, eax
jg 0x4749c0
movzx eax, word [ecx + edx*2]
cmp ax, 0x5c
je 0x474932
push 0x5c
mov edi, ebx
call fcn.0040af90
mov ecx, dword [esp + 0x18]
push ecx
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
lea ecx, [esp + 0x18]
push ecx
lea edx, [esp + 0x20]
push edx
mov ebx, str.zlib1.dll
call fcn.0040aab0
add esp, 8
mov byte [esp + 0x148], 3
mov ecx, dword [eax]
call fcn.004746a0
mov byte [esp + 0x148], 2
mov eax, dword [esp + 0x1c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x474987
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
call fcn.004ebcf0
push esi
call fcn.0057a850
mov edx, dword [0x677600]
mov eax, dword [edx + 0xc]
add esp, 4
mov ecx, 0x677600
call eax
add eax, 0x10
mov dword [esp + 0x20], eax
mov byte [esp + 0x148], 4
mov edx, dword [esp + 0x14]
test edx, edx
jne 0x4749ca
xor eax, eax
jmp 0x4749df
push 0x80070057
call fcn.00403650
mov eax, edx
lea esi, [eax + 2]
nop
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x4749d0
sub eax, esi
sar eax, 1
mov ebx, eax
push edx
lea eax, [esp + 0x24]
call fcn.004037a0
mov edi, dword [esp + 0x20]
push edi
call fcn.004e6530
add esp, 4
test eax, eax
je 0x474af9
call fcn.00474740
mov esi, dword [0x6790a8]
xor ebx, ebx
cmp esi, ebx
mov dword [0x6790a8], ebx
je 0x474a2f
lea ecx, [esi + 0xc]
push ecx
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
jg 0x474a2f
mov edx, dword [esi]
mov eax, dword [edx]
push 1
mov ecx, esi
call eax
mov eax, dword [0x678fc4]
cmp eax, ebx
mov esi, dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov dword [0x678fc8], ebx
mov dword [0x678fcc], ebx
je 0x474a53
push eax
call esi
mov dword [0x678fc4], ebx
mov eax, dword [0x671f10]
cmp eax, ebx
je 0x474a69
push eax
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov dword [0x671f10], ebx
mov eax, dword [0x671f0c]
cmp eax, ebx
je 0x474a7f
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [0x671f0c], ebx
cmp byte [0x678eef], bl
je 0x474a92
call fcn.004877d0
mov byte [0x678eef], bl
lea eax, [edi - 0x10]
mov byte [esp + 0x148], 2
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x474ab6
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x148], 1
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x474ade
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x24]
cmp eax, ebx
je 0x474ae9
push eax
call esi
call dword [sym.imp.ole32.dll_OleUninitialize]
mov eax, 1
jmp 0x475158
mov dword [esp + 0x28], vtable.CSingleModule.0
mov dword [esp + 0x2c], 0
mov edi, str.Tencent_QQCONFIG_Client_Mutex_532C65C7_31EE_4f2e_95AB_9E4230A07C92
lea eax, [esp + 0x28]
mov byte [esp + 0x148], 5
call fcn.0047e880
test eax, eax
je 0x474f40
call dword [sym.imp.USER32.dll_GetDesktopWindow]
test eax, eax
jne 0x474b35
xor esi, esi
jmp 0x474b41
push str.Tencent_QQPinyin_WND_532C65C7_31EE_4f2e_95AB_9E4230A07C92
call fcn.0047e900
mov esi, eax
push esi
call dword [sym.imp.USER32.dll_IsWindowVisible]
test eax, eax
je 0x474b69
push esi
call dword [sym.imp.USER32.dll_IsIconic]
test eax, eax
je 0x474b60
push 9
push esi
call dword [sym.imp.USER32.dll_ShowWindow]
push esi
call dword [sym.imp.USER32.dll_SetForegroundWindow]
jmp 0x474b86
mov edi, dword [ebp + 0x14]
push edi
push esi
call dword [sym.imp.USER32.dll_ShowWindow]
test edi, edi
je 0x474b86
push esi
call dword [sym.imp.USER32.dll_SetForegroundWindow]
add dword [0x68300c], 1
xor edi, edi
push 1
mov ebx, 7
push 0x6198d8
lea esi, [esp + 0x58]
mov dword [esp + 0x24], edi
mov dword [esp + 0x70], ebx
mov dword [esp + 0x6c], edi
mov word [esp + 0x5c], di
call fcn.00405040
mov byte [esp + 0x148], 6
push 1
push 0x625c94
lea esi, [esp + 0x3c]
mov dword [esp + 0x54], ebx
mov dword [esp + 0x50], edi
mov word [esp + 0x40], di
call fcn.00405040
mov byte [esp + 0x148], bl
push 2
push 0x6292b0
lea esi, [esp + 0x74]
mov dword [esp + 0x8c], ebx
mov dword [esp + 0x88], edi
mov word [esp + 0x78], di
call fcn.00405040
mov ecx, esi
push ecx
sub esp, 0x1c
mov byte [esp + 0x168], 8
mov edx, dword [esp + 0x34]
mov eax, esp
mov dword [esp + 0x50], esp
call fcn.00404630
lea edx, [esp + 0x70]
lea ecx, [esp + 0x54]
lea edi, [esp + 0xec]
call fcn.00403a30
cmp dword [esp + 0x84], 8
jb 0x474c45
mov edx, dword [esp + 0x70]
push edx
call fcn.005d2367
add esp, 4
xor esi, esi
mov dword [esp + 0x84], ebx
mov dword [esp + 0x80], esi
mov word [esp + 0x70], si
mov edi, 8
cmp dword [esp + 0x4c], edi
jb 0x474c72
mov eax, dword [esp + 0x38]
push eax
call fcn.005d2367
add esp, 4
mov dword [esp + 0x4c], ebx
mov dword [esp + 0x48], esi
mov word [esp + 0x38], si
mov byte [esp + 0x148], 0xc
cmp dword [esp + 0x68], edi
jb 0x474c9a
mov ecx, dword [esp + 0x54]
push ecx
call fcn.005d2367
add esp, 4
push 3
mov dword [esp + 0x68], esi
mov word [esp + 0x58], si
mov dword [esp + 0xac], esi
mov word [esp + 0x9c], si
mov dword [esp + 0x18], esi
push 0x6292b8
lea esi, [esp + 0x9c]
mov dword [esp + 0x70], ebx
mov dword [esp + 0xb4], ebx
call fcn.00405040
lea edx, [esp + 0x14]
push edx
mov eax, esi
push eax
lea ecx, [esp + 0xd4]
push ecx
lea ecx, [esp + 0x28]
mov byte [esp + 0x154], 0xd
call fcn.0045ecb0
mov byte [esp + 0x148], 0xc
cmp dword [esp + 0xac], edi
jb 0x474d16
mov edx, dword [esp + 0x98]
push edx
call fcn.005d2367
add esp, 4
cmp dword [esp + 0x1c], 0xf
jne 0x474ea0
mov eax, dword [0x677600]
mov edx, dword [eax + 0xc]
mov ecx, 0x677600
call edx
lea esi, [eax + 0x10]
mov dword [esp + 0x14], esi
mov byte [esp + 0x148], 0xe
mov eax, dword [esi - 8]
mov ecx, 1
sub ecx, dword [esi - 4]
sub eax, 0x104
or eax, ecx
jge 0x474d65
mov ecx, 0x104
lea eax, [esp + 0x14]
call fcn.00403540
mov esi, dword [esp + 0x14]
push esi
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
test esi, esi
jne 0x474d79
xor ecx, ecx
jmp 0x474d95
mov ecx, esi
lea edi, [ecx + 2]
mov edi, edi
mov dx, word [ecx]
add ecx, 2
test dx, dx
jne 0x474d80
sub ecx, edi
sar ecx, 1
js 0x4749c0
cmp ecx, dword [esi - 8]
jg 0x4749c0
test eax, eax
mov dword [esi - 0xc], ecx
mov word [esi + ecx*2], 0
jne 0x474e17
mov eax, dword [esi - 8]
mov ecx, 1
sub ecx, dword [esi - 4]
sub eax, 0x104
or eax, ecx
jge 0x474dd1
mov ecx, 0x104
lea eax, [esp + 0x14]
call fcn.00403540
mov esi, dword [esp + 0x14]
push 0
push 0x2e
push esi
push 0
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
test esi, esi
jne 0x474de6
xor eax, eax
jmp 0x474e05
mov eax, esi
lea edx, [eax + 2]
jmp 0x474df0
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x474df0
sub eax, edx
sar eax, 1
js 0x4749c0
cmp eax, dword [esi - 8]
jg 0x4749c0
mov dword [esi - 0xc], eax
mov word [esi + eax*2], 0
mov edx, str.QQPinyin_Camera_2CA8DCBA_B838_4ed9_A926_37F3313910A3.bmp
lea edi, [esp + 0x14]
call fcn.0040ae60
call dword [sym.imp.USER32.dll_GetDesktopWindow]
test eax, eax
je 0x474e78
push str.Tencent_QQPinyin_Dlg_F0D46D6A_3164_4fbc_8B10_CF5F40BAA268
call fcn.0047e900
mov esi, eax
test esi, esi
je 0x474e78
push esi
call dword [sym.imp.USER32.dll_IsWindow]
test eax, eax
je 0x474e78
xor eax, eax
mov dword [esp + 0x8c], eax
mov dword [esp + 0x90], eax
lea eax, [esp + 0x88]
push eax
push 0
push 0x4a
push esi
mov dword [esp + 0x98], 1
call dword [sym.imp.USER32.dll_SendMessageW]
mov byte [esp + 0x148], 0xc
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x474ea0
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
cmp byte [0x678eef], 0
je 0x474eb5
call fcn.004877d0
mov byte [0x678eef], 0
lea ecx, [esp + 0xcc]
mov byte [esp + 0x148], 5
call fcn.00403ba0
mov eax, dword [esp + 0x2c]
test eax, eax
je 0x474ed8
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov byte [esp + 0x148], 2
mov eax, dword [esp + 0x20]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x474f00
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x148], 1
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x474f28
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x24]
test eax, eax
je 0x475150
push eax
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
jmp 0x475150
push 0x37c
call fcn.005d2776
add esp, 4
mov dword [esp + 0x30], eax
test eax, eax
mov byte [esp + 0x148], 0xf
je 0x474f67
push eax
call fcn.00456400
mov edi, eax
jmp 0x474f69
xor edi, edi
push 0
mov byte [esp + 0x14c], 5
push 1
lea eax, [esp + 0x24]
mov dword [0x678fd4], edi
mov dword [esp + 0x24], 0xae
call fcn.004874e0
call fcn.004751a0
mov eax, dword [edi + 4]
push eax
push str.Tencent_QQPinyin_WND_532C65C7_31EE_4f2e_95AB_9E4230A07C92
push eax
call dword [sym.imp.USER32.dll_SetPropW]
mov esi, dword [ebp + 0x14]
mov ecx, dword [edi + 4]
push esi
push ecx
call dword [sym.imp.USER32.dll_ShowWindow]
test esi, esi
je 0x474fba
add dword [0x68300c], 1
push 0
push 0
push 0
lea edx, [esp + 0xbc]
push edx
call dword [sym.imp.USER32.dll_GetMessageW]
test eax, eax
je 0x475049
mov esi, dword [sym.imp.USER32.dll_SendMessageW]
mov ebx, dword [sym.imp.USER32.dll_IsDialogMessageW]
mov edi, edi
mov ecx, dword [edi + 4]
lea eax, [esp + 0xb0]
push eax
push ecx
call ebx
test eax, eax
jne 0x475031
cmp dword [esp + 0xb4], 0x200
jne 0x475015
lea edx, [esp + 0xb0]
push edx
push eax
mov eax, dword [0x67ebb0]
push 0x407
push eax
call esi
lea ecx, [esp + 0xb0]
push ecx
call dword [sym.imp.USER32.dll_TranslateMessage]
lea edx, [esp + 0xb0]
push edx
call dword [sym.imp.USER32.dll_DispatchMessageW]
push 0
push 0
push 0
lea eax, [esp + 0xbc]
push eax
call dword [sym.imp.USER32.dll_GetMessageW]
test eax, eax
jne 0x474fe0
call fcn.00474740
mov esi, dword [0x6790a8]
xor ebx, ebx
cmp esi, ebx
mov dword [0x6790a8], ebx
je 0x475078
lea ecx, [esi + 0xc]
push ecx
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
jg 0x475078
mov edx, dword [esi]
mov eax, dword [edx]
push 1
mov ecx, esi
call eax
mov edx, dword [edi]
mov eax, dword [edx + 4]
push 1
mov ecx, edi
call eax
mov eax, dword [0x678fc4]
cmp eax, ebx
mov edi, dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov dword [0x678fc8], ebx
mov dword [0x678fcc], ebx
je 0x4750a7
push eax
call edi
mov dword [0x678fc4], ebx
mov eax, dword [0x671f10]
cmp eax, ebx
je 0x4750bd
push eax
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov dword [0x671f10], ebx
mov eax, dword [0x671f0c]
cmp eax, ebx
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
je 0x4750d5
push eax
call esi
mov dword [0x671f0c], ebx
cmp byte [0x678eef], 0
je 0x4750ea
call fcn.004877d0
mov byte [0x678eef], 0
mov eax, dword [esp + 0x2c]
cmp eax, ebx
je 0x4750f5
push eax
call esi
mov byte [esp + 0x148], 2
mov eax, dword [esp + 0x20]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x47511d
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x148], 1
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x475145
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x24]
cmp eax, ebx
je 0x475150
push eax
call edi
call dword [sym.imp.ole32.dll_OleUninitialize]
xor eax, eax
mov ecx, dword [esp + 0x140]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x128]
xor ecx, esp
call fcn.005d28b3
mov esp, ebp
pop ebp
ret 0x10