Function at 0x407300
Capabilities:
Create process on windows
Get common file path
Set current directory
Terminate process

Disassembly:
mov eax, 0x4654
call fcn.0040e130
mov eax, dword [esp + 0x4664]
mov dword [esp + 4], ecx
mov ecx, 1
cmp eax, ecx
mov dword [esp + 8], 0xffffffff
mov dword [esp + 0xc], ecx
mov dword [esp], ecx
jl 0x407330
mov dword [esp], eax
push ebx
push ebp
push esi
push edi
lea eax, [esp + 0x664]
push eax
push 0x400
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
mov esi, dword [esp + 0x4678]
mov edi, dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov ebp, dword [sym.imp.KERNEL32.dll_FindClose]
lea ebx, [ebx]
mov ecx, dword [esp + 0x466c]
push ecx
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
test eax, eax
je 0x4073a2
mov eax, dword [esp + 0x4668]
lea edx, [esp + 0x124]
push edx
push eax
xor bl, bl
call edi
cmp eax, 0xffffffff
je 0x4073a2
test byte [esp + 0x124], 0x10
jne 0x407397
mov bl, 1
push eax
call ebp
test bl, bl
jne 0x407440
push 0x400
lea ecx, [esp + 0x1a68]
push ecx
push 0x2f
call fcn.00402870
lea edx, [esp + 0x2c]
push edx
call fcn.00402100
movsx eax, byte [esp + 0x30]
push eax
push esi
lea ecx, [esp + 0x1a7c]
push ecx
lea edx, [esp + 0x280]
push edx
call fcn.0040e8d4
add esp, 0x20
push 1
push 0x42ddd2
lea eax, [esp + 0x26c]
push eax
push 0
call dword [0x43c2f8]
cmp eax, 2
jne 0x407360
push 0x400
lea ecx, [esp + 0x268]
push ecx
push 0x2e
call fcn.00402870
add esp, 0xc
push 0x124
push 0x42ddd2
lea edx, [esp + 0x26c]
push edx
push 0
call dword [0x43c2f8]
cmp eax, 6
jne 0x407360
push 0
call fcn.0040e894
mov eax, dword [esp + 0x4668]
push eax
lea ecx, [esp + 0xa68]
push str.__s_
push ecx
call fcn.0040e8d4
mov eax, dword [esp + 0x467c]
add esp, 0xc
mov edi, 0x42ddd2
mov esi, eax
mov ecx, 1
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
je 0x4074bd
lea edi, [esp + 0xa64]
dec edi
mov edi, edi
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x407480
mov cx, word [0x42e2ec]
mov word [edi], cx
mov edx, eax
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x407494
lea edi, [esp + 0xa64]
sub eax, edx
dec edi
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x4074a5
mov ecx, eax
shr ecx, 2
mov esi, edx
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edx, dword [esp + 0x14]
cmp byte [edx], 0
je 0x4074dd
push 0
push str.CreateProcess
lea eax, [esp + 0xa6c]
push eax
push 0
call dword [0x43c2f8]
mov edi, dword [esp + 0x10]
test edi, edi
jle 0x4075b5
mov ebp, dword [sym.imp.KERNEL32.dll_CreateProcessA]
mov ebx, dword [sym.imp.KERNEL32.dll_Sleep]
mov esi, dword [esp + 0x4674]
test esi, esi
je 0x407501
dec edi
push 0
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov eax, dword [esp + 0x1c]
test eax, eax
je 0x4075ad
mov edx, dword [esp + 0x4668]
push 0x440b54
push 0x440b10
push 0
push 0
push 0x30
push 0
push 0
push 0
lea ecx, [esp + 0xa84]
push ecx
push edx
call ebp
test eax, eax
je 0x407597
mov edi, esi
mov dword [esp + 0x10], edi
jmp 0x407550
mov ecx, dword [0x440b54]
lea eax, [esp + 0x18]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
test eax, eax
je 0x4075d4
mov eax, dword [esp + 0x1c]
test eax, eax
je 0x407576
mov dword [esp + 0x1c], 0
push 1
call ebx
test esi, esi
je 0x407587
dec edi
test edi, edi
mov dword [esp + 0x10], edi
jle 0x4075b5
cmp dword [esp + 0x18], 0x103
je 0x407550
mov edi, dword [esp + 0x10]
jmp 0x4075ad
cmp edi, 1
jl 0x4075de
test esi, esi
jne 0x4075a9
mov edx, dword [esp + 0x14]
cmp byte [edx], 0
jne 0x4075de
push 1
call ebx
test edi, edi
jg 0x4074f5
lea eax, [esp + 0x664]
push eax
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
mov eax, dword [esp + 0x18]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x4654
ret 0x14
mov dword [esp + 0x18], 0
jmp 0x4075b5
push 0
push 0
lea eax, [esp + 0x1c]
push eax
push 0x400
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0
push 0x1300
call dword [sym.imp.KERNEL32.dll_FormatMessageA]
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0x4668]
push ecx
push edx
lea eax, [esp + 0x1e6c]
push str.Error_executing__s_n_s
push eax
call fcn.0040e8d4
add esp, 0x10
push 0x40
push str.Exec_And_Wait
lea ecx, [esp + 0x1e6c]
push ecx
push 0
call dword [0x43c2f8]
mov edx, dword [esp + 0x14]
push edx
call dword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x4075b5