Function at 0x429633
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x64
push ebx
push esi
push edi
xor edi, edi
cmp dword [ebp + 8], edi
jne 0x429659
cmp dword [ebp + 0xc], edi
jne 0x429659
call dword [sym.imp.MSVCRT.dll__errno]
mov dword [eax], 0xe
jmp 0x429947
call fcn.00429a9f
cmp eax, edi
mov dword [ebp - 4], eax
jne 0x429676
call dword [sym.imp.MSVCRT.dll__errno]
mov dword [eax], 0xb
jmp 0x429947
cmp dword [ebp + 0x10], edi
jne 0x429692
lea eax, [ebp - 0x10]
mov dword [ebp - 0x10], 0xc
mov dword [ebp - 0xc], edi
mov dword [ebp - 8], 1
mov dword [ebp + 0x10], eax
push 0x44
lea eax, [ebp - 0x64]
pop esi
push esi
push edi
push eax
call sub.MSVCRT.dll_memset
push 0x10
lea eax, [ebp - 0x20]
push edi
push eax
call sub.MSVCRT.dll_memset
mov eax, dword [ebp + 0x14]
mov ebx, dword [ebp + 0x1c]
add esp, 0x18
cmp eax, edi
mov edi, dword [ebp + 0x18]
mov dword [ebp - 0x64], esi
jne 0x4296c7
test edi, edi
jne 0x4296c7
test ebx, ebx
je 0x4296ff
mov esi, dword [sym.imp.KERNEL32.dll_GetStdHandle]
mov dword [ebp - 0x38], pe_nt_image_headers32
test eax, eax
jne 0x4296dc
push 0xfffffffffffffff6
call esi
test edi, edi
mov dword [ebp - 0x2c], eax
je 0x4296e8
mov dword [ebp - 0x28], edi
jmp 0x4296ef
push 0xfffffffffffffff5
call esi
mov dword [ebp - 0x28], eax
test ebx, ebx
je 0x4296f8
mov dword [ebp - 0x24], ebx
jmp 0x4296ff
push 0xfffffffffffffff4
call esi
mov dword [ebp - 0x24], eax
mov esi, dword [ebp + 0xc]
test esi, esi
je 0x429722
push 0
push esi
call sym.ruby187g.exc_dln_find_exe
mov edi, eax
pop ecx
test edi, edi
pop ecx
jne 0x429a31
mov dword [ebp + 0xc], esi
jmp 0x429a29
or dword [ebp + 0x14], 0xffffffff
mov ebx, dword [ebp + 8]
mov al, byte [ebx]
cmp al, 0x80
jae 0x429765
mov ecx, dword [sym.imp.MSVCRT.dll___mb_cur_max]
cmp dword [ecx], 1
jle 0x42974a
movzx eax, al
push 8
push eax
call dword [sym.imp.MSVCRT.dll__isctype]
pop ecx
pop ecx
jmp 0x42975b
mov ecx, dword [sym.imp.MSVCRT.dll__pctype]
movzx eax, al
mov ecx, dword [ecx]
mov al, byte [ecx + eax*2]
and eax, 8
test eax, eax
je 0x429765
inc ebx
mov dword [ebp + 8], ebx
jmp 0x429729
cmp byte [ebx], 0
mov esi, ebx
je 0x429803
mov al, byte [esi]
cmp al, 0x80
jae 0x4297eb
mov ecx, dword [sym.imp.MSVCRT.dll___mb_cur_max]
cmp dword [ecx], 1
jle 0x429791
movzx eax, al
push 8
push eax
call dword [sym.imp.MSVCRT.dll__isctype]
pop ecx
pop ecx
jmp 0x4297a2
mov ecx, dword [sym.imp.MSVCRT.dll__pctype]
movzx eax, al
mov ecx, dword [ecx]
mov al, byte [ecx + eax*2]
and eax, 8
test eax, eax
je 0x4297eb
mov edi, esi
sub edi, ebx
mov al, byte [esi + 1]
inc esi
cmp al, 0x80
jae 0x4297e2
mov ecx, dword [sym.imp.MSVCRT.dll___mb_cur_max]
cmp dword [ecx], 1
jle 0x4297cd
movzx eax, al
push 8
push eax
call dword [sym.imp.MSVCRT.dll__isctype]
pop ecx
pop ecx
jmp 0x4297de
mov ecx, dword [sym.imp.MSVCRT.dll__pctype]
movzx eax, al
mov ecx, dword [ecx]
mov al, byte [ecx + eax*2]
and eax, 8
test eax, eax
jne 0x4297aa
mov al, byte [esi]
dec esi
test al, al
je 0x4297ff
jmp 0x4297ed
xor edi, edi
push esi
call dword [sym.imp.USER32.dll_CharNextA]
mov esi, eax
cmp byte [esi], 0
jne 0x429770
test edi, edi
jne 0x42980c
push ebx
call sub.MSVCRT.dll_strlen
pop ecx
mov edi, eax
push str.RUBYSHELL
call sym.ruby187g.exc_rb_w32_getenv
mov ebx, eax
pop ecx
test ebx, ebx
mov dword [ebp + 0xc], ebx
je 0x429860
push dword [ebp + 8]
call fcn.00429c22
test eax, eax
pop ecx
mov dword [ebp + 0x14], eax
je 0x429860
push ebx
call sub.MSVCRT.dll_strlen
lea eax, [eax + edi + 7]
pop ecx
add eax, 3
and al, 0xfc
call fcn.00467aa0
mov esi, esp
push dword [ebp + 8]
push edi
push ebx
push str._s__c___.s_
push esi
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0x14
jmp 0x4299f7
push str.COMSPEC
call sym.ruby187g.exc_rb_w32_getenv
mov ebx, eax
pop ecx
test ebx, ebx
mov dword [ebp + 0xc], ebx
je 0x42994e
push ebx
call fcn.00429abf
mov esi, eax
mov eax, dword [ebp + 0x14]
neg esi
sbb esi, esi
pop ecx
inc esi
test eax, eax
jge 0x429898
push dword [ebp + 8]
call fcn.00429c22
pop ecx
test eax, eax
jne 0x4298ad
push esi
push dword [ebp + 8]
call fcn.00429aff
pop ecx
test eax, eax
pop ecx
je 0x42994e
push ebx
call sub.MSVCRT.dll_strlen
pop ecx
mov edx, edi
mov ecx, esi
neg ecx
sbb ecx, ecx
add edx, eax
and ecx, 2
lea eax, [ecx + edx + 5]
add eax, 3
and al, 0xfc
call fcn.00467aa0
test esi, esi
mov ebx, esp
mov eax, 0x4833f4
jne 0x4298df
mov eax, str._s__c__.s
push dword [ebp + 8]
push edi
push dword [ebp + 0xc]
push eax
push ebx
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0x14
mov dword [ebp + 8], ebx
call sym.ruby187g.exc_rb_w32_enter_critical
lea eax, [ebp - 0x20]
xor edi, edi
push eax
lea eax, [ebp - 0x64]
push eax
mov eax, dword [ebp + 0x10]
push edi
push edi
push 0x20
push dword [eax + 8]
push eax
push eax
push dword [ebp + 8]
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
mov esi, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call sym.ruby187g.exc_rb_w32_map_errno
pop ecx
mov ebx, eax
call dword [sym.imp.MSVCRT.dll__errno]
mov dword [eax], ebx
call sym.ruby187g.exc_rb_w32_leave_critical
cmp esi, edi
jne 0x429a6c
mov eax, dword [ebp - 4]
mov dword [eax + 4], edi
xor eax, eax
jmp 0x429a97
mov esi, dword [ebp + 8]
and dword [ebp + 0xc], 0
mov ebx, esi
cmp byte [ebx], 0
je 0x4299c1
movsx eax, byte [esi]
push eax
push str..:____
call dword [sym.imp.MSVCRT.dll_strchr]
pop ecx
test eax, eax
pop ecx
jne 0x4299cd
mov al, byte [esi]
cmp al, 0x80
jae 0x4299a7
mov ecx, dword [sym.imp.MSVCRT.dll___mb_cur_max]
cmp dword [ecx], 1
jle 0x429992
movzx eax, al
push 8
push eax
call dword [sym.imp.MSVCRT.dll__isctype]
pop ecx
pop ecx
jmp 0x4299a3
mov ecx, dword [sym.imp.MSVCRT.dll__pctype]
movzx eax, al
mov ecx, dword [ecx]
mov al, byte [ecx + eax*2]
and eax, 8
test eax, eax
jne 0x4299ff
movsx eax, byte [esi]
push eax
push 0x4833dc
call dword [sym.imp.MSVCRT.dll_strchr]
pop ecx
test eax, eax
pop ecx
jne 0x4299ff
inc esi
cmp byte [esi], al
jne 0x42995c
push 0
push ebx
call sym.ruby187g.exc_dln_find_exe
pop ecx
pop ecx
jmp 0x429a27
cmp byte [edi + ebx], 0
je 0x4298f4
lea eax, [edi + 1]
add eax, 3
and al, 0xfc
call fcn.00467aa0
mov esi, esp
push edi
push dword [ebp + 8]
push esi
call sub.MSVCRT.dll_memcpy
add esp, 0xc
and byte [esi + edi], 0
mov dword [ebp + 8], esi
jmp 0x4298f4
sub esi, ebx
lea eax, [esi + 1]
add eax, 3
and al, 0xfc
call fcn.00467aa0
mov edi, esp
push esi
push ebx
push edi
call sub.MSVCRT.dll_memcpy
and byte [esi + edi], 0
push 0
push edi
call sym.ruby187g.exc_dln_find_exe
add esp, 0x14
mov edi, eax
test edi, edi
je 0x4298f4
push edi
call sub.MSVCRT.dll_strlen
add eax, 4
pop ecx
and al, 0xfc
call fcn.00467aa0
mov esi, esp
push edi
push esi
call sub.MSVCRT.dll_strcpy
pop ecx
mov dword [ebp + 0xc], esi
pop ecx
mov al, byte [esi]
test al, al
je 0x4298f4
cmp al, 0x2f
jne 0x429a61
mov byte [esi], 0x5c
push esi
call dword [sym.imp.USER32.dll_CharNextA]
mov esi, eax
jmp 0x429a50
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov esi, dword [ebp - 4]
mov eax, dword [ebp - 0x20]
mov dword [esi], eax
mov eax, dword [ebp - 0x18]
mov dword [esi + 4], eax
call sym.ruby187g.exc_rb_w32_osid
cmp eax, 2
je 0x429a95
mov eax, dword [esi + 4]
neg eax
mov dword [esi + 4], eax
mov eax, esi
lea esp, [ebp - 0x70]
pop edi
pop esi
pop ebx
leave
ret