Function at 0x40f980
Capabilities:
Create process on windows
Terminate process

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffff9c
mov eax, 0x48fd74
push ebx
call fcn.004696b8
mov word [ebp - 0x48], 0x14
mov edx, 0x48c516
lea eax, [ebp - 4]
call fcn.00474b48
inc dword [ebp - 0x3c]
mov dl, byte [0x48b0b6]
mov word [ebp - 0x48], 8
mov byte [ebp - 0x59], 0
test dl, dl
je 0x40fcb1
mov word [ebp - 0x48], 0x2c
xor ecx, ecx
lea edx, [ebp - 8]
mov dword [ebp - 8], ecx
mov eax, 1
inc dword [ebp - 0x3c]
call fcn.00465f1c
mov word [ebp - 0x48], 0x20
mov word [ebp - 0x48], 0x38
mov edx, 0x48c521
lea eax, [ebp - 0xc]
call fcn.00474b48
inc dword [ebp - 0x3c]
lea edx, [ebp - 0xc]
mov eax, 0x49b13c
call fcn.00474e28
push eax
dec dword [ebp - 0x3c]
lea eax, [ebp - 0xc]
mov edx, 2
call fcn.00474d44
pop ecx
test cl, cl
je 0x40fbb6
mov word [ebp - 0x48], 0x20
mov ebx, 2
jmp 0x40fa96
mov eax, dword [ebp - 8]
call fcn.0045f8bc
test al, al
jne 0x40fad8
mov word [ebp - 0x48], 0x50
xor edx, edx
mov eax, ebx
mov dword [ebp - 0x18], edx
lea edx, [ebp - 0x18]
inc dword [ebp - 0x3c]
call fcn.00465f1c
lea edx, [ebp - 0x18]
xor eax, eax
mov dword [ebp - 0x1c], eax
lea ecx, [ebp - 0x1c]
inc dword [ebp - 0x3c]
mov eax, 0x48c529
call fcn.00475018
lea edx, [ebp - 0x1c]
lea eax, [ebp - 8]
call fcn.00474d88
dec dword [ebp - 0x3c]
lea eax, [ebp - 0x1c]
mov edx, 2
call fcn.00474d44
dec dword [ebp - 0x3c]
lea eax, [ebp - 0x18]
mov edx, 2
call fcn.00474d44
inc ebx
mov word [ebp - 0x48], 0x44
xor ecx, ecx
lea edx, [ebp - 0x14]
mov dword [ebp - 0x14], ecx
mov eax, ebx
inc dword [ebp - 0x3c]
call fcn.00465f1c
lea eax, [ebp - 0x14]
call fcn.00474e58
test eax, eax
lea eax, [ebp - 0x14]
setne dl
and edx, 1
push edx
mov edx, 2
dec dword [ebp - 0x3c]
call fcn.00474d44
pop ecx
test ecx, ecx
jne 0x40fa2a
mov word [ebp - 0x48], 0x68
xor eax, eax
mov dword [ebp - 0x10], eax
lea edx, [ebp - 0x10]
inc dword [ebp - 0x3c]
mov eax, ebx
inc ebx
call fcn.00465f1c
mov word [ebp - 0x48], 0x5c
jmp 0x40fb55
mov word [ebp - 0x48], 0x74
xor edx, edx
mov eax, ebx
mov dword [ebp - 0x20], edx
lea edx, [ebp - 0x20]
inc dword [ebp - 0x3c]
call fcn.00465f1c
lea edx, [ebp - 0x20]
xor eax, eax
mov dword [ebp - 0x24], eax
lea ecx, [ebp - 0x24]
inc dword [ebp - 0x3c]
mov eax, 0x48c52b
call fcn.00475018
lea edx, [ebp - 0x24]
lea eax, [ebp - 0x10]
call fcn.00474d88
dec dword [ebp - 0x3c]
lea eax, [ebp - 0x24]
mov edx, 2
call fcn.00474d44
dec dword [ebp - 0x3c]
lea eax, [ebp - 0x20]
mov edx, 2
call fcn.00474d44
inc ebx
call fcn.00465ebc
cmp ebx, eax
jle 0x40faf9
push 1
push 0
mov ecx, dword [ebp - 0x10]
test ecx, ecx
je 0x40fb6e
mov eax, dword [ebp - 0x10]
jmp 0x40fb73
mov eax, 0x48c532
push eax
mov edx, dword [ebp - 8]
test edx, edx
je 0x40fb80
mov ecx, dword [ebp - 8]
jmp 0x40fb85
mov ecx, 0x48c531
mov eax, dword [0x49a444]
push ecx
push 0x48c52d
mov edx, dword [eax]
mov eax, dword [edx + 0x24]
push eax
call sub.SHELL32.DLL_ShellExecuteA
dec dword [ebp - 0x3c]
lea eax, [ebp - 0x10]
mov edx, 2
call fcn.00474d44
mov word [ebp - 0x48], 0x20
jmp 0x40fc91
mov word [ebp - 0x48], 0x20
mov ebx, 2
jmp 0x40fc1f
mov word [ebp - 0x48], 0x8c
xor eax, eax
lea edx, [ebp - 0x2c]
mov dword [ebp - 0x2c], eax
mov eax, ebx
inc dword [ebp - 0x3c]
call fcn.00465f1c
lea edx, [ebp - 0x2c]
xor ecx, ecx
mov dword [ebp - 0x30], ecx
lea ecx, [ebp - 0x30]
inc dword [ebp - 0x3c]
mov eax, 0x48c533
call fcn.00475018
lea edx, [ebp - 0x30]
lea eax, [ebp - 8]
call fcn.00474d88
dec dword [ebp - 0x3c]
lea eax, [ebp - 0x30]
mov edx, 2
call fcn.00474d44
dec dword [ebp - 0x3c]
lea eax, [ebp - 0x2c]
mov edx, 2
call fcn.00474d44
inc ebx
mov word [ebp - 0x48], 0x80
xor ecx, ecx
lea edx, [ebp - 0x28]
mov dword [ebp - 0x28], ecx
mov eax, ebx
inc dword [ebp - 0x3c]
call fcn.00465f1c
lea eax, [ebp - 0x28]
call fcn.00474e58
test eax, eax
lea eax, [ebp - 0x28]
setne dl
and edx, 1
push edx
mov edx, 2
dec dword [ebp - 0x3c]
call fcn.00474d44
pop ecx
test ecx, ecx
jne 0x40fbc3
push 1
push 0
mov eax, dword [ebp - 8]
test eax, eax
je 0x40fc71
mov edx, dword [ebp - 8]
jmp 0x40fc76
mov edx, 0x48c546
push edx
mov eax, dword [0x49a444]
push str.NotePad.exe
push 0x48c535
mov ecx, dword [eax]
mov eax, dword [ecx + 0x24]
push eax
call sub.SHELL32.DLL_ShellExecuteA
mov eax, dword [sym.G_Server.exe__MainForm]
call fcn.0040fea8
dec dword [ebp - 0x3c]
lea eax, [ebp - 8]
mov edx, 2
call fcn.00474d44
mov word [ebp - 0x48], 8
mov ecx, dword [ebp - 4]
test ecx, ecx
je 0x40fcbd
mov eax, dword [ebp - 4]
jmp 0x40fcc2
mov eax, 0x48c547
push eax
push 0
call sub.USER32.DLL_FindWindowA
mov ebx, eax
test ebx, ebx
je 0x40fcf4
mov byte [ebp - 0x59], 1
mov al, byte [0x48b0b6]
test al, al
jne 0x40fcf4
push 0
push 0
push 0x10
push ebx
call sub.USER32.DLL_PostMessageA
push 0x7d0
call fcn.00403e2c
pop ecx
mov eax, 0x49b124
call fcn.00474e58
test eax, eax
je 0x40fd0f
mov edx, 0x49b124
lea eax, [ebp - 4]
call fcn.00474d74
mov word [ebp - 0x48], 0x98
xor edx, edx
lea ecx, [ebp - 0x34]
mov dword [ebp - 0x34], edx
push ecx
inc dword [ebp - 0x3c]
lea eax, [ebp - 4]
call fcn.00474e58
mov ecx, eax
add ecx, 0xfffffffe
lea eax, [ebp - 4]
mov edx, 1
call fcn.00474f88
mov ecx, dword [ebp - 0x34]
test ecx, ecx
je 0x40fd47
mov eax, dword [ebp - 0x34]
jmp 0x40fd4c
mov eax, 0x48c548
push eax
push 0
call sub.USER32.DLL_FindWindowA
mov ebx, eax
dec dword [ebp - 0x3c]
lea eax, [ebp - 0x34]
mov edx, 2
call fcn.00474d44
test ebx, ebx
je 0x40fd8f
mov byte [ebp - 0x59], 1
mov cl, byte [0x48b0b6]
test cl, cl
jne 0x40fd8f
push 0
push 0
push 0x10
push ebx
call sub.USER32.DLL_PostMessageA
push 0x7d0
call fcn.00403e2c
pop ecx
mov eax, dword [ebp - 4]
test eax, eax
je 0x40fd9b
mov edx, dword [ebp - 4]
jmp 0x40fda0
mov edx, 0x48c549
push edx
push 0
call sub.USER32.DLL_FindWindowA
mov ebx, eax
test ebx, ebx
je 0x40fded
mov byte [ebp - 0x59], 1
mov al, byte [0x48b0b6]
test al, al
jne 0x40fded
push 0
push 0
push 0x10
push ebx
call sub.USER32.DLL_PostMessageA
push 0x7d0
call fcn.00403e2c
pop ecx
mov edx, dword [ebp - 4]
test edx, edx
je 0x40fdde
mov ecx, dword [ebp - 4]
jmp 0x40fde3
mov ecx, 0x48c54a
push ecx
push 0
call sub.USER32.DLL_FindWindowA
mov ebx, eax
mov eax, dword [0x49a444]
mov edx, dword [ebp - 4]
mov eax, dword [eax]
call fcn.00440e94
test ebx, ebx
je 0x40fe54
mov byte [ebp - 0x59], 1
mov cl, byte [0x48b0b6]
test cl, cl
jne 0x40fe54
xor eax, eax
lea edx, [ebp - 0x60]
mov dword [ebp - 0x60], eax
mov word [ebp - 0x48], 8
push edx
push ebx
call sub.USER32.DLL_GetWindowThreadProcessId
lea ecx, [ebp - 0x64]
push ecx
mov eax, dword [ebp - 0x60]
push eax
push 1
push 0x400
call sub.KERNEL32.DLL_OpenProcess
push eax
call sub.KERNEL32.DLL_GetExitCodeProcess
mov edx, dword [ebp - 0x64]
push edx
mov ecx, dword [ebp - 0x60]
push ecx
push 1
push 1
call sub.KERNEL32.DLL_OpenProcess
push eax
call sub.KERNEL32.DLL_TerminateProcess
mov al, byte [ebp - 0x59]
test al, al
je 0x40fe84
mov dl, byte [0x48b0b6]
test dl, dl
je 0x40fe84
xor eax, eax
mov edx, 2
push eax
lea eax, [ebp - 4]
dec dword [ebp - 0x3c]
call fcn.00474d44
pop eax
mov edx, dword [ebp - 0x58]
mov dword fs:[0], edx
jmp 0x40fea1
mov al, 1
mov edx, 2
push eax
lea eax, [ebp - 4]
dec dword [ebp - 0x3c]
call fcn.00474d44
pop eax
mov edx, dword [ebp - 0x58]
mov dword fs:[0], edx
pop ebx
mov esp, ebp
pop ebp
ret