Function at 0x404440
Capabilities:
Get common file path
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x68c
lea ecx, [ebp - 0x1c]
mov dword [ebp - 0x14], 0
xor edx, edx
push str.Recent_file_list
call dbg.registry_get_handle
add esp, 4
test eax, eax
jne 0x404862
mov eax, dword [ebp + 8]
movsd xmm0, qword [str._d]
movsd qword [ebp - 0x3a], xmm0
mov word [ebp - 0x32], 0
mov dword [ebp - 0x30], global_file1
mov dword [ebp - 0x2c], global_file2
mov dword [ebp - 0x28], global_file3
mov dword [ebp - 0x24], global_file4
mov dword [ebp - 0x18], 0x208
push eax
call dword [sym.imp.user32.dll_GetMenu]
mov edi, eax
mov dword [ebp - 0x6c], 0x30
mov dword [ebp - 0x68], 0x162
mov dword [ebp - 0x64], 0
lea eax, [ebp - 0x48e]
mov dword [ebp - 0x48], eax
mov dword [ebp - 0x5c], 0x3ed
push 0
push 0x3f1
push edi
call dword [sym.imp.user32.dll_RemoveMenu]
mov dword [ebp - 0x20], edi
jmp 0x404519
lea eax, [ebp - 0x6c]
push eax
push 0
push 0x3e8
mov edi, dword [ebp - 0x20]
push edi
call dword [sym.imp.user32.dll_InsertMenuItemW]
inc dword [ebp - 0x5c]
mov dword [ebp - 0x18], 0x208
cmp dword [ebp - 0x14], 4
je 0x404839
mov esi, dword [ebp - 0x14]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
push eax
push str.File_d
lea ebx, [ebp - 0x78]
push ebx
call dword [sym.imp.user32.dll_wsprintfW]
add esp, 0xc
lea eax, [esi + 0x3ed]
push 0
push eax
push edi
call dword [sym.imp.user32.dll_RemoveMenu]
mov esi, dword [ebp + esi*4 - 0x30]
lea eax, [ebp - 0x18]
push eax
push esi
push 0
push 0
push ebx
push dword [ebp - 0x1c]
call dword [sym.imp.advapi32.dll_RegQueryValueExW]
mov ecx, dword [sym.imp.user32.dll_wsprintfW]
test eax, eax
jne 0x404839
mov dword [ebp - 0x4c], esi
push dword [ebp - 0x14]
lea eax, [ebp - 0x3a]
push eax
lea eax, [ebp - 0x48e]
push eax
call ecx
add esp, 0xc
xor eax, eax
nop word cs:[eax + eax]
movzx ecx, word [esi + eax]
mov word [ebp + eax - 0x280], cx
add eax, 2
test cx, cx
jne 0x404590
sub esp, 0x14
lea esi, [ebp - 0x696]
mov dword [esp + 0x10], esi
movaps xmm0, xmmword [0x40c580]
movups xmmword [esp], xmm0
call dword [sym.imp.shell32.dll_SHGetFolderPathW]
lea ebx, [ebp - 0x280]
push ebx
call sym._file_basename
add esp, 4
mov edi, eax
mov word [eax - 2], 0
push esi
push ebx
call dword [sym.imp.kernel32.dll_lstrcmpiW]
test eax, eax
je 0x404600
mov eax, 0xfffffffe
nop word [eax + eax]
cmp word [edi + eax + 2], 0
lea eax, [eax + 2]
jne 0x4045f0
cmp eax, 0x43
jl 0x404640
mov word [edi - 2], 0x5c
lea eax, [ebp - 0x490]
nop dword [eax]
cmp word [eax + 2], 0
lea eax, [eax + 2]
jne 0x404610
xor ecx, ecx
nop dword [eax]
movzx edx, word [edi + ecx]
mov word [eax + ecx], dx
add ecx, 2
test dx, dx
jne 0x404620
jmp 0x4044f0
mov word [edi - 2], 0x5c
xor edx, edx
mov ecx, 0
lea eax, [ebp - 0x280]
cmp edi, eax
jbe 0x404760
xor esi, esi
mov eax, 0xfffffffe
lea edx, [ebp - 0x280]
jmp 0x40467a
add edx, 2
add eax, 2
cmp edx, edi
jae 0x4046bb
movzx ecx, word [edx]
cmp ecx, 0x5c
je 0x404687
cmp ecx, 0x2f
jne 0x404670
test esi, esi
jne 0x4046c4
mov ecx, 0xfffffffe
cmp word [edi + ecx + 2], 0
lea ecx, [ecx + 2]
jne 0x404690
mov esi, edx
lea ebx, [ebp - 0x280]
sub esi, ebx
sar esi, 1
sar ecx, 1
add ecx, esi
mov esi, edx
cmp ecx, 0x21
jle 0x404670
xor edx, edx
xor ecx, ecx
jmp 0x404760
xor ecx, ecx
mov edx, esi
jmp 0x404760
mov ebx, 0xfffffffe
nop dword [eax]
cmp word [edi + ebx + 2], 0
lea ebx, [ebx + 2]
jne 0x4046d0
mov dword [ebp - 0x10], edx
lea ecx, [ebp - 0x280]
sub dword [ebp - 0x10], ecx
mov ecx, dword [ebp - 0x10]
sar ecx, 1
sar ebx, 1
add ebx, ecx
xor ecx, ecx
mov dword [ebp - 0x10], edx
cmp ebx, 0x22
mov ebx, dword [ebp - 0x10]
cmovge ebx, esi
mov dword [ebp - 0x10], ebx
jl 0x404707
mov edx, esi
jmp 0x404760
cmp edi, edx
jb 0x404760
xor ecx, ecx
mov edx, edi
jmp 0x40472f
mov esi, ecx
add edx, 0xfffffffe
add eax, 2
mov ecx, esi
cmp edx, dword [ebp - 0x10]
jb 0x404758
movzx esi, word [edx]
cmp esi, 0x5c
je 0x40473c
cmp esi, 0x2f
jne 0x404720
mov ebx, eax
mov esi, edi
add ebx, 2
cmp word [esi], 0
lea esi, [esi + 2]
jne 0x404740
mov esi, edx
cmp ebx, 0x42
jle 0x404722
mov edx, dword [ebp - 0x10]
jmp 0x404760
mov edx, dword [ebp - 0x10]
mov ecx, esi
nop dword [eax]
cmp edx, edi
je 0x404606
cmp edx, ecx
je 0x404805
test ecx, ecx
je 0x404805
mov word [edx + 2], 0
lea eax, [ebp - 0x490]
nop word cs:[eax + eax]
cmp word [eax + 2], 0
lea eax, [eax + 2]
jne 0x404790
xor edx, edx
nop dword [eax]
movzx esi, word [ebp + edx - 0x280]
mov word [eax + edx], si
add edx, 2
test si, si
jne 0x4047a0
lea eax, [ebp - 0x48e]
nop word [eax + eax]
cmp word [eax], 0
lea eax, [eax + 2]
jne 0x4047c0
movsd xmm0, qword [0x40c590]
movsd qword [eax - 2], xmm0
lea eax, [ebp - 0x490]
nop dword [eax]
cmp word [eax + 2], 0
lea eax, [eax + 2]
jne 0x4047e0
xor edx, edx
nop dword [eax]
movzx esi, word [ecx + edx]
mov word [eax + edx], si
add edx, 2
test si, si
jne 0x4047f0
jmp 0x4044f0
lea eax, [ebp - 0x490]
nop dword [eax + eax]
cmp word [eax + 2], 0
lea eax, [eax + 2]
jne 0x404810
xor ecx, ecx
nop dword [eax]
movzx edx, word [ebp + ecx - 0x280]
mov word [eax + ecx], dx
add ecx, 2
test dx, dx
jne 0x404820
jmp 0x4044f0
mov dword [ebp - 0x64], 0x800
mov dword [ebp - 0x68], 0x102
lea eax, [ebp - 0x6c]
push eax
push 0
push 0x3e8
push edi
call dword [sym.imp.user32.dll_InsertMenuItemW]
push dword [ebp - 0x1c]
call dword [sym.imp.advapi32.dll_RegCloseKey]
add esp, 0x68c
pop esi
pop edi
pop ebx
pop ebp
ret