Function at 0x40c612
Capabilities:
Delete registry key
Persist via default file association registry key
Query or enumerate registry value
Set registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x54ae9a
mov eax, dword fs:[0]
push eax
sub esp, 0x4c4
mov eax, dword [0x59de90]
xor eax, ebp
mov dword [ebp - 0x10], eax
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 4], 2
lea ecx, [ebp + 8]
call fcn.0040cf8b
movzx eax, al
test eax, eax
jne 0x40c675
push 0
lea ecx, [ebp + 8]
call fcn.00404a55
movsx eax, byte [eax]
cmp eax, 0x2e
jne 0x40c675
lea ecx, [ebp + 0x40]
call fcn.0040cf8b
movzx eax, al
test eax, eax
je 0x40c6ab
mov byte [ebp - 0x481], 0
mov byte [ebp - 4], 1
lea ecx, [ebp + 8]
call fcn.00401be7
mov byte [ebp - 4], 0
lea ecx, [ebp + 0x24]
call fcn.00401be7
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0x40]
call fcn.00401be7
mov al, byte [ebp - 0x481]
jmp 0x40ced8
mov byte [ebp - 0xa4], 0
push 7
pop ecx
xor eax, eax
lea edi, [ebp - 0xa3]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov dword [ebp - 0x84], 0x20
push 0
lea eax, [ebp - 0x2f4]
push eax
push 0
push 0xf003f
push 0
push 0
push 0
lea ecx, [ebp + 8]
call fcn.00401c04
push eax
push SysReAllocStringLen
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
test eax, eax
jne 0x40c7ec
lea eax, [ebp - 0x84]
push eax
lea eax, [ebp - 0xa4]
push eax
push 0
push 0
push 0
push dword [ebp - 0x2f4]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
lea ecx, [ebp + 0x24]
call fcn.00401c04
mov dword [ebp - 0x490], eax
lea eax, [ebp - 0xa4]
mov dword [ebp - 0x494], eax
mov eax, dword [ebp - 0x494]
mov al, byte [eax]
mov byte [ebp - 0x495], al
mov ecx, dword [ebp - 0x490]
cmp al, byte [ecx]
jne 0x40c793
cmp byte [ebp - 0x495], 0
je 0x40c78a
mov eax, dword [ebp - 0x494]
mov al, byte [eax + 1]
mov byte [ebp - 0x496], al
mov ecx, dword [ebp - 0x490]
cmp al, byte [ecx + 1]
jne 0x40c793
add dword [ebp - 0x494], 2
add dword [ebp - 0x490], 2
cmp byte [ebp - 0x496], 0
jne 0x40c738
and dword [ebp - 0x49c], 0
jmp 0x40c79e
sbb eax, eax
sbb eax, 0xffffffff
mov dword [ebp - 0x49c], eax
mov eax, dword [ebp - 0x49c]
mov dword [ebp - 0x4a0], eax
cmp dword [ebp - 0x4a0], 0
je 0x40c7de
lea ecx, [ebp + 0x24]
call fcn.00417fd7
inc eax
push eax
lea ecx, [ebp + 0x24]
call fcn.00401c04
push eax
push 1
push 0
push 0
push dword [ebp - 0x2f4]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov eax, dword [ebp + 0x5c]
mov byte [eax], 1
push dword [ebp - 0x2f4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
jmp 0x40c822
mov byte [ebp - 0x482], 0
mov byte [ebp - 4], 1
lea ecx, [ebp + 8]
call fcn.00401be7
mov byte [ebp - 4], 0
lea ecx, [ebp + 0x24]
call fcn.00401be7
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0x40]
call fcn.00401be7
mov al, byte [ebp - 0x482]
jmp 0x40ced8
push 0
call fcn.0040b550
pop ecx
push eax
call fcn.00525f68
pop ecx
call fcn.00525f7a
add eax, 0x32
mov dword [ebp - 0x2f8], eax
mov eax, dword [ebp - 0x2f8]
and eax, 0x80000001
jns 0x40c851
dec eax
or eax, 0xfffffffe
inc eax
test eax, eax
jne 0x40c866
mov eax, dword [ebp - 0x2f8]
add eax, 0xf0
mov dword [ebp - 0x2f8], eax
lea ecx, [ebp - 0x334]
call fcn.00401b3b
mov byte [ebp - 4], 3
push 0x577d20
lea ecx, [ebp - 0x334]
call fcn.00401547
push 0x5d
lea ecx, [ebp - 0x334]
call fcn.00404a3d
push 0x5d
lea ecx, [ebp - 0x334]
call fcn.00404a3d
push 0x45
lea ecx, [ebp - 0x334]
call fcn.00404a3d
push 0x41
lea ecx, [ebp - 0x334]
call fcn.00404a3d
push 0x4d
lea ecx, [ebp - 0x334]
call fcn.00404a3d
push 0x49
lea ecx, [ebp - 0x334]
call fcn.00404a3d
push 0x39
lea ecx, [ebp - 0x334]
call fcn.00404a3d
push 0x35
lea ecx, [ebp - 0x334]
call fcn.00404a3d
push 0x4d
lea ecx, [ebp - 0x334]
call fcn.00404a3d
push 0x3d
lea ecx, [ebp - 0x334]
call fcn.00404a3d
push 0x4d
lea ecx, [ebp - 0x334]
call fcn.00404a3d
push 0x39
lea ecx, [ebp - 0x334]
call fcn.00404a3d
push 0x39
lea ecx, [ebp - 0x334]
call fcn.00404a3d
push 0x5d
lea ecx, [ebp - 0x334]
call fcn.00404a3d
push 0x45
lea ecx, [ebp - 0x334]
call fcn.00404a3d
lea ecx, [ebp - 0x334]
call fcn.00401c04
push eax
push 0x577d24
call fcn.00525eab
pop ecx
pop ecx
push 0x10
lea eax, [ebp - 0x318]
push eax
push dword [ebp - 0x2f8]
call fcn.0053e158
add esp, 0xc
push 0x39
lea ecx, [ebp - 0x334]
call fcn.00404a3d
lea ecx, [ebp - 0x334]
call fcn.00401c04
push eax
lea eax, [ebp - 0x318]
push eax
push 0x577d28
call fcn.00525eab
add esp, 0xc
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x334]
call fcn.00401be7
mov byte [ebp - 0x2ec], 0
push 0x1ff
push 0
lea eax, [ebp - 0x2eb]
push eax
call fcn.00527ae0
add esp, 0xc
mov dword [ebp - 0x2f0], 0x200
push str.ShellOpenCommand
lea eax, [ebp + 0x24]
push eax
lea eax, [ebp - 0x80]
push eax
call fcn.00404cc4
add esp, 0xc
mov byte [ebp - 4], 4
push 0
lea eax, [ebp - 0xb0]
push eax
push 0
push 0xf003f
push 0
push 0
push 0
lea ecx, [ebp - 0x80]
call fcn.00401c04
push eax
push SysReAllocStringLen
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
test eax, eax
jne 0x40cb6a
lea eax, [ebp - 0x2f0]
push eax
lea eax, [ebp - 0x2ec]
push eax
push 0
push 0
push 0
push dword [ebp - 0xb0]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
lea ecx, [ebp + 0x40]
call fcn.00401c04
push eax
push str.__s_____1_
lea eax, [ebp - 0x43c]
push eax
call fcn.00525032
add esp, 0xc
lea eax, [ebp - 0x43c]
mov dword [ebp - 0x4a4], eax
lea eax, [ebp - 0x2ec]
mov dword [ebp - 0x4a8], eax
mov eax, dword [ebp - 0x4a8]
mov al, byte [eax]
mov byte [ebp - 0x4a9], al
mov ecx, dword [ebp - 0x4a4]
cmp al, byte [ecx]
jne 0x40cad5
cmp byte [ebp - 0x4a9], 0
je 0x40cacc
mov eax, dword [ebp - 0x4a8]
mov al, byte [eax + 1]
mov byte [ebp - 0x4aa], al
mov ecx, dword [ebp - 0x4a4]
cmp al, byte [ecx + 1]
jne 0x40cad5
add dword [ebp - 0x4a8], 2
add dword [ebp - 0x4a4], 2
cmp byte [ebp - 0x4aa], 0
jne 0x40ca7a
and dword [ebp - 0x4b0], 0
jmp 0x40cae0
sbb eax, eax
sbb eax, 0xffffffff
mov dword [ebp - 0x4b0], eax
mov eax, dword [ebp - 0x4b0]
mov dword [ebp - 0x4b4], eax
cmp dword [ebp - 0x4b4], 0
je 0x40cb5c
lea eax, [ebp - 0x43c]
mov dword [ebp - 0x4b8], eax
mov eax, dword [ebp - 0x4b8]
inc eax
mov dword [ebp - 0x4bc], eax
mov eax, dword [ebp - 0x4b8]
mov al, byte [eax]
mov byte [ebp - 0x4bd], al
inc dword [ebp - 0x4b8]
cmp byte [ebp - 0x4bd], 0
jne 0x40cb0e
mov eax, dword [ebp - 0x4b8]
sub eax, dword [ebp - 0x4bc]
mov dword [ebp - 0x4c4], eax
push dword [ebp - 0x4c4]
lea eax, [ebp - 0x43c]
push eax
push 1
push 0
push 0
push dword [ebp - 0xb0]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
push dword [ebp - 0xb0]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
jmp 0x40cbac
mov byte [ebp - 0x483], 0
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x80]
call fcn.00401be7
mov byte [ebp - 4], 1
lea ecx, [ebp + 8]
call fcn.00401be7
mov byte [ebp - 4], 0
lea ecx, [ebp + 0x24]
call fcn.00401be7
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0x40]
call fcn.00401be7
mov al, byte [ebp - 0x483]
jmp 0x40ced8
push str.OpenWithProgids
lea eax, [ebp + 8]
push eax
lea eax, [ebp - 0xcc]
push eax
call fcn.00404cc4
add esp, 0xc
mov byte [ebp - 4], 5
push 0
lea eax, [ebp - 0xec]
push eax
push 0
push 0xf003f
push 0
push 0
push 0
lea ecx, [ebp - 0xcc]
call fcn.00401c04
push eax
push SysReAllocStringLen
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
test eax, eax
jne 0x40cc18
push 0
push 0
push 1
push 0
lea ecx, [ebp + 0x24]
call fcn.00401c04
push eax
push dword [ebp - 0xec]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
jmp 0x40cc69
mov byte [ebp - 0x484], 0
mov byte [ebp - 4], 4
lea ecx, [ebp - 0xcc]
call fcn.00401be7
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x80]
call fcn.00401be7
mov byte [ebp - 4], 1
lea ecx, [ebp + 8]
call fcn.00401be7
mov byte [ebp - 4], 0
lea ecx, [ebp + 0x24]
call fcn.00401be7
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0x40]
call fcn.00401be7
mov al, byte [ebp - 0x484]
jmp 0x40ced8
lea eax, [ebp + 8]
push eax
push str.SoftwareMicrosoftWindowsCurrentVersionExplorerFileExts_
lea eax, [ebp - 0xe8]
push eax
call fcn.0040d38a
add esp, 0xc
mov byte [ebp - 4], 6
mov byte [ebp - 0xa5], 1
lea eax, [ebp - 0xac]
push eax
push 0xf003f
push 0
lea ecx, [ebp - 0xe8]
call fcn.00401c04
push eax
push SysReAllocStringLen
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40ce1b
and dword [ebp - 0x480], 0
mov byte [ebp - 0x47c], 0
push 0x3f
push 0
lea eax, [ebp - 0x47b]
push eax
call fcn.00527ae0
add esp, 0xc
push str.UserChoice_
lea eax, [ebp - 0xe8]
push eax
lea eax, [ebp - 0x2c]
push eax
call fcn.00404cc4
add esp, 0xc
mov dword [ebp - 0x4c8], eax
mov ecx, dword [ebp - 0x4c8]
call fcn.00401c04
push eax
push SysReAllocStringLen
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
neg eax
sbb eax, eax
neg eax
mov byte [ebp - 0x485], al
lea ecx, [ebp - 0x2c]
call fcn.00401be7
movzx eax, byte [ebp - 0x485]
test eax, eax
je 0x40cd35
mov byte [ebp - 0xa5], 0
push str.OpenWithList_
lea eax, [ebp - 0xe8]
push eax
lea eax, [ebp - 0x48]
push eax
call fcn.00404cc4
add esp, 0xc
mov dword [ebp - 0x4cc], eax
mov ecx, dword [ebp - 0x4cc]
call fcn.00401c04
push eax
push SysReAllocStringLen
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
neg eax
sbb eax, eax
neg eax
mov byte [ebp - 0x486], al
lea ecx, [ebp - 0x48]
call fcn.00401be7
movzx eax, byte [ebp - 0x486]
test eax, eax
je 0x40cd90
mov byte [ebp - 0xa5], 0
push str.OpenWithProgids_
lea eax, [ebp - 0xe8]
push eax
lea eax, [ebp - 0x64]
push eax
call fcn.00404cc4
add esp, 0xc
mov dword [ebp - 0x4d0], eax
mov ecx, dword [ebp - 0x4d0]
call fcn.00401c04
push eax
push SysReAllocStringLen
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
neg eax
sbb eax, eax
neg eax
mov byte [ebp - 0x487], al
lea ecx, [ebp - 0x64]
call fcn.00401be7
movzx eax, byte [ebp - 0x487]
test eax, eax
je 0x40cdeb
mov byte [ebp - 0xa5], 0
lea ecx, [ebp - 0xe8]
call fcn.00401c04
push eax
push SysReAllocStringLen
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
test eax, eax
je 0x40ce0d
mov byte [ebp - 0xa5], 0
push dword [ebp - 0xac]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
jmp 0x40ce78
mov byte [ebp - 0x488], 1
mov byte [ebp - 4], 5
lea ecx, [ebp - 0xe8]
call fcn.00401be7
mov byte [ebp - 4], 4
lea ecx, [ebp - 0xcc]
call fcn.00401be7
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x80]
call fcn.00401be7
mov byte [ebp - 4], 1
lea ecx, [ebp + 8]
call fcn.00401be7
mov byte [ebp - 4], 0
lea ecx, [ebp + 0x24]
call fcn.00401be7
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0x40]
call fcn.00401be7
mov al, byte [ebp - 0x488]
jmp 0x40ced8
mov al, byte [ebp - 0xa5]
mov byte [ebp - 0x489], al
mov byte [ebp - 4], 5
lea ecx, [ebp - 0xe8]
call fcn.00401be7
mov byte [ebp - 4], 4
lea ecx, [ebp - 0xcc]
call fcn.00401be7
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x80]
call fcn.00401be7
mov byte [ebp - 4], 1
lea ecx, [ebp + 8]
call fcn.00401be7
mov byte [ebp - 4], 0
lea ecx, [ebp + 0x24]
call fcn.00401be7
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0x40]
call fcn.00401be7
mov al, byte [ebp - 0x489]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00524b49
leave
ret