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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x320
mov eax, dword [0x43a008]
xor eax, ebp
mov dword [ebp - 8], eax
mov eax, dword [ebp + 0x14]
push ebx
mov ebx, ecx
mov dword [ebp - 0x2f8], eax
mov eax, dword [ebp + 0x18]
push esi
mov esi, dword [ebp + 8]
mov ecx, dword [ebx + 0x18]
push edi
mov edi, dword [ebp + 0xc]
mov dword [ebp - 0x2e4], esi
mov dword [ebp - 0x300], eax
call fcn.0040c73f
test al, al
je 0x41fcdb
call fcn.0040d4ce
cmp dword [eax], 5
jge 0x41fcdb
push 0x57
pop eax
jmp 0x41fedd
push esi
mov esi, dword [sym.imp.mozglue.dll__wcsdup]
call esi
pop ecx
push eax
lea ecx, [ebx + 0x30]
call fcn.0040e5b0
push edi
call esi
mov esi, eax
mov edi, 0x40c
mov eax, dword [ebp - 0x2f8]
pop ecx
mov ecx, 0x8040c
mov dword [ebp - 0x2fc], esi
cmp dword [eax + 0x44], 0
cmovne edi, ecx
cmp dword [ebx + 0x20], 0
mov dword [ebp - 0x2e0], edi
je 0x41fd33
call fcn.0040d4ce
cmp dword [eax], 5
jge 0x41fd33
or edi, 0x1000000
mov dword [ebp - 0x2e0], edi
xor eax, eax
lea edi, [ebp - 0x31c]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
lea eax, [ebp - 0x31c]
mov edi, dword [ebp - 0x2e4]
push eax
push dword [ebp - 0x2f8]
movzx eax, byte [ebp + 0x10]
push 0
push 0
push dword [ebp - 0x2e0]
push eax
push 0
push 0
push esi
push edi
push dword [ebx + 0x10]
call dword [sym.imp.ADVAPI32.dll_CreateProcessAsUserW]
test eax, eax
jne 0x41fd81
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
jmp 0x41fece
lea eax, [ebp - 0x31c]
push eax
lea ecx, [ebp - 0x2f4]
call fcn.0040cf7c
cmp dword [ebx + 0x20], 0
je 0x41fdac
push dword [ebp - 0x2f4]
push dword [ebx + 0x20]
call dword [sym.imp.KERNEL32.dll_AssignProcessToJobObject]
test eax, eax
je 0x41fe1b
mov ecx, dword [ebx + 0x14]
call fcn.0040c73f
test al, al
je 0x41fdde
mov eax, dword [ebp - 0x2f0]
mov dword [ebp - 0x2e4], eax
lea eax, [ebp - 0x2e4]
push ecx
push eax
call dword [sym.imp.ADVAPI32.dll_SetThreadToken]
test eax, eax
je 0x41fe1b
lea ecx, [ebx + 0x14]
call fcn.00405515
lea eax, [ebp - 0x2dc]
mov dword [ebp - 0x2dc], 0x1003f
push eax
push dword [ebp - 0x2f0]
call dword [sym.imp.KERNEL32.dll_GetThreadContext]
test eax, eax
je 0x41fe1b
mov ecx, dword [ebp - 0x300]
lea eax, [ebp - 0x2f4]
mov esi, dword [ebp - 0x22c]
push eax
call fcn.0040d0a4
test al, al
jne 0x41fe36
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0
push dword [ebp - 0x2f4]
mov esi, eax
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
jmp 0x41fec3
mov ecx, dword [ebx + 0x18]
call fcn.0040c73f
test al, al
je 0x41fe9b
mov eax, dword [ebp - 0x2f0]
lea edx, [ebp - 0x2e0]
and dword [ebp - 0x2e0], 0
mov dword [ebp - 0x304], ecx
mov ecx, str.NtSetInformationProcess
mov dword [ebp - 0x300], eax
call fcn.00420e77
push 8
lea eax, [ebp - 0x304]
push eax
push 9
push dword [ebp - 0x2f4]
call dword [ebp - 0x2e0]
test eax, eax
jns 0x41fe9b
push 0
push dword [ebp - 0x2f4]
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
mov esi, 0x13b
jmp 0x41fec3
mov edx, esi
mov ecx, edi
call fcn.0041fef0
mov dword [ebx + 0x2c], eax
lea ecx, [ebp - 0x2f4]
lea eax, [ebp - 0x30c]
push eax
call fcn.0040d16f
push eax
mov ecx, ebx
call fcn.0040d102
xor esi, esi
lea ecx, [ebp - 0x2f4]
call fcn.0040cfae
push 0
lea ecx, [ebp - 0x2fc]
call fcn.0040e5b0
mov eax, esi
mov ecx, dword [ebp - 8]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00405ef7
mov esp, ebp
pop ebp
ret 0x14