Function at 0x42cf60
Capabilities:
Persist via windows service
Query or enumerate registry value
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x220
mov eax, dword [0x4e7018]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
push 0x20a
mov dword [ebp - 0x220], eax
xor edi, edi
lea eax, [ebp - 0x210]
xor esi, esi
push edi
push eax
mov dword [ebp - 0x214], esi
call fcn.0040f160
mov eax, dword [ebp - 0x220]
add esp, 0xc
test ebx, ebx
je 0x42d3aa
test eax, eax
je 0x42d3aa
push eax
push ebx
push str.VNLRemoveEventLogFile:_instructed_to_remove:__S__S
push 0x20
call fcn.004439a0
push ebx
push dword [ebp - 0x220]
lea eax, [ebp - 0x210]
push str.SYSTEMCurrentControlSetServicesEventLog
push str._s_s_s
push 0x105
push eax
call fcn.004159a0
push 1
lea eax, [ebp - 0x210]
push edi
push eax
call fcn.004184d0
add esp, 0x34
test eax, eax
lea eax, [ebp - 0x210]
push eax
jne 0x42d00d
push str.VNLRemoveEventLogFile:_could_not_delete_service_key:__S
push 1
jmp 0x42d014
push str.VNLRemoveEventLogFile:_deleted_key:__S
push 0x10
call fcn.004439a0
add esp, 0xc
call fcn.0041aef0
test eax, eax
jne 0x42d291
push dword [ebp - 0x220]
lea eax, [ebp - 0x210]
push str.SYSTEMCurrentControlSetServicesEventLog
push 0x49a55c
push 0x105
push eax
call fcn.004159a0
add esp, 0x14
lea eax, [ebp - 0x218]
push eax
push 7
push 0
lea eax, [ebp - 0x210]
push eax
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov dword [ebp - 0x21c], eax
test eax, eax
je 0x42d0b0
call dword [sym.imp.KERNEL32.dll_GetLastError]
lea ecx, [ebp - 0x210]
push ecx
push eax
push dword [ebp - 0x21c]
push dword [ebp - 0x220]
push str.VNLRemoveEventLogFile:_could_not_open__S_key:_0x_08x_0x_08x__S
push 1
call fcn.004439a0
add esp, 0x18
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00401bf1
mov esp, ebp
pop ebp
ret
push dword [ebp - 0x220]
push str.VNLRemoveEventLogFile:_opened__S_key
push 0x10
call fcn.004439a0
add esp, 0xc
lea eax, [ebp - 0x214]
push eax
push 0
push 0
push 0
push str.Sources
push dword [ebp - 0x218]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov dword [ebp - 0x21c], eax
test eax, eax
je 0x42d12c
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, eax
mov eax, dword [ebp - 0x21c]
cmp eax, 0xea
jne 0x42d119
push dword [ebp - 0x214]
push str.VNLRemoveEventLogFile:_got_length_of_sources_key:__d
push 0x10
call fcn.004439a0
add esp, 0xc
jmp 0x42d140
push ecx
push eax
push str.VNLRemoveEventLogFile:_could_not_get_length_of_sources_key:_0x_08x_0x_08x
push 1
call fcn.004439a0
add esp, 0x10
jmp 0x42d140
push str.VNLRemoveEventLogFile:_got_length_of_sources_key
push 0x10
call fcn.004439a0
add esp, 8
nop dword [eax + eax]
test esi, esi
je 0x42d14d
push esi
call fcn.0047b1a0
add esp, 4
mov eax, dword [ebp - 0x214]
push eax
mov dword [ebp - 0x21c], eax
call fcn.0047c3b0
mov esi, eax
add esp, 4
test esi, esi
je 0x42d37c
push dword [ebp - 0x21c]
push 0
push esi
call fcn.0040f160
add esp, 0xc
lea eax, [ebp - 0x214]
push eax
push esi
push 0
push 0
push str.Sources
push dword [ebp - 0x218]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov dword [ebp - 0x21c], eax
test eax, eax
je 0x42d223
cmp eax, 0xea
jne 0x42d1cc
push dword [ebp - 0x214]
push str.VNLRemoveEventLogFile:_got_length_of_sources_key:__d
push 0x10
call fcn.004439a0
inc edi
add esp, 0xc
cmp edi, 5
jl 0x42d140
jmp 0x42d1e8
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [ebp - 0x21c]
push str.VNLRemoveEventLogFile:_could_not_get_length_of_sources_key:_0x_08x_0x_08x
push 1
call fcn.004439a0
add esp, 0x10
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.key_read_had_issues:_0x_08x
push 1
call fcn.004439a0
push esi
call fcn.0047b1a0
add esp, 0x10
push dword [ebp - 0x218]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
pop esi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00401bf1
mov esp, ebp
pop ebp
ret
push str.VNLRemoveEventLogFile:_read_sources_key
push 0x10
call fcn.004439a0
add esp, 8
mov edi, esi
cmp word [esi], 0
je 0x42d2b6
nop word [eax + eax]
push ebx
push edi
call fcn.0040ca9a
add esp, 8
test eax, eax
je 0x42d2b6
mov ecx, edi
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x42d253
sub ecx, edx
sar ecx, 1
lea edi, [edi + ecx*2]
add edi, 2
cmp word [edi], ax
jne 0x42d240
push str.VNLRemoveEventLogFile:_service_not_found_in_sources_key
push 4
call fcn.004439a0
add esp, 8
push esi
call fcn.0047b1a0
add esp, 4
push dword [ebp - 0x218]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push str.VNLRemoveEventLogFile:_returning
push 0x10
call fcn.004439a0
add esp, 8
mov eax, 1
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00401bf1
mov esp, ebp
pop ebp
ret
cmp word [edi], 0
je 0x42d26d
mov ecx, edi
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x42d2c1
mov eax, dword [ebp - 0x214]
sub ecx, edx
sar ecx, 1
inc ecx
lea ecx, [edi + ecx*2]
sub eax, ecx
add eax, esi
push eax
push ecx
push edi
call fcn.0048ddd0
add esp, 0xc
lea ecx, [ebx + 2]
nop dword [eax]
mov ax, word [ebx]
add ebx, 2
test ax, ax
jne 0x42d2f0
sub ebx, ecx
mov ecx, 0xfffffffe
sar ebx, 1
lea eax, [ebx + ebx]
sub ecx, eax
mov eax, dword [ebp - 0x214]
add eax, ecx
push eax
push esi
push 7
push 0
push str.Sources
push dword [ebp - 0x218]
mov dword [ebp - 0x214], eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov edi, eax
test edi, edi
je 0x42d370
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push edi
push str.VNLRemoveEventLogFile:_key_set_had_issues:_0x_08x_0x_08x
push 1
call fcn.004439a0
push esi
call fcn.0047b1a0
add esp, 0x14
push dword [ebp - 0x218]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
pop esi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00401bf1
mov esp, ebp
pop ebp
ret
push str.VNLRemoveEventLogFile:_sources_key_written
push 0x10
jmp 0x42d274
push dword [ebp - 0x218]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push str.VNLRemoveEventLogFile:_memory_allocation_failed
push 1
call fcn.004439a0
add esp, 8
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00401bf1
mov esp, ebp
pop ebp
ret
push eax
push ebx
push str.VNLRemoveEventLogFile:_got_invalid_parameters:_0x_08x_0x_08x
push 1
call fcn.004439a0
mov ecx, dword [ebp - 4]
add esp, 0x10
xor ecx, ebp
xor eax, eax
pop edi
pop esi
pop ebx
call fcn.00401bf1
mov esp, ebp
pop ebp
ret