Function at 0x408510
Capabilities:
Accept command line arguments

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4a3ee1
mov eax, dword fs:[0]
push eax
sub esp, 0x254
mov eax, dword [0x4d8368]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov dword [ebp - 0x254], edi
mov ebx, dword [ebp + 8]
push edi
push dword [edi + 4]
mov dword [ebp - 0x258], ebx
push dword [edi]
mov dword [ebp - 0x24c], 0
call fcn.004018f0
mov eax, dword [edi]
add esp, 0xc
mov dword [edi + 4], eax
lea eax, [edi + 0x10]
mov dword [edi + 0xc], 0
mov dword [eax + 0x10], 0
cmp dword [eax + 0x14], 8
jb 0x408585
mov eax, dword [eax]
xor ecx, ecx
mov word [eax], cx
mov dword [edi + 0x38], ecx
lea ecx, [edi + 0x28]
cmp dword [edi + 0x3c], 8
jb 0x408599
mov ecx, dword [edi + 0x28]
xor eax, eax
mov word [ecx], ax
mov dword [edi + 0x40], eax
add edi, 0x44
mov ecx, edi
mov esi, dword [edi]
push dword [esi + 4]
push edi
call fcn.00406b40
mov dword [esi + 4], esi
mov dword [esi], esi
mov dword [esi + 8], esi
mov esi, dword [ebp - 0x254]
lea ecx, [esi + 0x4c]
mov dword [edi + 4], 0
mov dword [ecx + 0x10], 0
mov eax, ecx
cmp dword [ecx + 0x14], 8
mov dword [ebp - 0x260], ecx
jb 0x4085e0
mov eax, dword [ecx]
xor ecx, ecx
mov word [eax], cx
cmp dword [ebx + 0x10], ecx
je 0x408e65
cmp dword [ebx + 0x14], 8
mov eax, ebx
mov dword [ebp - 0x250], ecx
jb 0x4085fe
mov eax, dword [ebx]
lea ecx, [ebp - 0x250]
push ecx
push eax
call dword [sym.imp.SHELL32.dll_CommandLineToArgvW]
mov ebx, eax
mov dword [ebp - 0x25c], ebx
test ebx, ebx
je 0x408776
mov ecx, dword [esi + 8]
mov eax, 0x2aaaaaab
sub ecx, dword [esi]
imul ecx
mov ecx, dword [ebp - 0x250]
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
cmp ecx, eax
jbe 0x408656
cmp ecx, 0xaaaaaaa
ja 0x408e85
push ecx
mov ecx, esi
call fcn.00409720
mov ecx, dword [ebp - 0x250]
xor edi, edi
test ecx, ecx
jle 0x40876f
mov edx, dword [ebx + edi*4]
test edx, edx
je 0x408766
mov ecx, edx
mov dword [ebp - 0x220], 0
xor eax, eax
mov dword [ebp - 0x21c], 7
mov word [ebp - 0x230], ax
lea ebx, [ecx + 2]
lea ecx, [ecx]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x408690
sub ecx, ebx
sar ecx, 1
push ecx
push edx
lea ecx, [ebp - 0x230]
call fcn.00402e10
mov ecx, dword [esi + 4]
mov dword [ebp - 4], 0
cmp ecx, dword [esi + 8]
je 0x408704
mov eax, dword [ebp - 0x230]
mov edx, 7
mov dword [ecx], eax
mov eax, dword [ebp - 0x22c]
mov dword [ecx + 4], eax
mov eax, dword [ebp - 0x228]
mov dword [ecx + 8], eax
mov eax, dword [ebp - 0x224]
mov dword [ecx + 0xc], eax
mov eax, dword [ebp - 0x220]
mov dword [ecx + 0x10], eax
mov eax, dword [ebp - 0x21c]
mov dword [ecx + 0x14], eax
xor eax, eax
add dword [esi + 4], 0x18
mov word [ebp - 0x230], ax
jmp 0x408719
lea eax, [ebp - 0x230]
push eax
push ecx
mov ecx, esi
call fcn.00406830
mov edx, dword [ebp - 0x21c]
mov dword [ebp - 4], 0xffffffff
cmp edx, 8
jb 0x40875a
mov ecx, dword [ebp - 0x230]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x408750
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x408e8a
push edx
push ecx
call fcn.00464df3
add esp, 8
mov ebx, dword [ebp - 0x25c]
mov ecx, dword [ebp - 0x250]
inc edi
cmp edi, ecx
jl 0x408660
push ebx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov ecx, dword [esi + 4]
mov eax, 0x2aaaaaab
mov ebx, dword [esi]
sub ecx, ebx
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
cmp eax, 2
jbe 0x4087f5
cmp dword [ebx + 0x2c], 8
lea edi, [ebx + 0x18]
jb 0x40879f
mov edi, dword [ebx + 0x18]
cmp dword [ebx + 0x28], 0xc
jne 0x4087f5
mov ecx, 0x4ad65c
mov edx, 0xc
sub edi, ecx
mov ax, word [edi + ecx]
cmp ax, word [ecx]
jne 0x4087f5
add ecx, 2
sub edx, 1
jne 0x4087b1
lea eax, [ebx + 0x30]
push eax
lea eax, [ebp - 0x248]
push eax
call fcn.0041e320
add esp, 8
mov dword [ebp - 0x24c], 1
mov ecx, eax
push 0
push 0x4ad7f8
call fcn.00404fc0
test eax, eax
jne 0x4087f5
mov bl, 1
jmp 0x4087f7
xor bl, bl
test byte [ebp - 0x24c], 1
je 0x40880b
lea ecx, [ebp - 0x248]
call fcn.00402320
test bl, bl
je 0x408820
mov ecx, dword [esi]
push 0x10
add ecx, 0x18
push str._jsapihttpserver
call fcn.00402e10
mov ebx, dword [esi + 4]
mov eax, 0x2aaaaaab
mov edi, dword [esi]
mov ecx, ebx
sub ecx, edi
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
je 0x4088cd
cmp dword [edi + 0x14], 8
mov eax, edi
jb 0x40884a
mov eax, dword [edi]
push eax
lea ebx, [esi + 0x10]
call dword [sym.imp.SHLWAPI.dll_PathIsRelativeW]
test eax, eax
je 0x4088a8
push 0x208
lea eax, [ebp - 0x218]
push 0
push eax
call fcn.0047ce40
add esp, 0xc
lea eax, [ebp - 0x218]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea ecx, [ebp - 0x218]
lea edx, [ecx + 2]
jmp 0x408890
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x408890
sub ecx, edx
lea eax, [ebp - 0x218]
sar ecx, 1
push ecx
jmp 0x4088b9
cmp ebx, edi
je 0x4088c1
cmp dword [edi + 0x14], 8
mov eax, edi
jb 0x4088b6
mov eax, dword [edi]
push dword [edi + 0x10]
push eax
mov ecx, ebx
call fcn.00402e10
mov dword [esi + 0x40], 1
mov ebx, dword [esi + 4]
mov edi, dword [esi]
sub ebx, edi
mov eax, 0x2aaaaaab
imul ebx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
cmp eax, 2
jb 0x408e65
add edi, 0x18
lea ebx, [esi + 0x28]
cmp ebx, edi
je 0x408908
cmp dword [edi + 0x14], 8
mov eax, edi
jb 0x4088fd
mov eax, dword [edi]
push dword [edi + 0x10]
mov ecx, ebx
push eax
call fcn.00402e10
cmp dword [ebx + 0x14], 8
jb 0x408910
mov ebx, dword [ebx]
push str.LocalService
push ebx
call fcn.0041e0f0
add esp, 8
test eax, eax
jne 0x40892c
mov eax, 1
jmp 0x4089e0
push str.InstallService
push ebx
call fcn.0041e0f0
add esp, 8
test eax, eax
jne 0x408948
mov eax, 2
jmp 0x4089e0
push str.UninstallService
push ebx
call fcn.0041e0f0
add esp, 8
test eax, eax
jne 0x408964
mov eax, 3
jmp 0x4089e0
push str.RepairService
push ebx
call fcn.0041e0f0
add esp, 8
test eax, eax
jne 0x40897d
mov eax, 4
jmp 0x4089e0
push str.CheckService
push ebx
call fcn.0041e0f0
add esp, 8
test eax, eax
jne 0x408996
mov eax, 5
jmp 0x4089e0
push str.Stop
push ebx
call fcn.0041e0f0
add esp, 8
test eax, eax
jne 0x4089af
mov eax, 6
jmp 0x4089e0
push 0x4ad8dc
push ebx
call fcn.0041e0f0
add esp, 8
test eax, eax
jne 0x4089c8
mov eax, 7
jmp 0x4089e0
push str.UpdateService
push ebx
call fcn.0041e0f0
add esp, 8
neg eax
sbb eax, eax
and eax, 0xfffffff8
add eax, 8
mov dword [esi + 0xc], eax
mov edi, 2
mov dword [esi + 0x40], 2
mov eax, 0x2aaaaaab
mov ecx, dword [esi + 4]
mov ebx, dword [esi]
mov dword [ebp - 0x250], ecx
sub ecx, ebx
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
cmp eax, edi
jbe 0x408aca
mov edx, ebx
mov ecx, dword [ebp - 0x250]
mov eax, edi
lea eax, [eax + eax*2]
lea esi, [edx + eax*8]
mov edx, dword [esi + 0x10]
cmp edx, 2
jb 0x408b63
mov ebx, dword [esi + 0x14]
mov eax, esi
cmp ebx, 8
jb 0x408a3d
mov eax, dword [esi]
cmp word [eax], 0x2f
jne 0x408a78
mov eax, esi
cmp ebx, 8
jb 0x408a4c
mov eax, dword [esi]
lea edi, [eax + edx*2]
mov ecx, esi
jb 0x408a55
mov ecx, dword [esi]
xor edx, edx
cmp ecx, edi
je 0x408a78
jmp 0x408a60
cmp word [ecx], 0x2f
lea eax, [edx + 1]
cmovne eax, edx
add ecx, 2
mov edx, eax
cmp ecx, edi
jne 0x408a60
cmp edx, 1
je 0x408a8b
mov eax, esi
cmp ebx, 8
jb 0x408a81
mov eax, dword [esi]
cmp word [eax], 0x2d
jne 0x408b53
push esi
mov esi, dword [ebp - 0x254]
mov ecx, esi
call fcn.00407ff0
mov edi, dword [esi + 0x40]
inc edi
mov dword [esi + 0x40], edi
mov eax, dword [esi + 4]
mov ecx, eax
mov ebx, dword [esi]
sub ecx, ebx
mov dword [ebp - 0x250], eax
mov eax, 0x2aaaaaab
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
mov edx, ebx
cmp edi, eax
jb 0x408a17
mov ecx, dword [esi + 4]
sub ecx, ebx
mov eax, 0x2aaaaaab
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
cmp edi, eax
jae 0x408d05
lea eax, [edi + edi*2]
cmp dword [ebx + eax*8 + 0x14], 8
lea edi, [ebx + eax*8]
mov ecx, edi
jb 0x408af9
mov ecx, dword [edi]
mov ebx, dword [edi + 0x10]
test ebx, ebx
je 0x408b73
or edx, 0xffffffff
lea eax, [ebx - 1]
cmp eax, edx
cmovb edx, eax
add edx, edx
cmp word [edx + ecx], 0x2e
lea eax, [edx + ecx]
je 0x408b24
cmp eax, ecx
je 0x408b73
sub eax, 2
cmp word [eax], 0x2e
jne 0x408b17
sub eax, ecx
sar eax, 1
cmp eax, 0xffffffff
je 0x408b73
cmp dword [edi + 0x14], 8
mov eax, edi
jb 0x408b37
mov eax, dword [edi]
add edx, eax
cmp word [edx], 0x2e
je 0x408b4d
nop
cmp edx, eax
je 0x408b6e
sub edx, 2
cmp word [edx], 0x2e
jne 0x408b40
sub edx, eax
sar edx, 1
jmp 0x408b75
mov esi, dword [ebp - 0x254]
mov ebx, dword [esi]
mov edi, dword [esi + 0x40]
jmp 0x408aca
mov esi, dword [ebp - 0x254]
jmp 0x408acd
or edx, 0xffffffff
jmp 0x408b75
xor edx, edx
lea eax, [ebx - 1]
mov dword [ebp - 0x220], 0
mov dword [ebp - 0x24c], eax
xor eax, eax
mov dword [ebp - 0x21c], 7
mov word [ebp - 0x230], ax
cmp ebx, edx
jb 0x408e8f
mov eax, ebx
mov ecx, 1
sub eax, edx
cmp eax, dword [ebp - 0x24c]
cmovb ecx, edx
sub ebx, ecx
cmp dword [edi + 0x14], 8
jb 0x408bbf
mov edi, dword [edi]
push ebx
lea eax, [edi + edx*2]
push eax
lea ecx, [ebp - 0x230]
call fcn.00402e10
cmp dword [ebp - 0x21c], 8
lea edi, [ebp - 0x230]
mov ebx, dword [ebp - 0x230]
mov ecx, 4
mov eax, dword [ebp - 0x220]
cmovae edi, ebx
cmp eax, ecx
mov dword [ebp - 4], 1
mov edx, eax
cmova edx, ecx
mov ecx, str..exe
test edx, edx
je 0x408c2b
sub edi, ecx
lea esp, [esp]
mov ax, word [edi + ecx]
cmp ax, word [ecx]
jne 0x408cbf
add ecx, 2
sub edx, 1
jne 0x408c10
mov eax, dword [ebp - 0x220]
cmp eax, 4
jb 0x408cbf
ja 0x408cbf
push 4
xor eax, eax
mov dword [ebp - 0x238], 0
push str._Exe
lea ecx, [ebp - 0x248]
mov dword [ebp - 0x234], 7
mov word [ebp - 0x248], ax
call fcn.00402e10
lea eax, [ebp - 0x248]
mov byte [ebp - 4], 2
push eax
mov ecx, esi
call fcn.00407ff0
mov edx, dword [ebp - 0x234]
mov byte [ebp - 4], 1
cmp edx, 8
jb 0x408cbf
mov ecx, dword [ebp - 0x248]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x408cb5
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x408e8a
push edx
push ecx
call fcn.00464df3
add esp, 8
mov eax, dword [ebp - 0x21c]
mov dword [ebp - 4], 0xffffffff
cmp eax, 8
jb 0x408d00
lea ecx, [eax*2 + 2]
mov eax, ebx
cmp ecx, 0x1000
jb 0x408cf6
mov ebx, dword [ebx - 4]
add ecx, 0x23
sub eax, ebx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x408e99
push ecx
push ebx
call fcn.00464df3
add esp, 8
mov edi, dword [esi + 0x40]
mov ebx, dword [esi]
lea eax, [edi + edi*2]
cmp dword [ebx + eax*8 - 4], 8
lea ebx, [ebx + eax*8]
lea edx, [ebx - 0x18]
jb 0x408d18
mov edx, dword [ebx - 0x18]
mov esi, dword [ebp - 0x258]
mov ecx, esi
mov edi, dword [esi + 0x14]
cmp edi, 8
jb 0x408d2a
mov ecx, dword [esi]
push dword [ebx - 8]
mov esi, dword [esi + 0x10]
push edx
push 0
push esi
push ecx
call fcn.00406d20
inc eax
add esp, 0x14
add eax, dword [ebx - 8]
cmp eax, esi
ja 0x408e5e
xor ecx, ecx
mov dword [ebp - 0x21c], 7
sub esi, eax
mov word [ebp - 0x230], cx
mov ecx, dword [ebp - 0x258]
cmp esi, 0xffffffff
mov ebx, 0xffffffff
cmovb ebx, esi
cmp edi, 8
jb 0x408d76
mov ecx, dword [ecx]
lea eax, [ecx + eax*2]
mov dword [ebp - 0x24c], eax
cmp ebx, 7
ja 0x408daa
lea esi, [ebx + ebx]
mov dword [ebp - 0x220], ebx
push esi
push eax
lea eax, [ebp - 0x230]
push eax
call fcn.0047c8c0
add esp, 0xc
xor eax, eax
mov word [ebp + esi - 0x230], ax
jmp 0x408e10
cmp ebx, 0x7ffffffe
ja 0x408e94
mov esi, ebx
or esi, 7
cmp esi, 0x7ffffffe
jbe 0x408dca
mov esi, 0x7ffffffe
jmp 0x408dd4
mov eax, 0xa
cmp esi, eax
cmovb esi, eax
lea eax, [esi + 1]
push eax
lea ecx, [ebp - 0x230]
call fcn.00402c30
mov dword [ebp - 0x21c], esi
mov edi, eax
lea esi, [ebx + ebx]
mov dword [ebp - 0x220], ebx
push esi
push dword [ebp - 0x24c]
push edi
call fcn.0047c340
add esp, 0xc
mov dword [ebp - 0x230], edi
xor eax, eax
mov word [edi + esi], ax
mov ecx, dword [ebp - 0x260]
lea eax, [ebp - 0x230]
push eax
call fcn.004072d0
mov edx, dword [ebp - 0x21c]
cmp edx, 8
jb 0x408e5e
mov ecx, dword [ebp - 0x230]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x408e54
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x408e99
push edx
push ecx
call fcn.00464df3
add esp, 8
mov eax, 1
jmp 0x408e67
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00465060
mov esp, ebp
pop ebp
ret 8
call fcn.00402a60
call fcn.00485d39
call fcn.00404e40
call fcn.00402a50
call fcn.00485d39
int3