Function at 0x401940
Capabilities:
Check if file exists
Create a process with modified i/o handles and window
Create process on windows
Delete file
Get common file path
Get file attributes
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
mov eax, 0x144c
call fcn.00402da0
mov eax, dword [0x40b0fc]
push ebx
push esi
xor eax, ebp
push edi
xor ebx, ebx
mov dword [esp + 0x1454], eax
lea eax, [esp + 0x10]
push eax
push 0x20019
push ebx
push str.ppfilm_shellopencommand
push 0x80000000
mov dword [esp + 0x38], ebx
mov dword [esp + 0x20], ebx
mov dword [esp + 0x24], ebx
mov byte [esp + 0x1fc], bl
mov byte [esp + 0x12c], bl
mov byte [esp + 0x194], bl
mov byte [esp + 0xc4], bl
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
mov esi, dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
jne 0x401ad2
lea ecx, [esp + 0x28]
push ecx
mov ecx, dword [esp + 0x14]
lea edx, [esp + 0x254]
push edx
lea eax, [esp + 0x34]
push eax
push ebx
push 0x409200
push ecx
mov dword [esp + 0x44], 1
mov dword [esp + 0x40], 0x400
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x401ac3
lea edx, [esp + 0x250]
push 0x25
push edx
call fcn.00403250
add esp, 8
cmp eax, ebx
je 0x401a08
mov byte [eax - 1], bl
push 0x400
lea eax, [esp + 0x654]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea ecx, [esp + 0x250]
push ecx
lea edx, [esp + 0x654]
push edx
call section..text
add esp, 8
cmp eax, ebx
jg 0x401ac3
lea eax, [esp + 0x250]
push 0x5c
push eax
call fcn.00403210
add esp, 8
cmp eax, ebx
je 0x401a81
mov ecx, dword [str.PIPIPlayer.exe]
inc eax
mov dword [eax], ecx
mov edx, dword [0x4094a4]
mov dword [eax + 4], edx
mov ecx, dword [0x4094a8]
mov dword [eax + 8], ecx
mov dx, word [0x4094ac]
mov word [eax + 0xc], dx
mov cl, byte [0x4094ae]
mov byte [eax + 0xe], cl
lea edx, [esp + 0x250]
push edx
call esi
cmp eax, 0xffffffff
je 0x401ac3
lea eax, [esp + 0x650]
push str._show
push eax
call fcn.00402e40
add esp, 8
test eax, eax
je 0x402069
lea ecx, [esp + 0x250]
push ebx
push ecx
call fcn.00401110
add esp, 8
jmp 0x402069
mov edx, dword [esp + 0x10]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov dword [esp + 0x10], ebx
push 0x400
lea eax, [esp + 0xc54]
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
lea eax, [esp + 0xc50]
lea edx, [eax + 1]
nop
mov cl, byte [eax]
inc eax
cmp cl, bl
jne 0x401af0
sub eax, edx
xor ecx, ecx
cmp eax, ebx
jle 0x401b1f
nop
mov dl, byte [esp + ecx + 0xc50]
cmp dl, 0x2f
je 0x401b18
cmp dl, 0x5c
je 0x401b18
inc ecx
cmp ecx, eax
jl 0x401b00
jmp 0x401b1f
mov byte [esp + ecx + 0xc50], bl
push str.Program_FilesppfilmjfCacheMgr.exe
lea ecx, [esp + 0xc54]
push ecx
lea edx, [esp + 0x258]
push str._s_s
push edx
call fcn.00402d00
mov edi, dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
add esp, 0x10
push 0x400
lea eax, [esp + 0x654]
push eax
push ebx
call edi
lea ecx, [esp + 0x250]
push ecx
lea edx, [esp + 0x654]
push edx
call section..text
add esp, 8
cmp eax, ebx
jg 0x401bc8
push str.Program_FilesppfilmPIPIPlayer.exe
lea eax, [esp + 0xc54]
push eax
lea ecx, [esp + 0x258]
push str._s_s
push ecx
call fcn.00402d00
add esp, 0x10
lea edx, [esp + 0x250]
push edx
call esi
cmp eax, 0xffffffff
je 0x401bc8
lea eax, [esp + 0x650]
push str._show
push eax
call fcn.00402e40
add esp, 8
test eax, eax
je 0x402069
push str.Program_FilesppfilmPIPIPlayer.exe
jmp 0x401c3c
push str.Program_FilespipijfCacheMgr.exe
lea ecx, [esp + 0xc54]
push ecx
lea edx, [esp + 0x258]
push str._s_s
push edx
call fcn.00402d00
add esp, 0x10
push 0x400
lea eax, [esp + 0x654]
push eax
push ebx
call edi
lea ecx, [esp + 0x250]
push ecx
lea edx, [esp + 0x654]
push edx
call section..text
add esp, 8
test eax, eax
jg 0x401cb5
lea eax, [esp + 0x650]
push str._show
push eax
call fcn.00402e40
add esp, 8
test eax, eax
je 0x402069
push str.Program_FilespipiPIPIPlayer.exe
lea ecx, [esp + 0xc54]
push ecx
lea edx, [esp + 0x258]
push str._s_s
push edx
call fcn.00402d00
add esp, 0x10
xor eax, eax
mov ecx, 0x11
lea edi, [esp + 0x30]
rep stosd dword es:[edi], eax
lea ecx, [esp + 0x14]
push ecx
lea edx, [esp + 0x34]
push edx
push ebx
push ebx
push ebx
mov dword [esp + 0x28], eax
push ebx
mov dword [esp + 0x30], eax
mov dword [esp + 0x34], eax
push ebx
mov dword [esp + 0x3c], eax
push ebx
lea eax, [esp + 0x270]
push eax
push ebx
mov dword [esp + 0x58], 0x44
mov dword [esp + 0x84], 0x101
mov word [esp + 0x88], bx
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
jmp 0x402069
push ebx
push str.ppfilm_class
call dword [sym.imp.USER32.dll_FindWindowA]
cmp eax, ebx
je 0x401ce8
push 0xffffffffffffffeb
push eax
call dword [sym.imp.USER32.dll_GetWindowLongA]
cmp eax, ebx
je 0x401ce8
push ebx
push ebx
push 0x12
push eax
call dword [sym.imp.USER32.dll_PostMessageA]
push 0x3e8
call dword [sym.imp.KERNEL32.dll_Sleep]
push str.Program_Filespipiconfigconfig.ini
lea ecx, [esp + 0xc54]
push ecx
lea edx, [esp + 0x1058]
push str._s_s
push edx
call fcn.00402d00
lea edi, [esp + 0xc60]
add esp, 0x10
dec edi
mov al, byte [edi + 1]
inc edi
cmp al, bl
jne 0x401d12
mov ecx, 0xa
mov esi, str.Program_Filespipiconfigclienttype.ini
rep movsd dword es:[edi], dword [esi]
push 0x400
lea eax, [esp + 0x654]
push eax
push ebx
movsw word es:[edi], word [esi]
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea eax, [esp + 0x650]
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
cmp cl, bl
jne 0x401d46
sub eax, edx
dec eax
cmp eax, ebx
jl 0x401d71
mov cl, byte [esp + eax + 0x650]
cmp cl, 0x2f
je 0x401d6a
cmp cl, 0x5c
je 0x401d6a
dec eax
jns 0x401d54
jmp 0x401d71
mov byte [esp + eax + 0x650], bl
lea ecx, [esp + 0x7c]
push ecx
lea edx, [esp + 0x1ec]
push edx
lea eax, [esp + 0xb8]
push eax
lea ecx, [esp + 0x18c]
push ecx
lea edx, [esp + 0x128]
push edx
lea eax, [esp + 0x20]
push eax
lea ecx, [esp + 0x3c]
push ecx
mov byte [esp + 0x204], bl
mov byte [esp + 0x98], bl
mov byte [esp + 0xcc], bl
mov byte [esp + 0x19c], bl
mov byte [esp + 0x134], bl
call fcn.00401460
mov edi, dword [esp + 0x40]
add esp, 0x1c
cmp edi, ebx
je 0x401f06
mov esi, dword [esp + 0xc]
cmp esi, ebx
lea eax, [esp + 0x1e8]
lea edx, [eax + 1]
je 0x401e80
lea ecx, [ecx]
mov cl, byte [eax]
inc eax
cmp cl, bl
jne 0x401df0
sub eax, edx
push esi
mov dword [esp + 0x10], eax
push edi
je 0x401e43
lea edx, [esp + 0x1f0]
push edx
lea eax, [esp + 0x88]
push eax
lea ecx, [esp + 0xc0]
push ecx
lea edx, [esp + 0x194]
push edx
lea eax, [esp + 0x130]
push eax
lea ecx, [esp + 0xa6c]
push str.pipi_setup_s_s_s_s__s__u__u.exe
push ecx
call fcn.00402d00
add esp, 0x24
jmp 0x401f38
lea edx, [esp + 0x84]
push edx
lea eax, [esp + 0xbc]
push eax
lea ecx, [esp + 0x190]
push ecx
lea edx, [esp + 0x12c]
push edx
lea eax, [esp + 0xa68]
push str.pipi_setup_s_s_s_s__u__u.exe
push eax
call fcn.00402d00
add esp, 0x20
jmp 0x401f38
mov cl, byte [eax]
inc eax
cmp cl, bl
jne 0x401e80
sub eax, edx
mov dword [esp + 0xc], eax
push edi
je 0x401ecf
lea ecx, [esp + 0x1ec]
push ecx
lea edx, [esp + 0x84]
push edx
lea eax, [esp + 0xbc]
push eax
lea ecx, [esp + 0x190]
push ecx
lea edx, [esp + 0x12c]
push edx
lea eax, [esp + 0xa68]
push str.pipi_setup_s_s_s_s__s__u.exe
push eax
call fcn.00402d00
add esp, 0x20
jmp 0x401f38
lea ecx, [esp + 0x80]
push ecx
lea edx, [esp + 0xb8]
push edx
lea eax, [esp + 0x18c]
push eax
lea ecx, [esp + 0x128]
push ecx
lea edx, [esp + 0xa64]
push str.pipi_setup_s_s_s_s__u.exe
push edx
call fcn.00402d00
add esp, 0x1c
jmp 0x401f38
lea eax, [esp + 0x7c]
push eax
lea ecx, [esp + 0xb4]
push ecx
lea edx, [esp + 0x120]
push edx
lea eax, [esp + 0x18c]
push eax
lea ecx, [esp + 0xa60]
push str.pipi_setup_s_s_s_s_clean_585.exe
push ecx
call fcn.00402d00
add esp, 0x18
lea eax, [esp + 0xa50]
mov edx, eax
mov cl, byte [eax]
inc eax
cmp cl, bl
jne 0x401f41
lea edi, [esp + 0x650]
sub eax, edx
dec edi
mov cl, byte [edi + 1]
inc edi
cmp cl, bl
jne 0x401f52
mov ecx, eax
shr ecx, 2
mov esi, edx
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
lea edx, [esp + 0x650]
and ecx, 3
push edx
rep movsb byte es:[edi], byte [esi]
call fcn.004018b0
add esp, 4
xor eax, eax
lea esp, [esp]
mov cl, byte [esp + eax + 0x650]
mov byte [esp + eax + 0x250], cl
inc eax
cmp cl, bl
jne 0x401f80
lea edi, [esp + 0x250]
dec edi
jmp 0x401fa0
mov al, byte [edi + 1]
inc edi
cmp al, bl
jne 0x401fa0
mov eax, dword [str.__verysilent]
mov ecx, dword [0x4092ec]
mov edx, dword [0x4092f0]
mov dword [edi], eax
mov al, byte [0x4092f4]
mov dword [edi + 4], ecx
mov dword [edi + 8], edx
mov byte [edi + 0xc], al
xor eax, eax
mov ecx, 0x11
lea edi, [esp + 0x30]
rep stosd dword es:[edi], eax
lea edx, [esp + 0x14]
push edx
lea eax, [esp + 0x34]
push eax
push ebx
push ebx
xor ecx, ecx
push ebx
mov dword [esp + 0x28], ecx
push ebx
mov dword [esp + 0x30], ecx
mov dword [esp + 0x34], ecx
push ebx
mov dword [esp + 0x3c], ecx
push ebx
lea ecx, [esp + 0x270]
push ecx
push ebx
mov dword [esp + 0x58], 0x44
mov dword [esp + 0x84], 0x101
mov word [esp + 0x88], bx
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
mov edx, dword [esp + 0x14]
push 0xffffffffffffffff
push edx
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov eax, dword [esp + 0x14]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push eax
call esi
mov ecx, dword [esp + 0x18]
push ecx
call esi
lea edx, [esp + 0x1050]
push edx
lea eax, [esp + 0xc54]
push eax
call fcn.004011a0
add esp, 8
lea ecx, [esp + 0x650]
push ecx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov ecx, dword [esp + 0x1454]
pop edi
pop esi
xor ecx, ebp
mov eax, 1
pop ebx
call fcn.00402d89
mov esp, ebp
pop ebp
ret 0x10