Function at 0x412c7c
Capabilities:
Set current directory
Set environment variable

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffeb8
mov eax, 0x4e95c4
call fcn.004ccad8
mov dword [ebp - 0x128], 7
lea edx, [ebp + 0x28]
lea eax, [ebp + 0x28]
call fcn.004d9c5c
inc dword [ebp - 0x128]
mov word [ebp - 0x134], 0xc
lea edx, [ebp + 0x24]
lea eax, [ebp + 0x24]
call fcn.004d9c5c
inc dword [ebp - 0x128]
lea edx, [ebp + 0x20]
lea eax, [ebp + 0x20]
call fcn.004d9c5c
inc dword [ebp - 0x128]
lea edx, [ebp + 0x1c]
lea eax, [ebp + 0x1c]
call fcn.004d9c5c
inc dword [ebp - 0x128]
lea edx, [ebp + 0x18]
lea eax, [ebp + 0x18]
call fcn.004d9c5c
inc dword [ebp - 0x128]
lea edx, [ebp + 0x10]
lea eax, [ebp + 0x10]
call fcn.004d9c5c
inc dword [ebp - 0x128]
lea edx, [ebp + 0xc]
lea eax, [ebp + 0xc]
call fcn.004d9c5c
inc dword [ebp - 0x128]
mov word [ebp - 0x134], 0x18
lea edx, [ebp - 0x20]
push edx
call fcn.00407b7c
pop ecx
add dword [ebp - 0x128], 2
mov word [ebp - 0x134], 0xc
mov word [ebp - 0x134], 0x24
lea eax, [ebp - 0x2c]
call fcn.00401cac
mov edx, eax
inc dword [ebp - 0x128]
mov ecx, dword [0x4f4180]
mov eax, dword [ecx]
call fcn.00467f0c
lea edx, [ebp - 0x2c]
push dword [edx]
lea eax, [ebp - 0x30]
call fcn.00401cac
mov edx, eax
inc dword [ebp - 0x128]
pop eax
call fcn.004a746c
lea eax, [ebp - 0x30]
call fcn.00406774
push eax
call sub.KERNEL32.DLL_SetCurrentDirectoryA
dec dword [ebp - 0x128]
lea eax, [ebp - 0x30]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x2c]
mov edx, 2
call fcn.004d9dc0
mov word [ebp - 0x134], 0x30
push 1
push dword [ebp + 0x18]
push dword [ebp + 8]
lea eax, [ebp - 0x34]
call fcn.00401cac
push eax
inc dword [ebp - 0x128]
call fcn.0041227c
add esp, 0x10
lea edx, [ebp - 0x34]
lea eax, [ebp + 0x18]
call fcn.004d9df0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x34]
mov edx, 2
call fcn.004d9dc0
mov word [ebp - 0x134], 0x3c
lea eax, [ebp - 0x24]
call fcn.00401cac
inc dword [ebp - 0x128]
mov word [ebp - 0x134], 0xc
mov word [ebp - 0x134], 0x48
mov edx, 0x4e8999
lea eax, [ebp - 0x28]
call fcn.004d9c24
inc dword [ebp - 0x128]
mov word [ebp - 0x134], 0xc
cmp byte [ebp + 0x14], 0
je 0x412e7c
mov word [ebp - 0x134], 0x54
mov edx, 0x4e899c
lea eax, [ebp - 0x38]
call fcn.004d9c24
inc dword [ebp - 0x128]
lea edx, [ebp - 0x38]
lea eax, [ebp - 0x28]
call fcn.004d9df0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x38]
mov edx, 2
call fcn.004d9dc0
mov word [ebp - 0x134], 0x60
lea eax, [ebp - 0x3c]
xor edx, edx
call fcn.004d9d7c
inc dword [ebp - 0x128]
lea edx, [ebp - 0x3c]
lea eax, [ebp + 0x24]
call fcn.004d9ebc
test al, al
je 0x412ee5
lea eax, [ebp - 0x40]
call fcn.00401cac
mov edx, eax
inc dword [ebp - 0x128]
lea eax, [ebp + 0x24]
call fcn.004da040
lea eax, [ebp - 0x40]
call fcn.00405440
test eax, eax
setg dl
and edx, 1
push edx
dec dword [ebp - 0x128]
lea eax, [ebp - 0x40]
mov edx, 2
call fcn.004d9dc0
pop ecx
test ecx, ecx
jne 0x412ee9
xor eax, eax
jmp 0x412eee
mov eax, 1
push eax
dec dword [ebp - 0x128]
lea eax, [ebp - 0x3c]
mov edx, 2
call fcn.004d9dc0
pop ecx
test cl, cl
je 0x412fa2
mov word [ebp - 0x134], 0x6c
lea eax, [ebp - 0x44]
call fcn.00401cac
mov edx, eax
inc dword [ebp - 0x128]
lea eax, [ebp + 0x24]
call fcn.004da040
lea edx, [ebp - 0x44]
push edx
lea eax, [ebp - 0x4c]
call fcn.00401cac
push eax
inc dword [ebp - 0x128]
mov edx, 0x4e899e
lea eax, [ebp - 0x48]
call fcn.004d9c24
inc dword [ebp - 0x128]
lea edx, [ebp - 0x48]
pop ecx
pop eax
call fcn.004d9e18
lea edx, [ebp - 0x4c]
lea eax, [ebp + 0x24]
call fcn.004d9df0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x4c]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x48]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x44]
mov edx, 2
call fcn.004d9dc0
jmp 0x412fdc
mov word [ebp - 0x134], 0x78
mov edx, 0x4e89a0
lea eax, [ebp - 0x50]
call fcn.004d9c24
inc dword [ebp - 0x128]
lea edx, [ebp - 0x50]
lea eax, [ebp + 0x24]
call fcn.004d9df0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x50]
mov edx, 2
call fcn.004d9dc0
cmp byte [ebp + 0x38], 0
je 0x4132c2
mov word [ebp - 0x134], 0x84
lea eax, [ebp - 0x54]
call fcn.00401cac
mov ecx, eax
inc dword [ebp - 0x128]
lea edx, [ebp + 0x10]
mov eax, 0x4e89a1
call fcn.004da1b0
lea edx, [ebp - 0x54]
push edx
lea eax, [ebp - 0x5c]
call fcn.00401cac
push eax
inc dword [ebp - 0x128]
mov edx, 0x4e89ac
lea eax, [ebp - 0x58]
call fcn.004d9c24
inc dword [ebp - 0x128]
lea edx, [ebp - 0x58]
pop ecx
pop eax
call fcn.004d9e18
lea edx, [ebp - 0x5c]
push edx
lea eax, [ebp - 0x60]
call fcn.00401cac
mov ecx, eax
inc dword [ebp - 0x128]
lea edx, [ebp + 0x24]
pop eax
call fcn.004d9e18
lea edx, [ebp - 0x60]
push edx
lea eax, [ebp - 0x64]
call fcn.00401cac
mov ecx, eax
inc dword [ebp - 0x128]
lea edx, [ebp + 0xc]
pop eax
call fcn.004d9e18
lea edx, [ebp - 0x64]
push edx
lea eax, [ebp - 0x68]
call fcn.00401cac
mov ecx, eax
inc dword [ebp - 0x128]
lea edx, [ebp - 0x28]
pop eax
call fcn.004d9e18
lea edx, [ebp - 0x68]
push edx
lea eax, [ebp - 0x6c]
call fcn.00401cac
mov ecx, eax
inc dword [ebp - 0x128]
lea edx, [ebp + 0x1c]
pop eax
call fcn.004d9e18
lea edx, [ebp - 0x6c]
push edx
lea eax, [ebp - 0x74]
call fcn.00401cac
push eax
inc dword [ebp - 0x128]
mov edx, 0x4e89af
lea eax, [ebp - 0x70]
call fcn.004d9c24
inc dword [ebp - 0x128]
lea edx, [ebp - 0x70]
pop ecx
pop eax
call fcn.004d9e18
lea edx, [ebp - 0x74]
push edx
lea eax, [ebp - 0x78]
call fcn.00401cac
mov ecx, eax
inc dword [ebp - 0x128]
lea edx, [ebp + 0x20]
pop eax
call fcn.004d9e18
lea edx, [ebp - 0x78]
push edx
lea eax, [ebp - 0x80]
call fcn.00401cac
push eax
inc dword [ebp - 0x128]
mov edx, 0x4e89b1
lea eax, [ebp - 0x7c]
call fcn.004d9c24
inc dword [ebp - 0x128]
lea edx, [ebp - 0x7c]
pop ecx
pop eax
call fcn.004d9e18
lea edx, [ebp - 0x80]
push edx
lea eax, [ebp - 0x84]
call fcn.00401cac
mov ecx, eax
inc dword [ebp - 0x128]
lea edx, [ebp + 0x18]
pop eax
call fcn.004d9e18
lea edx, [ebp - 0x84]
push edx
lea eax, [ebp - 0x8c]
call fcn.00401cac
push eax
inc dword [ebp - 0x128]
mov edx, 0x4e89b5
lea eax, [ebp - 0x88]
call fcn.004d9c24
inc dword [ebp - 0x128]
lea edx, [ebp - 0x88]
pop ecx
pop eax
call fcn.004d9e18
lea edx, [ebp - 0x8c]
lea eax, [ebp - 0x24]
call fcn.004d9df0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x8c]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x88]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x84]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x80]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x7c]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x78]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x74]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x70]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x6c]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x68]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x64]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x60]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x5c]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x58]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x54]
mov edx, 2
call fcn.004d9dc0
jmp 0x413605
mov word [ebp - 0x134], 0x90
lea eax, [ebp - 0x90]
call fcn.00401cac
mov ecx, eax
inc dword [ebp - 0x128]
lea edx, [ebp + 0x10]
mov eax, 0x4e89b7
call fcn.004da1b0
lea edx, [ebp - 0x90]
push edx
lea eax, [ebp - 0x98]
call fcn.00401cac
push eax
inc dword [ebp - 0x128]
mov edx, 0x4e89c2
lea eax, [ebp - 0x94]
call fcn.004d9c24
inc dword [ebp - 0x128]
lea edx, [ebp - 0x94]
pop ecx
pop eax
call fcn.004d9e18
lea edx, [ebp - 0x98]
push edx
lea eax, [ebp - 0x9c]
call fcn.00401cac
mov ecx, eax
inc dword [ebp - 0x128]
lea edx, [ebp + 0x18]
pop eax
call fcn.004d9e18
lea edx, [ebp - 0x9c]
push edx
lea eax, [ebp - 0xa4]
call fcn.00401cac
push eax
inc dword [ebp - 0x128]
mov edx, 0x4e89c5
lea eax, [ebp - 0xa0]
call fcn.004d9c24
inc dword [ebp - 0x128]
lea edx, [ebp - 0xa0]
pop ecx
pop eax
call fcn.004d9e18
lea edx, [ebp - 0xa4]
push edx
lea eax, [ebp - 0xa8]
call fcn.00401cac
mov ecx, eax
inc dword [ebp - 0x128]
lea edx, [ebp + 0x24]
pop eax
call fcn.004d9e18
lea edx, [ebp - 0xa8]
push edx
lea eax, [ebp - 0xac]
call fcn.00401cac
mov ecx, eax
inc dword [ebp - 0x128]
lea edx, [ebp + 0xc]
pop eax
call fcn.004d9e18
lea edx, [ebp - 0xac]
push edx
lea eax, [ebp - 0xb0]
call fcn.00401cac
mov ecx, eax
inc dword [ebp - 0x128]
lea edx, [ebp - 0x28]
pop eax
call fcn.004d9e18
lea edx, [ebp - 0xb0]
push edx
lea eax, [ebp - 0xb4]
call fcn.00401cac
mov ecx, eax
inc dword [ebp - 0x128]
lea edx, [ebp + 0x1c]
pop eax
call fcn.004d9e18
lea edx, [ebp - 0xb4]
push edx
lea eax, [ebp - 0xbc]
call fcn.00401cac
push eax
inc dword [ebp - 0x128]
mov edx, 0x4e89c9
lea eax, [ebp - 0xb8]
call fcn.004d9c24
inc dword [ebp - 0x128]
lea edx, [ebp - 0xb8]
pop ecx
pop eax
call fcn.004d9e18
lea edx, [ebp - 0xbc]
push edx
lea eax, [ebp - 0xc0]
call fcn.00401cac
mov ecx, eax
inc dword [ebp - 0x128]
lea edx, [ebp + 0x20]
pop eax
call fcn.004d9e18
lea edx, [ebp - 0xc0]
push edx
lea eax, [ebp - 0xc8]
call fcn.00401cac
push eax
inc dword [ebp - 0x128]
mov edx, 0x4e89cb
lea eax, [ebp - 0xc4]
call fcn.004d9c24
inc dword [ebp - 0x128]
lea edx, [ebp - 0xc4]
pop ecx
pop eax
call fcn.004d9e18
lea edx, [ebp - 0xc8]
lea eax, [ebp - 0x24]
call fcn.004d9df0
dec dword [ebp - 0x128]
lea eax, [ebp - 0xc8]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0xc4]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0xc0]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0xbc]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0xb8]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0xb4]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0xb0]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0xac]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0xa8]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0xa4]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0xa0]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x9c]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x98]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x94]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x90]
mov edx, 2
call fcn.004d9dc0
lea eax, [ebp + 0x28]
call fcn.00405440
test eax, eax
jle 0x413624
lea eax, [ebp + 0x28]
call fcn.00406774
push eax
push 0x4e89cd
call sub.KERNEL32.DLL_SetEnvironmentVariableA
cmp dword [ebp + 0x30], 0
je 0x4136f9
mov word [ebp - 0x134], 0xa8
lea eax, [ebp - 0xcc]
call fcn.00401cac
mov ecx, eax
inc dword [ebp - 0x128]
lea edx, [ebp - 0x24]
mov eax, 0x4e89dc
call fcn.004da1b0
mov word [ebp - 0x134], 0x9c
mov word [ebp - 0x134], 0xb4
lea eax, [ebp - 0xcc]
call fcn.00406774
push eax
lea edx, [ebp - 0xf4]
push edx
call fcn.0040a0a8
add esp, 8
inc dword [ebp - 0x128]
lea ecx, [ebp - 0xf4]
push ecx
push dword [ebp + 0x2c]
call fcn.0040da94
add esp, 8
dec dword [ebp - 0x128]
push 2
lea eax, [ebp - 0xf4]
push eax
call fcn.0040a104
add esp, 8
push 0
push dword [ebp + 0x2c]
call fcn.00404138
pop ecx
dec eax
push eax
push 0x7e8
push dword [ebp + 0x30]
call sub.USER32.DLL_SendMessageA
mov edx, dword [0x4f4180]
mov eax, dword [edx]
call fcn.004674a0
dec dword [ebp - 0x128]
lea eax, [ebp - 0xcc]
mov edx, 2
call fcn.004d9dc0
mov word [ebp - 0x134], 0xc
cmp byte [ebp + 0x34], 0
je 0x4137e0
mov eax, 1
push eax
dec dword [ebp - 0x128]
lea eax, [ebp - 0x28]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x24]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
dec dword [ebp - 0x128]
lea eax, [ebp - 8]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp + 0xc]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp + 0x10]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp + 0x18]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp + 0x1c]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp + 0x20]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp + 0x24]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp + 0x28]
mov edx, 2
call fcn.004d9dc0
pop eax
mov edx, dword [ebp - 0x144]
mov dword fs:[0], edx
jmp 0x413aa9
push dword [ebp + 0x30]
push dword [ebp + 0x2c]
push dword [ebp - 0x24]
lea ecx, [ebp - 0x20]
push ecx
call fcn.0040dafc
add esp, 0x10
test al, al
je 0x4139d1
lea eax, [ebp - 0x20]
push eax
call fcn.00413ab0
pop ecx
mov dword [ebp - 0x148], eax
mov word [ebp - 0x134], 0xc
cmp dword [ebp - 0x148], 0
jbe 0x4139d1
mov word [ebp - 0x134], 0xcc
push dword [ebp - 0x148]
push dword [ebp + 8]
lea eax, [ebp - 0xf8]
call fcn.00401cac
push eax
inc dword [ebp - 0x128]
call fcn.00412550
add esp, 0xc
mov word [ebp - 0x134], 0xc0
mov word [ebp - 0x134], 0xd8
lea eax, [ebp - 0xf8]
call fcn.00406774
push eax
lea edx, [ebp - 0x120]
push edx
call fcn.0040a0a8
add esp, 8
inc dword [ebp - 0x128]
lea ecx, [ebp - 0x120]
push ecx
push dword [ebp + 0x2c]
call fcn.0040da94
add esp, 8
dec dword [ebp - 0x128]
push 2
lea eax, [ebp - 0x120]
push eax
call fcn.0040a104
add esp, 8
cmp dword [ebp + 0x30], 0
je 0x4138d8
push 0
push dword [ebp + 0x2c]
call fcn.00404138
pop ecx
dec eax
push eax
push 0x7e8
push dword [ebp + 0x30]
call sub.USER32.DLL_SendMessageA
mov edx, dword [0x4f4180]
mov eax, dword [edx]
call fcn.004674a0
xor eax, eax
push eax
dec dword [ebp - 0x128]
lea eax, [ebp - 0xf8]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x28]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x24]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
dec dword [ebp - 0x128]
lea eax, [ebp - 8]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp + 0xc]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp + 0x10]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp + 0x18]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp + 0x1c]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp + 0x20]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp + 0x24]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp + 0x28]
mov edx, 2
call fcn.004d9dc0
pop eax
mov edx, dword [ebp - 0x144]
mov dword fs:[0], edx
jmp 0x413aa9
mov eax, 1
push eax
dec dword [ebp - 0x128]
lea eax, [ebp - 0x28]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp - 0x24]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
dec dword [ebp - 0x128]
lea eax, [ebp - 8]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp + 0xc]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp + 0x10]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp + 0x18]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp + 0x1c]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp + 0x20]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp + 0x24]
mov edx, 2
call fcn.004d9dc0
dec dword [ebp - 0x128]
lea eax, [ebp + 0x28]
mov edx, 2
call fcn.004d9dc0
pop eax
mov edx, dword [ebp - 0x144]
mov dword fs:[0], edx
mov esp, ebp
pop ebp
ret