Function at 0x1003fdc
Capabilities:
Persist via windows service
Set registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x50
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0x24]
xor edi, edi
push eax
push 0x10016d4
push ebx
mov byte [ebp - 1], 0
mov byte [ebp - 4], 0
mov byte [ebp - 2], 0
mov byte [ebp - 3], 0
mov dword [ebp - 0x1c], edi
mov dword [ebp - 0x18], edi
mov dword [ebp - 0x20], edi
mov dword [ebp - 0x14], edi
mov dword [ebp - 0x2c], edi
mov dword [ebp - 0x28], edi
call fcn.01002bf3
test al, al
je 0x1004030
push dword [ebp - 8]
push ebx
call fcn.01002c42
jmp 0x1004033
mov dword [ebp - 0x24], edi
lea eax, [ebp - 8]
push eax
push edi
push 0x1001638
push ebx
call fcn.01002bf3
test al, al
je 0x1004054
push dword [ebp - 8]
push ebx
call fcn.01002c42
mov byte [ebp - 4], 1
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0xc]
push eax
push 0x1001a4c
push ebx
call fcn.01002bf3
test al, al
je 0x10040af
push dword [ebp - 8]
push ebx
call fcn.01002c42
push dword [ebp - 0xc]
call dword [sym.imp.msvcrt.dll_wcslen]
pop ecx
lea eax, [eax + eax + 2]
push eax
push 0x40
mov dword [ebp - 0x30], eax
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
cmp eax, edi
mov dword [ebp - 0x1c], eax
jne 0x100409f
mov esi, 0x8007000e
jmp 0x1004334
push dword [ebp - 0xc]
push eax
call dword [sym.imp.msvcrt.dll_wcscpy]
pop ecx
pop ecx
mov byte [ebp - 1], 1
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0xc]
push eax
push 0x1001a30
push ebx
call fcn.01002bf3
test al, al
je 0x1004138
push dword [ebp - 8]
push ebx
call fcn.01002c42
mov esi, dword [ebp - 0xc]
mov dword [ebp - 0x10], edi
mov byte [ebp + 0xb], 0
push 0x2c
push esi
call dword [sym.imp.msvcrt.dll_wcschr]
mov edi, eax
test edi, edi
pop ecx
pop ecx
jne 0x10040f0
mov byte [ebp + 0xb], 1
jmp 0x10040f6
and word [edi], 0
inc edi
inc edi
cmp word [esi], 0
je 0x100412a
push esi
push 0x1001a20
call dword [sym.imp.msvcrt.dll__wcsicmp]
test eax, eax
pop ecx
pop ecx
jne 0x1004114
or dword [ebp - 0x10], 1
jmp 0x100412a
push esi
push 0x1001a10
call dword [sym.imp.msvcrt.dll__wcsicmp]
test eax, eax
pop ecx
pop ecx
jne 0x10041a1
or dword [ebp - 0x10], 2
cmp byte [ebp + 0xb], 0
mov esi, edi
je 0x10040d9
mov byte [ebp - 2], 1
xor edi, edi
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0xc]
push eax
push 0x10019e4
push ebx
call fcn.01002bf3
test al, al
je 0x100416d
push dword [ebp - 8]
push ebx
call fcn.01002c42
push edi
push edi
push dword [ebp - 0xc]
call dword [sym.imp.msvcrt.dll_wcstoul]
add esp, 0xc
mov dword [ebp - 0x34], eax
mov byte [ebp - 3], 1
push ebx
call fcn.01002c85
mov esi, eax
cmp esi, edi
jl 0x1004334
cmp byte [ebp - 1], 0
jne 0x10041c8
cmp byte [ebp - 2], 0
jne 0x10041c8
cmp byte [ebp - 4], 0
jne 0x10041be
cmp byte [ebp - 3], 0
jne 0x10041c8
push 0x640
call fcn.01007f71
jmp 0x10041b4
push esi
push 0x10019d4
push 0x5de
call fcn.01007efc
add esp, 0xc
mov esi, 0x80070057
jmp 0x1004334
cmp byte [ebp - 3], 0
je 0x10042cb
lea eax, [ebp - 0x18]
push eax
push closesocket
push dword [ebp - 0x24]
call dword [sym.imp.ADVAPI32.dll_RegConnectRegistryW]
test eax, eax
jne 0x10042bd
cmp byte [ebp - 1], al
mov ebx, dword [sym.imp.ADVAPI32.dll_RegOpenKeyW]
mov edi, dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
jne 0x10041fc
cmp byte [ebp - 2], al
je 0x100428d
lea eax, [ebp - 0x14]
push eax
push 0x1001968
push dword [ebp - 0x18]
call ebx
test eax, eax
jne 0x10042bd
cmp byte [ebp - 1], al
je 0x1004232
push dword [ebp - 0x30]
push dword [ebp - 0x1c]
push 1
push eax
push 0x1001954
push dword [ebp - 0x14]
call edi
test eax, eax
jne 0x10042bd
cmp byte [ebp - 2], 0
je 0x100428d
mov eax, dword [ebp - 0x10]
sub eax, 0
je 0x1004268
dec eax
je 0x1004261
dec eax
je 0x100425a
dec eax
je 0x1004253
mov esi, 0x80004001
jmp 0x1004334
mov esi, 0x1001944
jmp 0x100426d
mov esi, 0x1001938
jmp 0x100426d
mov esi, 0x1001930
jmp 0x100426d
mov esi, 0x1001920
push esi
call dword [sym.imp.msvcrt.dll_wcslen]
pop ecx
lea eax, [eax + eax + 2]
push eax
push esi
push 1
push 0
push 0x1001914
push dword [ebp - 0x14]
call edi
test eax, eax
jne 0x10042bd
cmp byte [ebp - 3], 0
je 0x10042cb
lea eax, [ebp - 0x20]
push eax
push 0x10018b0
push dword [ebp - 0x18]
call ebx
test eax, eax
jne 0x10042bd
push 4
lea eax, [ebp - 0x34]
push eax
push 4
push 0
push 0x1001880
push dword [ebp - 0x20]
call edi
test eax, eax
je 0x10042cb
jle 0x100431c
and eax, 0xffff
or eax, 0x80070000
jmp 0x100431c
cmp byte [ebp - 4], 0
je 0x1004332
push 1
push 0x1001860
push dword [ebp - 0x24]
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
test eax, eax
mov dword [ebp - 0x2c], eax
je 0x100430e
push 0x40
push 0x1001850
push eax
call dword [sym.imp.ADVAPI32.dll_OpenServiceW]
test eax, eax
mov dword [ebp - 0x28], eax
je 0x100430e
lea ecx, [ebp - 0x50]
push ecx
push 6
push eax
call dword [sym.imp.ADVAPI32.dll_ControlService]
test eax, eax
jne 0x1004332
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
test eax, eax
jg 0x1004320
call esi
mov esi, eax
jmp 0x1004334
call esi
mov esi, eax
and esi, 0xffff
or esi, 0x80070000
jmp 0x1004334
xor esi, esi
cmp dword [ebp - 0x1c], 0
mov ebx, dword [sym.imp.KERNEL32.dll_LocalFree]
je 0x1004345
push dword [ebp - 0x1c]
call ebx
cmp dword [ebp - 0x20], 0
mov edi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
je 0x1004356
push dword [ebp - 0x20]
call edi
cmp dword [ebp - 0x14], 0
je 0x1004361
push dword [ebp - 0x14]
call edi
cmp dword [ebp - 0x18], 0
je 0x100436c
push dword [ebp - 0x18]
call edi
cmp dword [ebp - 0x28], 0
mov edi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
je 0x100437d
push dword [ebp - 0x28]
call edi
cmp dword [ebp - 0x2c], 0
je 0x1004388
push dword [ebp - 0x2c]
call edi
test esi, esi
jge 0x10043c0
cmp esi, 0x80070057
je 0x10043be
lea eax, [ebp + 8]
push eax
push esi
call fcn.01008787
test eax, eax
jl 0x10043cc
push dword [ebp + 8]
push 0x10015f4
push 0x579
call fcn.01007efc
add esp, 0xc
push dword [ebp + 8]
call ebx
jmp 0x10043cc
test esi, esi
jne 0x10043cc
push 0x578
call fcn.01007f71
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret 4