Function at 0x402400
Capabilities:
Delete directory
Delete file
Persist via run registry key
Query or enumerate registry value

Disassembly:
sub esp, 0x320
or ecx, 0xffffffff
xor eax, eax
push ebx
mov ebx, dword [esp + 0x328]
push ebp
push esi
push edi
mov edi, ebx
xor ebp, ebp
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp ecx, 1
jae 0x40242f
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x320
ret
mov edx, dword [str._Common_Desktop_]
mov ecx, 0x41
xor eax, eax
lea edi, [esp + 0x128]
rep stosd dword es:[edi], eax
mov edi, edx
or ecx, 0xffffffff
mov byte [esp + 0x24], al
mov esi, dword [sym.imp.MSVCRT.dll__strnicmp]
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov dword [esp + 0x1c], ebx
push ecx
push edx
push ebx
call esi
add esp, 0xc
test eax, eax
jne 0x40249b
mov edx, dword [str._Common_Desktop_]
mov edi, edx
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
add ecx, 0xfffffffd
inc edx
push ecx
lea eax, [esp + 0x12c]
push edx
push eax
call dword [sym.imp.MSVCRT.dll_strncpy]
add esp, 0xc
mov ebp, 2
jmp 0x40264e
mov edx, dword [str._Common_Programs_]
or ecx, 0xffffffff
mov edi, edx
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push edx
push ebx
call esi
add esp, 0xc
test eax, eax
jne 0x4024e9
mov edx, dword [str._Common_Programs_]
or ecx, 0xffffffff
mov edi, edx
repne scasb al, byte es:[edi]
not ecx
add ecx, 0xfffffffd
inc edx
push ecx
lea ecx, [esp + 0x12c]
push edx
push ecx
call dword [sym.imp.MSVCRT.dll_strncpy]
add esp, 0xc
mov ebp, 2
jmp 0x40264e
mov edx, dword [str._Common_Start_Menu_]
or ecx, 0xffffffff
mov edi, edx
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push edx
push ebx
call esi
add esp, 0xc
test eax, eax
jne 0x402537
mov edx, dword [str._Common_Start_Menu_]
or ecx, 0xffffffff
mov edi, edx
repne scasb al, byte es:[edi]
not ecx
add ecx, 0xfffffffd
inc edx
push ecx
push edx
lea edx, [esp + 0x130]
push edx
call dword [sym.imp.MSVCRT.dll_strncpy]
add esp, 0xc
mov ebp, 2
jmp 0x40264e
mov edx, dword [str._Common_Startup_]
or ecx, 0xffffffff
mov edi, edx
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push edx
push ebx
call esi
add esp, 0xc
test eax, eax
jne 0x402560
mov edx, dword [str._Common_Startup_]
jmp 0x40246f
mov edx, dword [str._Desktop_]
or ecx, 0xffffffff
mov edi, edx
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push edx
push ebx
call esi
add esp, 0xc
test eax, eax
jne 0x402589
mov edx, dword [str._Desktop_]
jmp 0x402627
mov edx, dword [str._Programs_]
or ecx, 0xffffffff
mov edi, edx
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push edx
push ebx
call esi
add esp, 0xc
test eax, eax
jne 0x4025c6
mov edx, dword [str._Programs_]
or ecx, 0xffffffff
mov edi, edx
repne scasb al, byte es:[edi]
not ecx
add ecx, 0xfffffffd
inc edx
push ecx
push edx
lea edx, [esp + 0x130]
push edx
jmp 0x402640
mov edx, dword [str._Start_Menu_]
or ecx, 0xffffffff
mov edi, edx
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push edx
push ebx
call esi
add esp, 0xc
test eax, eax
jne 0x402603
mov edx, dword [str._Start_Menu_]
or ecx, 0xffffffff
mov edi, edx
repne scasb al, byte es:[edi]
not ecx
add ecx, 0xfffffffd
inc edx
push ecx
lea eax, [esp + 0x12c]
push edx
push eax
jmp 0x402640
mov edx, dword [str._Startup_]
or ecx, 0xffffffff
mov edi, edx
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push edx
push ebx
call esi
add esp, 0xc
test eax, eax
jne 0x40264e
mov edx, dword [str._Startup_]
mov edi, edx
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
add ecx, 0xfffffffd
inc edx
push ecx
lea ecx, [esp + 0x12c]
push edx
push ecx
call dword [sym.imp.MSVCRT.dll_strncpy]
add esp, 0xc
mov ebp, 1
xor esi, esi
mov dword [esp + 0x18], esi
cmp ebp, 1
je 0x402662
cmp ebp, 2
jne 0x40281d
lea edi, [esp + 0x128]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp ebp, 1
lea edx, [ecx + ebx + 2]
mov dword [esp + 0x1c], edx
jne 0x402728
test esi, esi
mov ebp, 2
mov dword [esp + 0x14], 0x80000001
jle 0x402735
mov edi, str.Common
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
dec ecx
lea eax, [esp + 0x128]
push ecx
push str.Common
push eax
call dword [sym.imp.MSVCRT.dll__strnicmp]
add esp, 0xc
test eax, eax
jne 0x402735
mov edi, str.Common
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
dec ecx
lea edx, [esp + 0x22c]
lea edi, [esp + ecx + 0x128]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x128]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [esp + 0x22c]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov esi, dword [esp + 0x18]
jmp 0x402735
mov ebp, 1
mov dword [esp + 0x14], 0x80000002
mov edx, dword [esp + 0x14]
lea ecx, [esp + 0x14]
push ecx
push 1
push 0
push str.SOFTWAREMicrosoftWindowsCurrentVersionExplorerShell_Folders
push edx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x4027b9
mov ecx, 0x41
lea edi, [esp + 0x24]
rep stosd dword es:[edi], eax
lea eax, [esp + 0x10]
lea ecx, [esp + 0x24]
push eax
lea edx, [esp + 0x24]
push ecx
mov ecx, dword [esp + 0x1c]
push edx
lea eax, [esp + 0x134]
push 0
push eax
push ecx
mov dword [esp + 0x28], 0x104
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov edx, dword [esp + 0x14]
mov esi, eax
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test esi, esi
jne 0x4027a9
cmp dword [esp + 0x20], 1
jne 0x4027a9
mov eax, dword [esp + 0x10]
test eax, eax
ja 0x4027d1
mov eax, dword [esp + 0x18]
test eax, eax
jg 0x40286a
mov esi, eax
jmp 0x4027c1
test esi, esi
jg 0x40286a
inc esi
cmp esi, 2
mov dword [esp + 0x18], esi
jl 0x402654
jmp 0x40281d
lea edi, [esp + 0x24]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov dword [esp + 0x10], ecx
mov al, byte [esp + ecx + 0x23]
cmp al, 0x5c
je 0x40281d
cmp al, 0x2f
je 0x40281d
mov edi, 0x40a1e0
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x24]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, dword [esp + 0x1c]
mov al, byte [edi]
cmp al, 0x5c
je 0x40282b
cmp al, 0x2f
jne 0x40282c
inc edi
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0x24]
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [esp + 0x24]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp ecx, 5
mov dword [esp + 0x10], ecx
jae 0x402877
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x320
ret
lea eax, [ecx - 1]
test eax, eax
jl 0x4028a6
mov dl, byte [esp + eax + 0x24]
cmp dl, 0x5c
je 0x402891
cmp dl, 0x2f
je 0x402891
dec eax
jns 0x40287e
jmp 0x4028a6
mov cl, byte [esp + eax + 0x24]
lea eax, [esp + eax + 0x24]
test eax, eax
mov byte [eax], 0
je 0x4028a2
mov byte [eax], cl
mov ecx, dword [esp + 0x10]
lea eax, [esp + ecx + 0x20]
push str..LNK
push eax
call dword [sym.imp.MSVCRT.dll__stricmp]
add esp, 8
test eax, eax
je 0x4028eb
mov edi, str..LNK
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x24]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea eax, [esp + 0x24]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
lea edi, [esp + 0x24]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
dec ecx
js 0x402939
mov al, byte [esp + ecx + 0x24]
cmp al, 0x5c
je 0x402926
cmp al, 0x2f
je 0x402926
dec ecx
jns 0x402907
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x320
ret
mov byte [esp + ecx + 0x24], 0
lea ecx, [esp + 0x24]
push ecx
call dword [sym.imp.MSVCRT.dll__rmdir]
add esp, 4
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x320
ret