Function at 0x40d090
Capabilities:
Create process on windows
Get common file path

Disassembly:
push ebp
lea ebp, [esp - 0x5464]
mov eax, 0x5464
call fcn.00502fa0
push 0xffffffffffffffff
push 0x51afa8
mov eax, dword fs:[0]
push eax
sub esp, 0x44
mov eax, dword [0x5513d4]
xor eax, ebp
mov dword [ebp + 0x5460], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov bh, byte [ebp + 0x546c]
mov byte [ebp - 0x14], bh
push 1
push 0x800
lea eax, [ebp + 0x4460]
push eax
call fcn.004847a0
push 0x800
lea eax, [ebp + 0x4460]
push eax
call fcn.004836c0
push 0x800
push str.Settings.reg
lea eax, [ebp + 0x4460]
push eax
call fcn.0049ce50
push 0x800
lea eax, [ebp + 0x4460]
push eax
lea eax, [ebp + 0x60]
push eax
call fcn.0049ce90
test bh, bh
je 0x40d1dd
push 1
push str.ExportedSettings
push 0x52452c
call fcn.004af150
cmp byte [ebp + 0x5470], 0
jne 0x40d17b
push dword [ebp - 0x14]
push str..reg
lea eax, [ebp + 0x4460]
push eax
xor eax, eax
test bh, bh
sete al
add eax, 0x5b4
push eax
call fcn.00496b20
push eax
push dword [0x558aa8]
call fcn.00409850
test al, al
je 0x40d1d6
test bh, bh
jne 0x40d2c6
lea ecx, [ebp]
call fcn.0049cee0
mov dword [ebp - 4], 0
mov byte [ebp - 4], 1
push 0
push 0
push 0
push 0
push 0
push 0
lea eax, [ebp]
push eax
lea eax, [ebp + 0x4460]
push eax
call fcn.00475500
test al, al
jne 0x40d230
lea eax, [ebp + 0x4460]
push eax
mov ecx, 0x58c304
call fcn.0046dc70
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp]
call fcn.00404c50
xor al, al
jmp 0x40d4bb
push 0
push 1
push 0x800
lea eax, [ebp + 0x4460]
push eax
push str.Settings.reg
call fcn.00484580
lea eax, [ebp + 0x4460]
push eax
call fcn.00474160
test al, al
jne 0x40d141
cmp byte [ebp + 0x5470], al
jne 0x40d1d6
push 0x800
lea eax, [ebp + 0x60]
push eax
lea eax, [ebp + 0x4460]
push eax
call fcn.0049ce90
jmp 0x40d14a
lea eax, [ebp - 0x14]
push eax
lea ecx, [ebp]
call fcn.0049d020
test al, al
je 0x40d2a6
mov eax, dword [ebp - 0x14]
cmp word [eax], 0x5b
jne 0x40d230
push 0x22
push str._HKEY_CURRENT_USERSoftwareWinRAR
push eax
call fcn.004a0630
test eax, eax
mov eax, dword [ebp - 0x14]
jne 0x40d26f
movzx ecx, word [eax + 0x44]
cmp ecx, 0x5c
je 0x40d26b
cmp ecx, 0x5d
jne 0x40d26f
mov bl, 1
jmp 0x40d271
xor bl, bl
push 0x23
push str._HKEY_LOCAL_MACHINESoftwareWinRAR
push eax
call fcn.004a0630
test eax, eax
jne 0x40d297
mov eax, dword [ebp - 0x14]
movzx eax, word [eax + 0x46]
cmp eax, 0x5c
je 0x40d293
cmp eax, 0x5d
jne 0x40d297
mov al, 1
jmp 0x40d299
xor al, al
test bl, bl
jne 0x40d230
test al, al
jne 0x40d230
jmp 0x40d1c7
mov dword [ebp - 4], 0
push 0x52452c
call fcn.004add00
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp]
call fcn.00404c50
lea eax, [ebp + 0x1060]
push eax
push 1
push 0
push 0x24
push 0
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
push 0x800
lea eax, [ebp + 0x1060]
push eax
push str.regedit.exe
push eax
call fcn.00484d90
lea eax, [ebp + 0x4460]
push eax
lea eax, [ebp + 0x2060]
test bh, bh
je 0x40d31a
push str._e___s__HKEY_CURRENT_USERSoftwareWinRAR
jmp 0x40d31f
push 0x525334
push 0x900
push eax
call fcn.004027c0
add esp, 0x10
push 0x3c
push 0
lea eax, [ebp - 0x50]
push eax
call fcn.00505530
add esp, 0xc
mov dword [ebp - 0x50], 0x3c
mov dword [ebp - 0x4c], 0x40
mov eax, dword [0x558aa8]
mov dword [ebp - 0x48], eax
lea eax, [ebp + 0x1060]
mov dword [ebp - 0x40], eax
lea eax, [ebp + 0x2060]
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x34], 1
lea eax, [ebp - 0x50]
push eax
call dword [sym.imp.SHELL32.dll_ShellExecuteExW]
test eax, eax
setne bl
test bl, bl
je 0x40d396
push 0x2710
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test bh, bh
je 0x40d43a
test bl, bl
je 0x40d42b
push 0x800
lea eax, [ebp + 0x4460]
push eax
lea eax, [ebp + 0x3460]
push eax
call fcn.0049ce90
push 0x800
lea eax, [ebp + 0x3460]
push eax
call fcn.004747e0
test eax, eax
je 0x40d42b
lea eax, [ebp + 0x3460]
push eax
push str._e___s__HKEY_LOCAL_MACHINESoftwareWinRAR
push 0x900
lea eax, [ebp + 0x2060]
push eax
call fcn.004027c0
add esp, 0x10
lea eax, [ebp - 0x50]
push eax
call dword [sym.imp.SHELL32.dll_ShellExecuteExW]
test eax, eax
je 0x40d42b
push 0x2710
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea eax, [ebp + 0x3460]
push eax
lea eax, [ebp + 0x4460]
push eax
call fcn.0040e620
push str.ExportedSettings
push 0x52452c
call fcn.004ae060
test bl, bl
je 0x40d496
test bh, bh
jne 0x40d447
call fcn.0040cfe0
lea eax, [ebp + 0x4460]
push eax
xor eax, eax
test bh, bh
sete al
add eax, 0x460
push eax
call fcn.00496b20
push eax
push 0x900
lea eax, [ebp + 0x3260]
push eax
call fcn.004027c0
add esp, 0x10
push 0
push 0x2fb
call fcn.00496b20
push eax
lea eax, [ebp + 0x3260]
push eax
push dword [0x558aa8]
call fcn.004d6c50
jmp 0x40d4b9
cmp byte [ebp + 0x5470], 0
jne 0x40d4b9
lea eax, [ebp + 0x2060]
push eax
push 0x201
call fcn.00496b20
push eax
call fcn.004db310
add esp, 8
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x5460]
xor ecx, ebp
call fcn.00502f8e
lea esp, [ebp + 0x5464]
pop ebp
ret 8