Function at 0x405610
Capabilities:
Accept command line arguments

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x3ec
push edi
mov edi, dword [ebp + 8]
mov dword [edi + 0x3064], 0xf
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
lea ecx, [ebp - 4]
push ecx
push eax
call dword [sym.imp.SHELL32.dll_CommandLineToArgvW]
test eax, eax
jne 0x405657
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.____Error_call_CommandLineToArgvW__code:__d_n
call fcn.00406130
add esp, 8
xor eax, eax
pop edi
mov esp, ebp
pop ebp
ret
cmp dword [ebp - 4], 1
mov dword [ebp + 8], 1
jle 0x405975
push ebx
lea ebx, [eax + 4]
push esi
nop dword [eax]
push 0x3e8
lea eax, [ebp - 0x3ec]
push 0
push eax
call fcn.00410280
mov ecx, dword [ebx]
add esp, 0xc
movzx eax, word [ecx]
cmp eax, 0x2d
je 0x405699
cmp eax, 0x2f
jne 0x40596c
lea eax, [ebp - 0x3ec]
push eax
lea eax, [ecx + 2]
push eax
call fcn.00408200
add esp, 8
lea ecx, [ebp - 0x3ec]
mov edx, str.NOMUTEX
mov esi, 0xc
nop dword [eax]
mov eax, dword [ecx]
cmp eax, dword [edx]
jne 0x4056e0
add ecx, 4
add edx, 4
sub esi, 4
jae 0x4056c0
mov dword [edi + 0x17c], 1
jmp 0x40594d
lea eax, [ebp - 0x3ec]
cmp dword [eax], 0x4f004c
jne 0x40570c
cmp dword [eax + 4], 0x47
jne 0x40570c
push edi
mov dword [edi + 0x180], 1
call fcn.004062c0
add esp, 4
jmp 0x40594d
lea ecx, [ebp - 0x3ec]
mov edx, str.TARGET
mov esi, 0xa
nop dword [eax]
mov eax, dword [ecx]
cmp eax, dword [edx]
jne 0x405776
add ecx, 4
add edx, 4
sub esi, 4
jae 0x405720
mov ax, word [ecx]
cmp ax, word [edx]
jne 0x405776
inc dword [ebp + 8]
add ebx, 4
xor ecx, ecx
mov eax, dword [ebx]
mov al, byte [eax]
lea ecx, [ecx + 1]
mov byte [edi + ecx + 0x18f], al
mov eax, dword [ebx]
cmp word [eax + ecx*2], 0
lea eax, [eax + ecx*2]
jne 0x405743
cmp byte [ecx + edi + 0x18f], 0x5c
je 0x40594d
mov byte [edi + ecx + 0x190], 0x5c
jmp 0x40594d
lea eax, [ebp - 0x3ec]
cmp dword [eax], 0x440049
jne 0x4057bd
movzx eax, word [eax + 4]
test ax, ax
jne 0x4057bd
inc dword [ebp + 8]
add ebx, 4
xor ecx, ecx
mov eax, dword [ebx]
nop word [eax + eax]
mov al, byte [eax]
lea ecx, [ecx + 1]
mov byte [edi + ecx + 0x294], al
mov eax, dword [ebx]
cmp word [eax + ecx*2], 0
lea eax, [eax + ecx*2]
jne 0x4057a0
jmp 0x40594d
lea ecx, [ebp - 0x3ec]
mov edx, str.CONSOLE
mov esi, 0xc
nop dword [eax]
mov eax, dword [ecx]
cmp eax, dword [edx]
jne 0x405837
add ecx, 4
add edx, 4
sub esi, 4
jae 0x4057d0
mov dword [edi + 0x184], 1
call dword [sym.imp.KERNEL32.dll_AllocConsole]
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x40580b
call esi
push eax
push str.____Error_call_AllocConsole__code:__d_n
call fcn.00406130
add esp, 8
push 0xfffffffffffffff5
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
mov dword [edi + 0x39c], eax
cmp eax, 0xffffffff
jne 0x40594d
call esi
push eax
push str.____Error_call_GetStdHandle__code:__d_n
call fcn.00406130
add esp, 8
jmp 0x40594d
lea ecx, [ebp - 0x3ec]
mov edx, str.PROCOFF
mov esi, 0xc
mov eax, dword [ecx]
cmp eax, dword [edx]
jne 0x405867
add ecx, 4
add edx, 4
sub esi, 4
jae 0x405847
mov dword [edi + 0x188], 1
jmp 0x40594d
lea ecx, [ebp - 0x3ec]
mov edx, str.UNCOFF
mov esi, 0xa
mov eax, dword [ecx]
cmp eax, dword [edx]
jne 0x40589f
add ecx, 4
add edx, 4
sub esi, 4
jae 0x405877
mov ax, word [ecx]
cmp ax, word [edx]
jne 0x40589f
mov dword [edi + 0x18c], 1
jmp 0x40594d
lea eax, [ebp - 0x3ec]
cmp dword [eax], 0x490053
jne 0x40594d
cmp dword [eax + 4], 0x45005a
jne 0x40594d
movzx eax, word [eax + 8]
test ax, ax
jne 0x40594d
mov eax, dword [ebx + 4]
add ebx, 4
inc dword [ebp + 8]
movzx ecx, word [eax]
add ecx, 0xffffffd0
mov dword [edi + 0x3064], ecx
mov eax, dword [ebx]
movzx eax, word [eax + 2]
test ax, ax
je 0x405928
cmp eax, 0x30
jb 0x40596c
cmp eax, 0x39
ja 0x40596c
lea ecx, [ecx + ecx*4]
lea ecx, [ecx - 0x18]
lea ecx, [eax + ecx*2]
mov dword [edi + 0x3064], ecx
mov eax, dword [ebx]
movzx eax, word [eax + 4]
test ax, ax
je 0x405928
cmp eax, 0x30
jb 0x40596c
cmp eax, 0x39
ja 0x40596c
lea ecx, [ecx + ecx*4]
lea eax, [eax + ecx*2]
add eax, 0xffffffd0
mov dword [edi + 0x3064], eax
mov eax, dword [edi + 0x3064]
test eax, eax
jg 0x40593e
mov dword [edi + 0x3064], 0xf
jmp 0x40594d
cmp eax, 0x64
jle 0x40594d
mov dword [edi + 0x3064], 0x64
mov eax, dword [ebp + 8]
add ebx, 4
inc eax
mov dword [ebp + 8], eax
cmp eax, dword [ebp - 4]
jl 0x405670
pop esi
pop ebx
mov eax, 1
pop edi
mov esp, ebp
pop ebp
ret
pop esi
pop ebx
xor eax, eax
pop edi
mov esp, ebp
pop ebp
ret
mov eax, 1
pop edi
mov esp, ebp
pop ebp
ret