Function at 0x40d6af
Capabilities:
Accept command line arguments
Check if file exists
Create thread
Get common file path
Query or enumerate registry value
Resume thread

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1d88
call fcn.0041be40
and dword [ebp - 0x18], 0
push ebx
push esi
push edi
mov esi, ecx
call section..text
mov dword [esi + 0x10], eax
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
test eax, eax
mov dword [ebp - 0x14], eax
mov ebx, 0x81
je 0x40d83f
and word [ebp - 0x320], 0
mov ecx, ebx
xor eax, eax
lea edi, [ebp - 0x31e]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x320]
push 0x103
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea eax, [ebp - 0x320]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFindFileNameW]
and word [ebp - 0x98], 0
push 0x1f
mov dword [ebp - 8], eax
pop ecx
xor eax, eax
lea edi, [ebp - 0x96]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov edi, dword [ebp - 0x14]
lea eax, [ebp - 0x98]
push 0x3f
push eax
push str._cid:
push edi
call fcn.00402abe
add esp, 0x10
test eax, eax
je 0x40d75c
cmp word [ebp - 0x98], 0
jne 0x40d77d
lea eax, [ebp - 0x98]
push 0x3f
push eax
mov ecx, esi
push dword [ebp - 8]
call fcn.0040f175
test eax, eax
je 0x40d79c
cmp word [ebp - 0x98], 0
je 0x40d79c
lea eax, [ebp - 0x98]
push eax
call dword [sym.imp.MSVCRT.dll_wcslen]
pop ecx
push eax
lea eax, [ebp - 0x98]
push eax
lea ecx, [esi + 0x34]
call dword [sym.imp.MSVCP60.dll_public:_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int______thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::assign_unsigned_short_int_const___unsigned_int_]
and dword [ebp - 4], 0
lea eax, [ebp - 4]
push eax
push str._lnk:
push edi
call fcn.00402b6c
add esp, 0xc
test eax, eax
jne 0x40d7ca
lea eax, [ebp - 4]
mov ecx, esi
push eax
push 1
push dword [ebp - 8]
call fcn.0040f2cc
test eax, eax
je 0x40d7d5
xor eax, eax
cmp dword [ebp - 4], eax
setne al
mov dword [esi + 0x20], eax
lea eax, [ebp - 4]
push eax
push str._def:
push edi
call fcn.00402b6c
add esp, 0xc
test eax, eax
jne 0x40d7ff
lea eax, [ebp - 4]
mov ecx, esi
push eax
push 2
push dword [ebp - 8]
call fcn.0040f2cc
test eax, eax
je 0x40d80a
xor eax, eax
cmp dword [ebp - 4], eax
setne al
mov dword [esi + 0x24], eax
lea eax, [ebp - 4]
push eax
push str._run:
push edi
call fcn.00402b6c
add esp, 0xc
test eax, eax
jne 0x40d834
lea eax, [ebp - 4]
mov ecx, esi
push eax
push 3
push dword [ebp - 8]
call fcn.0040f2cc
test eax, eax
je 0x40d83f
xor eax, eax
cmp dword [ebp - 4], eax
setne al
mov dword [esi + 0x28], eax
and word [ebp - 0x118], 0
push 0x1f
pop ecx
xor eax, eax
lea edi, [ebp - 0x116]
and word [ebp - 0x1978], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov ecx, ebx
xor eax, eax
lea edi, [ebp - 0x1976]
push 0x103
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x1978]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea eax, [ebp - 0x118]
push 0x40
push eax
lea eax, [ebp - 0x1978]
push eax
call fcn.00401120
add esp, 0xc
test eax, eax
je 0x40de86
lea eax, [ebp - 0x118]
lea edi, [esi + 0x44]
push eax
call dword [sym.imp.MSVCRT.dll_wcslen]
pop ecx
push eax
lea eax, [ebp - 0x118]
push eax
mov ecx, edi
call dword [sym.imp.MSVCP60.dll_public:_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int______thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::assign_unsigned_short_int_const___unsigned_int_]
xor edx, edx
mov ecx, ebx
xor eax, eax
lea edi, [ebp - 0x936]
mov word [ebp - 0x938], dx
push edx
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x938]
push 2
push eax
push edx
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
test eax, eax
je 0x40de86
lea eax, [ebp - 0x938]
push eax
call dword [sym.imp.MSVCRT.dll_wcslen]
pop ecx
push eax
lea eax, [ebp - 0x938]
push eax
lea ecx, [esi + 0xf4]
call dword [sym.imp.MSVCP60.dll_public:_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int______thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::assign_unsigned_short_int_const___unsigned_int_]
and word [ebp - 0x1770], 0
mov ecx, ebx
xor eax, eax
lea edi, [ebp - 0x176e]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x938]
push 0x423e54
push eax
lea eax, [ebp - 0x1770]
push eax
call dword [sym.imp.SHLWAPI.dll_PathCombineW]
lea eax, [ebp - 0x1770]
push eax
call dword [sym.imp.MSVCRT.dll_wcslen]
pop ecx
push eax
lea eax, [ebp - 0x1770]
push eax
lea ecx, [esi + 0x104]
call dword [sym.imp.MSVCP60.dll_public:_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int______thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::assign_unsigned_short_int_const___unsigned_int_]
xor edx, edx
mov ecx, ebx
xor eax, eax
lea edi, [ebp - 0x72e]
mov word [ebp - 0x730], dx
push edx
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x730]
push 0x17
push eax
push edx
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
test eax, eax
je 0x40de86
lea eax, [ebp - 0x730]
push eax
call dword [sym.imp.MSVCRT.dll_wcslen]
pop ecx
push eax
lea eax, [ebp - 0x730]
push eax
lea ecx, [esi + 0x134]
call dword [sym.imp.MSVCP60.dll_public:_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int______thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::assign_unsigned_short_int_const___unsigned_int_]
and word [ebp - 0x1158], 0
mov ecx, ebx
xor eax, eax
lea edi, [ebp - 0x1156]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x730]
push 0x423e54
push eax
lea eax, [ebp - 0x1158]
push eax
call dword [sym.imp.SHLWAPI.dll_PathCombineW]
lea eax, [ebp - 0x1158]
push eax
call dword [sym.imp.MSVCRT.dll_wcslen]
pop ecx
push eax
lea eax, [ebp - 0x1158]
push eax
lea ecx, [esi + 0x144]
call dword [sym.imp.MSVCP60.dll_public:_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int______thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::assign_unsigned_short_int_const___unsigned_int_]
xor edx, edx
mov ecx, ebx
xor eax, eax
lea edi, [ebp - 0xf4e]
mov word [ebp - 0xf50], dx
push edx
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0xf50]
push 0xb
push eax
push edx
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
test eax, eax
je 0x40de86
lea eax, [ebp - 0xf50]
push eax
call dword [sym.imp.MSVCRT.dll_wcslen]
pop ecx
push eax
lea eax, [ebp - 0xf50]
push eax
lea ecx, [esi + 0x114]
call dword [sym.imp.MSVCP60.dll_public:_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int______thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::assign_unsigned_short_int_const___unsigned_int_]
xor edx, edx
mov ecx, ebx
xor eax, eax
lea edi, [ebp - 0x1566]
mov word [ebp - 0x1568], dx
push edx
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x1568]
push 0x16
push eax
push edx
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
test eax, eax
je 0x40de86
lea eax, [ebp - 0x1568]
push eax
call dword [sym.imp.MSVCRT.dll_wcslen]
pop ecx
push eax
lea eax, [ebp - 0x1568]
push eax
lea ecx, [esi + 0x154]
call dword [sym.imp.MSVCP60.dll_public:_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int______thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::assign_unsigned_short_int_const___unsigned_int_]
xor edx, edx
mov ecx, ebx
xor eax, eax
lea edi, [ebp - 0x135e]
mov word [ebp - 0x1360], dx
push edx
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x1360]
push 0x10
push eax
push edx
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
test eax, eax
je 0x40de86
lea eax, [ebp - 0x1360]
push eax
call dword [sym.imp.MSVCRT.dll_wcslen]
pop ecx
push eax
lea eax, [ebp - 0x1360]
push eax
lea ecx, [esi + 0x124]
call dword [sym.imp.MSVCP60.dll_public:_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int______thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::assign_unsigned_short_int_const___unsigned_int_]
xor edx, edx
mov ecx, ebx
xor eax, eax
lea edi, [ebp - 0xb3e]
mov word [ebp - 0xb40], dx
push edx
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0xb40]
push 0x19
push eax
push edx
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
test eax, eax
je 0x40de86
lea eax, [ebp - 0xb40]
push eax
call dword [sym.imp.MSVCRT.dll_wcslen]
pop ecx
push eax
lea eax, [ebp - 0xb40]
push eax
lea ecx, [esi + 0x164]
call dword [sym.imp.MSVCP60.dll_public:_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int______thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::assign_unsigned_short_int_const___unsigned_int_]
xor edx, edx
mov ecx, ebx
xor eax, eax
lea edi, [ebp - 0x1b7e]
mov word [ebp - 0x1b80], dx
push edx
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x1b80]
push 0x1a
push eax
push edx
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
test eax, eax
je 0x40de86
and word [ebp - 0xd48], 0
mov ecx, ebx
xor eax, eax
lea edi, [ebp - 0xd46]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x1b80]
push str.MicrosoftInternet_ExplorerQuick_Launch
push eax
lea eax, [ebp - 0xd48]
push eax
call dword [sym.imp.SHLWAPI.dll_PathCombineW]
lea eax, [ebp - 0xd48]
push eax
call dword [sym.imp.MSVCRT.dll_wcslen]
pop ecx
push eax
lea eax, [ebp - 0xd48]
push eax
lea ecx, [esi + 0xe4]
call dword [sym.imp.MSVCP60.dll_public:_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int______thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::assign_unsigned_short_int_const___unsigned_int_]
and word [ebp - 0x528], 0
mov ecx, ebx
xor eax, eax
lea edi, [ebp - 0x526]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0xc]
mov edi, str.SoftwareMicrosoftWindowsCurrentVersionApp_Pathshao123JuziBrowser.exe
push eax
lea eax, [ebp - 0x528]
push eax
lea eax, [ebp - 0x10]
push eax
push str.Path
push edi
push SysReAllocString
mov dword [ebp - 0x10], 1
mov dword [ebp - 0xc], 0x206
call dword [sym.imp.SHLWAPI.dll_SHGetValueW]
test eax, eax
jne 0x40dc2e
lea eax, [ebp - 0x528]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x40dc78
cmp dword [esi + 0x10], 8
jge 0x40dc78
push 0x208
lea eax, [ebp - 0x528]
push 0
push eax
call sub.MSVCRT.dll_memset
add esp, 0xc
lea eax, [ebp - 0xc]
mov dword [ebp - 0x10], 1
mov dword [ebp - 0xc], 0x206
push eax
lea eax, [ebp - 0x528]
push eax
lea eax, [ebp - 0x10]
push eax
push str.Path
push edi
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.SHLWAPI.dll_SHGetValueW]
lea eax, [ebp - 0x528]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x40dd40
and word [ebp - 0x320], 0
mov ecx, ebx
xor eax, eax
lea edi, [ebp - 0x31e]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x528]
push str.hao123Juzi.exe
push eax
lea eax, [ebp - 0x320]
push eax
call dword [sym.imp.SHLWAPI.dll_PathCombineW]
and word [ebp - 0x98], 0
push 0x1f
pop ecx
xor eax, eax
lea edi, [ebp - 0x96]
push 0x40
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x98]
push eax
lea eax, [ebp - 0x320]
push eax
call fcn.00401120
xor edi, edi
add esp, 0xc
cmp word [ebp - 0x98], di
je 0x40dd20
mov eax, dword [esi + 0x48]
cmp eax, edi
jne 0x40dd02
mov eax, dword [sym.imp.MSVCP60.dll_unsigned_short_int_const__private:_static_unsigned_short_int_const____cdecl_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Nullstr_void_::_2::_C]
push eax
lea eax, [ebp - 0x98]
push eax
call fcn.00401202
pop ecx
cmp eax, edi
pop ecx
jge 0x40dd1e
mov dword [esi + 0x14], 1
jmp 0x40dd30
jne 0x40dd29
mov dword [esi + 0x14], 2
jmp 0x40dd30
mov dword [esi + 0x14], 3
lea eax, [ebp - 0x528]
mov ecx, esi
push eax
call fcn.0040ee9c
jmp 0x40ddb4
and word [ebp - 0x320], 0
mov ecx, ebx
xor eax, eax
lea edi, [ebp - 0x31e]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x14]
mov dword [ebp - 8], 1
push eax
lea eax, [ebp - 0x320]
push eax
lea eax, [ebp - 8]
push eax
push str.lastinstpath
push str.Softwarehao123JuziBrowser
push SysReAllocString
mov dword [ebp - 0x14], 0x206
call dword [sym.imp.SHLWAPI.dll_SHGetValueW]
test eax, eax
jne 0x40ddb2
lea eax, [ebp - 0x320]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x40ddb2
lea eax, [ebp - 0x320]
mov ecx, esi
push eax
mov dword [esi + 0x14], 4
call fcn.0040ee9c
xor edi, edi
cmp dword [esi + 0x7c], edi
jne 0x40de2d
mov dword [esi + 0x14], edi
mov word [ebp - 0x320], di
mov ecx, ebx
xor eax, eax
lea edi, [ebp - 0x31e]
cmp dword [esi + 0x10], 8
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
push 0
jge 0x40dddd
push 0x26
jmp 0x40dddf
push 0x1a
lea eax, [ebp - 0x320]
push eax
push 0
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
and word [ebp - 0x1d88], 0
mov ecx, ebx
xor eax, eax
lea edi, [ebp - 0x1d86]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea eax, [ebp - 0x320]
push str.hao123JuziBrowser
push eax
lea eax, [ebp - 0x1d88]
push eax
call dword [sym.imp.SHLWAPI.dll_PathCombineW]
lea eax, [ebp - 0x1d88]
mov ecx, esi
push eax
call fcn.0040ee9c
xor edi, edi
lea eax, [esi + 4]
push eax
push 4
push esi
push 0x40de8e
push edi
push edi
call dword [sym.imp.KERNEL32.dll_CreateThread]
cmp eax, edi
mov dword [ebp - 8], eax
je 0x40de86
push edi
push edi
push edi
push edi
call dword [sym.imp.KERNEL32.dll_CreateEventW]
push dword [ebp - 8]
mov dword [esi + 0xc], eax
call dword [sym.imp.KERNEL32.dll_ResumeThread]
push 0x3e8
push dword [esi + 0xc]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push dword [esi + 0xc]
mov ebx, dword [sym.imp.KERNEL32.dll_CloseHandle]
call ebx
push dword [ebp - 8]
mov dword [esi + 0xc], edi
call ebx
mov dword [ebp - 0x18], 1
mov eax, dword [ebp - 0x18]
pop edi
pop esi
pop ebx
leave
ret