Function at 0x427aa0
Capabilities:
Modify service
Query service configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x170
mov eax, dword [0x4c143c]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
or dword [ebp - 0x14c], 0xffffffff
push ebx
mov ebx, dword [ebp + 8]
push esi
mov esi, dword [ebp + 0x14]
push edi
mov edi, ecx
mov dword [ebp - 0x13c], eax
mov eax, dword [ebp + 0x10]
xor ecx, ecx
push 0x18
mov dword [ebp - 0x144], edi
mov dword [ebp - 0x154], ebx
mov dword [ebp - 0x138], eax
mov dword [ebp - 0x164], 0x10
mov dword [ebp - 0x134], ecx
mov dword [ebp - 0x12c], ecx
mov dword [ebp - 0x148], ecx
mov dword [ebp - 0x140], ecx
mov dword [ebp - 0x150], ecx
mov dword [ebp - 0x130], ecx
call fcn.00458edd
pop ecx
mov dword [ebp - 0x160], eax
lea eax, [ebp - 0x158]
push eax
push 0
push 0
push 2
push ebx
call dword [sym.imp.ADVAPI32.dll_QueryServiceConfig2A]
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
call ebx
cmp eax, 0x7a
jne 0x4284d4
push dword [ebp - 0x158]
call fcn.00458edd
pop ecx
lea ecx, [ebp - 0x158]
mov dword [ebp - 0x130], eax
push ecx
push dword [ebp - 0x158]
push eax
push 2
push dword [ebp - 0x154]
call dword [sym.imp.ADVAPI32.dll_QueryServiceConfig2A]
mov edx, dword [ebp - 0x130]
mov dword [ebp - 0x168], 1
mov ecx, dword [edx + 0xc]
and dword [edx + 8], 0
mov dword [ebp - 0x15c], ecx
test ecx, ecx
je 0x427bbc
mov eax, dword [edx + 0x10]
mov edi, dword [ebp - 0x12c]
cmp dword [eax], 2
lea eax, [eax + 8]
cmove edi, dword [ebp - 0x168]
sub ecx, 1
jne 0x427b9e
mov dword [ebp - 0x12c], edi
mov edi, dword [ebp - 0x144]
push esi
push str.FAILURES
mov dword [edx + 0xc], 3
call fcn.004660fd
pop ecx
pop ecx
test eax, eax
jne 0x427d18
mov eax, dword [ebp - 0x130]
mov ecx, dword [ebp - 0x160]
mov dword [eax + 0x10], ecx
xor ecx, ecx
inc ecx
mov esi, ecx
cmp dword [eax + 0xc], ecx
jb 0x427f86
push dword [ebp - 0x13c]
mov ecx, edi
push esi
call fcn.0041c836
mov dword [ebp - 0x144], eax
test eax, eax
je 0x427cec
push eax
call fcn.00467690
pop ecx
test eax, eax
jne 0x427c2c
mov ecx, dword [ebp - 0x130]
mov eax, dword [ecx + 0x10]
and dword [eax + esi*8 - 8], 0
jmp 0x427c7d
push dword [ebp - 0x144]
call fcn.00467690
xor edx, edx
inc edx
pop ecx
cmp eax, edx
je 0x427c70
push dword [ebp - 0x144]
call fcn.00467690
pop ecx
push 2
pop edx
cmp eax, edx
jne 0x427c5d
xor eax, eax
inc eax
mov dword [ebp - 0x12c], eax
jmp 0x427c70
push dword [ebp - 0x144]
call fcn.00467690
pop ecx
push 3
pop edx
cmp eax, edx
jne 0x427cb4
mov ecx, dword [ebp - 0x130]
mov eax, dword [ecx + 0x10]
mov dword [eax + esi*8 - 8], edx
cmp dword [ebp - 0x15c], 0
jne 0x427c91
mov eax, dword [ecx + 0x10]
mov dword [eax + esi*8 - 4], 0xea60
push dword [ebp - 0x144]
call fcn.0045f1d9
mov edx, dword [ebp - 0x130]
inc esi
pop ecx
cmp esi, dword [edx + 0xc]
jbe 0x427bf5
mov esi, edx
jmp 0x427f88
mov ecx, dword [edi + 0xc]
test ecx, ecx
je 0x427cd8
cmp dword [0x4c12e0], 0
je 0x427cd8
push dword [ebp - 0x138]
mov eax, dword [ecx]
push str.Invalid_recovery_type_specified_for_service__s
push ecx
call dword [eax + 0x14]
add esp, 0xc
push 0x57
pop ebx
push dword [ebp - 0x144]
call fcn.0045f1d9
pop ecx
jmp 0x42825c
mov ecx, dword [edi + 0xc]
test ecx, ecx
je 0x427d10
cmp dword [0x4c12e0], 0
je 0x427d10
push dword [ebp - 0x138]
push str.Invalid_number_of_recovery_specification_for_the_service__s
mov eax, dword [ecx]
push ecx
call dword [eax + 0x14]
add esp, 0xc
push 0x57
pop ebx
jmp 0x42825c
push esi
push str.PROGRAMSTORUN
call fcn.004660fd
pop ecx
pop ecx
test eax, eax
jne 0x427ebc
push 0x104
push eax
lea eax, [ebp - 0x108]
push eax
call fcn.0045b1d0
add esp, 0xc
xor eax, eax
inc eax
mov ecx, edi
mov esi, 0x103
push dword [ebp - 0x13c]
push eax
call fcn.0041c836
push dword [ebp - 0x13c]
mov ecx, edi
mov dword [ebp - 0x148], eax
push 2
call fcn.0041c836
push dword [ebp - 0x13c]
mov ecx, edi
mov dword [ebp - 0x140], eax
push 3
call fcn.0041c836
mov dword [ebp - 0x150], eax
mov eax, dword [ebp - 0x148]
test eax, eax
je 0x427db6
push esi
push eax
lea eax, [ebp - 0x108]
push 0x104
push eax
call fcn.00467c09
mov eax, dword [ebp - 0x148]
push eax
call fcn.00461890
add esp, 0x14
sub esi, eax
cmp dword [ebp - 0x140], 0
je 0x427e0f
cmp esi, 2
jle 0x427e0f
push esi
push 0x49b2e8
lea eax, [ebp - 0x108]
push 0x104
push eax
call fcn.00467c09
push 0x49b2e8
call fcn.00461890
sub esi, eax
lea eax, [ebp - 0x108]
push esi
push dword [ebp - 0x140]
push 0x104
push eax
call fcn.00467c09
push dword [ebp - 0x140]
call fcn.00461890
add esp, 0x28
sub esi, eax
mov eax, dword [ebp - 0x150]
test eax, eax
je 0x427e78
push eax
push 0x49b2ec
call fcn.004660fd
pop ecx
pop ecx
test eax, eax
jne 0x427e78
cmp esi, 2
jle 0x427e78
push esi
push 0x49b2e8
lea eax, [ebp - 0x108]
push 0x104
push eax
call fcn.00467c09
push 0x49b2e8
call fcn.00461890
sub esi, eax
lea eax, [ebp - 0x108]
push esi
push str._fail_1_
push 0x104
push eax
call fcn.00467c09
push str._fail_1_
call fcn.00461890
add esp, 0x28
sub esi, eax
test esi, esi
jns 0x427ea8
mov ecx, dword [edi + 0xc]
test ecx, ecx
je 0x427ea0
cmp dword [0x4c12e0], 0
je 0x427ea0
push dword [ebp - 0x138]
mov eax, dword [ecx]
push str.Buffer_over_flow__while_setting_service_parameters_for_service__s_
push ecx
call dword [eax + 0x14]
add esp, 0xc
push 0x6f
pop ebx
jmp 0x4280f0
mov esi, dword [ebp - 0x130]
lea eax, [ebp - 0x108]
mov dword [esi + 8], eax
jmp 0x427f88
push esi
push str.RESETFAILCOUNTAFTERDAYS
call fcn.004660fd
pop ecx
pop ecx
test eax, eax
jne 0x427f05
push dword [ebp - 0x13c]
inc eax
mov ecx, edi
push eax
call fcn.0041c836
mov esi, eax
push esi
call fcn.00467690
mov edx, dword [ebp - 0x130]
imul eax, eax, 0x15180
push esi
mov dword [edx], eax
call fcn.0045f1d9
pop ecx
mov esi, dword [ebp - 0x130]
pop ecx
jmp 0x427f88
push esi
push str.RESTARTSERVICEAFTERMINUTES
call fcn.004660fd
pop ecx
pop ecx
test eax, eax
jne 0x42815a
push dword [ebp - 0x13c]
inc eax
mov ecx, edi
push eax
call fcn.0041c836
mov ecx, dword [ebp - 0x130]
xor esi, esi
mov dword [ebp - 0x13c], eax
cmp dword [ecx + 0xc], esi
jbe 0x427f7b
mov edi, eax
mov eax, dword [ecx + 0x10]
test eax, eax
je 0x427f69
xor edx, edx
inc edx
cmp dword [eax + esi*8], edx
jne 0x427f69
push edi
call fcn.00467690
mov edx, dword [ebp - 0x130]
pop ecx
imul ecx, eax, 0xea60
mov eax, dword [edx + 0x10]
mov dword [eax + esi*8 + 4], ecx
mov ecx, edx
inc esi
cmp esi, dword [ecx + 0xc]
jb 0x427f3e
mov edi, dword [ebp - 0x144]
mov eax, dword [ebp - 0x13c]
push eax
call fcn.0045f1d9
jmp 0x427ef9
mov esi, eax
cmp dword [ebp - 0x12c], 0
je 0x4280b1
lea eax, [ebp - 0x14c]
push eax
push 0x28
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
jne 0x427fe2
call ebx
mov ecx, dword [edi + 0xc]
mov edx, eax
test ecx, ecx
je 0x427fd2
cmp dword [0x4c12e0], 0
je 0x427fd2
mov eax, dword [ecx]
push edx
push str.Cannot_open_process_token__for_elevation_._Error:__d
push ecx
call dword [eax + 0x14]
add esp, 0xc
and dword [ebp - 0x12c], 0
call ebx
mov ebx, eax
jmp 0x4280f0
lea eax, [ebp - 0x170]
push eax
push str.SeShutdownPrivilege
push 0
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
test eax, eax
jne 0x428029
call ebx
mov edx, dword [edi + 0xc]
test edx, edx
je 0x42801b
cmp dword [0x4c12e0], 0
je 0x42801b
push eax
push str.Cannot_look_up_privilege__for_elevation_._Error:__d
mov ecx, dword [edx]
push edx
call dword [ecx + 0x14]
add esp, 0xc
push dword [ebp - 0x14c]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x427fd2
push 0x10
lea eax, [ebp - 0x118]
push 0
push eax
call fcn.0045b1d0
mov ecx, dword [ebp - 0x16c]
xor eax, eax
inc eax
mov dword [ebp - 0x110], ecx
add esp, 0xc
mov dword [ebp - 0x118], eax
mov eax, dword [ebp - 0x170]
mov dword [ebp - 0x114], eax
lea eax, [ebp - 0x164]
mov dword [ebp - 0x10c], 2
push eax
lea eax, [ebp - 0x128]
push eax
push 0x10
lea eax, [ebp - 0x118]
push eax
push 0
push dword [ebp - 0x14c]
call dword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
test eax, eax
jne 0x4280b1
call ebx
mov edx, dword [edi + 0xc]
test edx, edx
je 0x42801b
cmp dword [0x4c12e0], 0
je 0x42801b
push eax
push str.Cannot_enable_SE_SHUTDOWN_NAME_privilage_for_process_token._Error:__d
jmp 0x428012
push esi
push 2
push dword [ebp - 0x154]
call dword [sym.imp.ADVAPI32.dll_ChangeServiceConfig2A]
test eax, eax
je 0x428126
mov ecx, dword [edi + 0xc]
test ecx, ecx
je 0x4280ea
cmp dword [0x4c12e0], 0
je 0x4280ea
cmp dword [0x4c3630], 0
je 0x4280ea
mov eax, dword [ecx]
push str.Successfully_changed_service_recovery_rules
push ecx
call dword [eax + 0x10]
pop ecx
pop ecx
mov ebx, dword [ebp - 0x134]
mov eax, dword [ebp - 0x148]
test eax, eax
je 0x428101
push eax
call fcn.0045f1d9
pop ecx
mov eax, dword [ebp - 0x140]
test eax, eax
je 0x428112
push eax
call fcn.0045f1d9
pop ecx
mov eax, dword [ebp - 0x150]
test eax, eax
je 0x42825c
push eax
jmp 0x427ce1
call ebx
mov edx, dword [edi + 0xc]
test edx, edx
je 0x427fd9
cmp dword [0x4c12e0], 0
je 0x427fd9
mov ecx, dword [edx]
push eax
push dword [ebp - 0x138]
push str.Failed_to_changed_service_recovery_rules_for_service__s._Error:__d
push edx
call dword [ecx + 0x14]
add esp, 0x10
jmp 0x427fd9
push esi
push str.DescDLL
call fcn.004660fd
pop ecx
pop ecx
test eax, eax
jne 0x42818d
push dword [ebp - 0x138]
mov ecx, edi
push dword [ebp - 0x13c]
push dword [ebp - 0x154]
call fcn.004276f5
xor esi, esi
xor ebx, ebx
jmp 0x428262
push esi
push str.CommandLine
call fcn.004660fd
pop ecx
pop ecx
test eax, eax
jne 0x428481
push dword [ebp - 0x13c]
inc eax
mov ecx, edi
push eax
call fcn.0041c836
mov esi, eax
mov dword [ebp - 0x140], esi
test esi, esi
je 0x428447
push esi
call fcn.00461890
pop ecx
test eax, eax
je 0x428447
mov esi, dword [sym.imp.ADVAPI32.dll_QueryServiceConfigA]
lea eax, [ebp - 0x150]
push eax
push 0
push 0
push dword [ebp - 0x154]
call esi
call ebx
cmp eax, 0x7a
jne 0x42844d
push dword [ebp - 0x150]
call fcn.0045f1f4
pop ecx
mov ebx, eax
lea eax, [ebp - 0x150]
push eax
push dword [ebp - 0x150]
push ebx
push dword [ebp - 0x154]
call esi
test eax, eax
jne 0x4282f4
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, dword [edi + 0xc]
test edx, edx
je 0x42824b
cmp dword [0x4c12e0], 0
je 0x42824b
mov ecx, dword [edx]
push eax
push dword [ebp - 0x138]
push str.Unable_to_retrieve_Service_Config_for_service__s._Error:__d
push edx
call dword [ecx + 0x14]
add esp, 0x10
test ebx, ebx
je 0x428256
push ebx
call fcn.0045f1d9
pop ecx
mov ebx, dword [ebp - 0x134]
mov esi, dword [ebp - 0x12c]
mov eax, dword [ebp - 0x160]
test eax, eax
je 0x428273
push eax
call fcn.00458ee6
pop ecx
mov eax, dword [ebp - 0x130]
test eax, eax
je 0x428284
push eax
call fcn.00458ee6
pop ecx
test esi, esi
je 0x428514
xor ecx, ecx
lea eax, [ebp - 0x128]
push ecx
push ecx
push dword [ebp - 0x164]
push eax
push ecx
push dword [ebp - 0x14c]
call dword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
je 0x428508
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, dword [edi + 0xc]
test edx, edx
je 0x4282dd
cmp dword [0x4c12e0], 0
je 0x4282dd
mov ecx, dword [edx]
push eax
push str.Failed_to_remove_privilage_from_current_process_token._Error:__d
push edx
call dword [ecx + 0x14]
add esp, 0xc
push dword [ebp - 0x14c]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x428516
test ebx, ebx
jne 0x428320
mov ecx, dword [edi + 0xc]
test ecx, ecx
je 0x428256
cmp dword [0x4c12e0], ebx
je 0x428256
mov eax, dword [ecx]
push str.Detected_Unknown_error___service_config_not_populated
push ecx
call dword [eax + 0x14]
pop ecx
jmp 0x428255
mov eax, dword [ebx + 0xc]
push eax
mov dword [ebp - 0x15c], eax
call fcn.00461890
push dword [ebp - 0x140]
mov esi, eax
call fcn.00461890
add esi, 2
add eax, esi
push eax
mov dword [ebp - 0x148], eax
call fcn.0045f1f4
mov esi, eax
add esp, 0xc
test esi, esi
jne 0x428372
mov ecx, dword [edi + 0xc]
test ecx, ecx
je 0x428372
cmp dword [0x4c12e0], eax
je 0x428372
mov eax, dword [ecx]
push str.Unable_to_allocate_memory_for_binary_path_buffer.
push ecx
call dword [eax + 0x14]
pop ecx
pop ecx
mov eax, dword [ebp - 0x148]
mov ecx, esi
mov edx, eax
test eax, eax
je 0x428389
mov byte [ecx], 0
inc ecx
sub edx, 1
jne 0x428380
push dword [ebp - 0x15c]
push eax
push esi
call fcn.00465e4f
push 0x49b2e8
push dword [ebp - 0x148]
push esi
call fcn.00465e4f
push dword [ebp - 0x140]
push dword [ebp - 0x148]
push esi
call fcn.00465e4f
add esp, 0x24
xor eax, eax
push eax
push eax
push eax
push eax
push eax
push eax
push esi
push 0xffffffffffffffff
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp - 0x154]
call dword [sym.imp.ADVAPI32.dll_ChangeServiceConfigA]
xor ecx, ecx
inc ecx
cmp eax, ecx
jne 0x428408
mov ecx, dword [edi + 0xc]
test ecx, ecx
je 0x428433
cmp dword [0x4c12e0], 0
je 0x428433
cmp dword [0x4c3630], 0
je 0x428433
mov eax, dword [ecx]
push esi
push str.ChangeServiceConfig..Appended_command_line_parameter:__s
push ecx
call dword [eax + 0x10]
add esp, 0xc
jmp 0x428433
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, dword [edi + 0xc]
test edx, edx
je 0x428433
cmp dword [0x4c12e0], 0
je 0x428433
mov ecx, dword [edx]
push eax
push dword [ebp - 0x138]
push str...There_was_an_error_changing_the_service_configuration_for_service__s._Error:__d
push edx
call dword [ecx + 0x14]
add esp, 0x10
push esi
call fcn.0045f1d9
push ebx
call fcn.0045f1d9
mov esi, dword [ebp - 0x140]
pop ecx
pop ecx
push esi
jmp 0x428250
call ebx
mov edx, dword [edi + 0xc]
test edx, edx
je 0x428256
cmp dword [0x4c12e0], 0
je 0x428256
mov ecx, dword [edx]
push eax
push dword [ebp - 0x138]
push str.Error_retrieving_Service_Config_for_service__s_or_Service_Does_not_Exists._Error:__d
push edx
call dword [ecx + 0x14]
add esp, 0x10
jmp 0x428256
mov ecx, dword [edi + 0xc]
test ecx, ecx
je 0x427d10
test esi, esi
je 0x4284b7
cmp dword [0x4c12e0], 0
je 0x427d10
push dword [ebp - 0x138]
mov eax, dword [ecx]
push esi
push str.Unsupported_command___s__found_in_service_recovery_section_when_trying_to_set_extra_service_params__s
push ecx
call dword [eax + 0x14]
add esp, 0x10
jmp 0x427d10
cmp dword [0x4c12e0], 0
je 0x427d10
push dword [ebp - 0x138]
push str.Unsupported_command_found_in_service_recovery_section_when_trying_to_set_extra_service_params__s
jmp 0x427d07
call ebx
mov edx, dword [edi + 0xc]
test edx, edx
je 0x4284fb
cmp dword [0x4c12e0], 0
je 0x4284fb
mov ecx, dword [edx]
push eax
push dword [ebp - 0x138]
push str.Error_retrieving_Service_Config_for_service__s_or_Service_Does_not_Exists._Error:__d
push edx
call dword [ecx + 0x14]
add esp, 0x10
mov ebx, dword [ebp - 0x134]
mov esi, ebx
jmp 0x428262
push dword [ebp - 0x14c]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, ebx
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00458eeb
leave
ret 0x10