Function at 0x10004260
Capabilities:
Set environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x35ec
call fcn.10009390
mov eax, dword [0x10013568]
xor eax, ebp
mov dword [ebp - 0xc], eax
cmp dword [ebp + 0xc], 0
je 0x10004285
cmp dword [ebp + 0x14], 0
jne 0x10004291
push 0x57
call fcn.10007fa0
jmp 0x100047b0
mov eax, dword [ebp + 0x14]
mov byte [eax], 0
mov ecx, dword [ebp + 0xc]
mov dword [ebp - 0xa74], ecx
mov edx, dword [ebp - 0xa74]
cmp dword [edx], 0x31305350
je 0x100042ba
push 0x57
call fcn.10007fa0
jmp 0x100047b0
mov eax, dword [ebp + 8]
push eax
call fcn.10007fa0
mov dword [ebp - 0x35e4], eax
cmp dword [ebp - 0x35e4], 0
jne 0x100042de
push 6
call fcn.10007fa0
jmp 0x100047b0
push 1
push 0
push 0
mov ecx, dword [ebp - 0x35e4]
add ecx, 0x28
push ecx
call fcn.10007fa0
test eax, eax
jne 0x100042fe
xor eax, eax
jmp 0x100047b0
mov dword [ebp - 0x32a8], 0x3c
lea edx, [ebp - 0x35e0]
mov dword [ebp - 0x3268], edx
lea eax, [ebp - 0x32a8]
push eax
mov ecx, dword [ebp - 0xa74]
push ecx
call fcn.10007fa0
push 0x105
lea edx, [ebp - 0x3400]
push edx
mov eax, dword [ebp + 0x10]
push eax
call fcn.10007fa0
test eax, eax
je 0x1000435a
lea ecx, [ebp - 0x3400]
push ecx
push 0x100011e8
lea edx, [ebp - 0x32a8]
push edx
call fcn.10007fa0
jmp 0x10004375
mov eax, dword [ebp - 0x35e4]
add eax, 0x28
push eax
push 0x100011e8
lea ecx, [ebp - 0x32a8]
push ecx
call fcn.10007fa0
push 0x100013e0
lea edx, [ebp - 0x32a8]
push edx
mov eax, dword [ebp - 0x35e4]
push eax
call fcn.10007fa0
mov dword [ebp - 0x73c], eax
cmp dword [ebp - 0x73c], 0
je 0x100043eb
mov ecx, dword [ebp - 0x73c]
push ecx
call dword [sym.imp.msvcrt.dll_atoi]
add esp, 4
mov dword [ebp - 0x84c], eax
cmp dword [ebp - 0x84c], 3
jle 0x100043eb
mov edx, dword [0x100138a0]
and edx, 1
je 0x100043dc
push 3
mov eax, dword [ebp - 0x84c]
push eax
push 0x100013a0
call fcn.10007fa0
add esp, 0xc
push 0x51a
call fcn.10007fa0
jmp 0x100047b0
lea edx, [ebp - 0x32a8]
push edx
mov eax, dword [ebp - 0x35e4]
push eax
call fcn.10007fa0
test eax, eax
je 0x1000440e
push 0x37
call fcn.10007fa0
jmp 0x100047b0
push 0x10001390
lea ecx, [ebp - 0x32a8]
push ecx
mov edx, dword [ebp - 0x35e4]
push edx
call fcn.10007fa0
mov dword [ebp - 0x32f8], eax
cmp dword [ebp - 0x32f8], 0
jne 0x10004444
push 0x490
call fcn.10007fa0
jmp 0x100047b0
mov eax, dword [ebp + 0x18]
push eax
mov ecx, dword [ebp + 0x14]
push ecx
mov edx, dword [ebp - 0x32f8]
push edx
lea eax, [ebp - 0x32a8]
push eax
mov ecx, dword [ebp - 0x35e4]
push ecx
call fcn.10007fa0
push 7
push 0x10001388
mov edx, dword [ebp + 0x14]
push edx
call dword [sym.imp.msvcrt.dll__strnicmp]
add esp, 0xc
test eax, eax
je 0x10004496
push 8
push 0x1000137c
mov eax, dword [ebp + 0x14]
push eax
call dword [sym.imp.msvcrt.dll__strnicmp]
add esp, 0xc
test eax, eax
jne 0x100044a0
mov eax, 1
jmp 0x100047b0
mov ecx, dword [ebp + 0x14]
push ecx
call fcn.10007fa0
test eax, eax
je 0x100044d4
push 0
lea edx, [ebp - 0x32a8]
push edx
mov eax, dword [ebp + 0x18]
push eax
mov ecx, dword [ebp + 0x14]
push ecx
mov edx, dword [ebp - 0x35e4]
push edx
call fcn.10007fa0
mov eax, 1
jmp 0x100047b0
mov eax, dword [ebp + 0x14]
push eax
call fcn.10007fa0
test eax, eax
je 0x100044e8
xor eax, eax
jmp 0x100047b0
mov byte [ebp - 0x968], 0
push 0
push 0x105
lea ecx, [ebp - 0x968]
push ecx
mov edx, dword [ebp + 0x14]
push edx
call fcn.10007fa0
test eax, eax
jne 0x10004516
push 0x52
call fcn.10007fa0
jmp 0x100047b0
push 0x10001370
lea eax, [ebp - 0x32a8]
push eax
mov ecx, dword [ebp - 0x35e4]
push ecx
call fcn.10007fa0
mov dword [ebp - 0x32f8], eax
cmp dword [ebp - 0x32f8], 0
jne 0x10004557
lea edx, [ebp - 0x968]
push edx
mov eax, dword [ebp + 0x14]
push eax
push 0x490
call fcn.10007fa0
jmp 0x100047b0
push 0x30d
lea ecx, [ebp - 0x428]
push ecx
mov edx, dword [ebp - 0x32f8]
push edx
lea eax, [ebp - 0x32a8]
push eax
mov ecx, dword [ebp - 0x35e4]
push ecx
call fcn.10007fa0
mov dword [ebp - 0x740], eax
movsx edx, byte [ebp - 0x428]
test edx, edx
jne 0x100045a5
lea eax, [ebp - 0x968]
push eax
mov ecx, dword [ebp + 0x14]
push ecx
push 0xd
call fcn.10007fa0
jmp 0x100047b0
push 0x10001364
lea edx, [ebp - 0x32a8]
push edx
mov eax, dword [ebp - 0x35e4]
push eax
call fcn.10007fa0
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
je 0x1000466b
push 0x30d
push 0
lea ecx, [ebp - 0x738]
push ecx
call sub.msvcrt.dll_memset
add esp, 0xc
push 0x30d
lea edx, [ebp - 0x738]
push edx
mov eax, dword [ebp - 4]
push eax
lea ecx, [ebp - 0x32a8]
push ecx
mov edx, dword [ebp - 0x35e4]
push edx
call fcn.10007fa0
lea eax, [ebp - 0x738]
push eax
call fcn.10007fa0
lea ecx, [ebp - 0x738]
mov dword [ebp - 4], ecx
mov edx, dword [ebp - 4]
mov dword [ebp - 0x35e8], edx
jmp 0x10004632
mov eax, dword [ebp - 0x35e8]
add eax, 1
mov dword [ebp - 0x35e8], eax
mov ecx, dword [ebp - 0x35e8]
movsx edx, byte [ecx]
cmp edx, 0x3d
je 0x10004642
jmp 0x10004623
mov eax, dword [ebp - 0x35e8]
mov byte [eax], 0
mov ecx, dword [ebp - 0x35e8]
add ecx, 1
mov dword [ebp - 0x35e8], ecx
mov edx, dword [ebp - 0x35e8]
push edx
mov eax, dword [ebp - 4]
push eax
call dword [sym.imp.kernel32.dll_SetEnvironmentVariableA]
cmp dword [ebp - 0x740], 0
jne 0x100046a5
lea ecx, [ebp - 0x428]
push ecx
mov edx, dword [ebp - 0x35e4]
push edx
call fcn.10007fa0
test eax, eax
jne 0x100046a5
lea eax, [ebp - 0x968]
push eax
mov ecx, dword [ebp + 0x14]
push ecx
push 0x4c7
call fcn.10007fa0
jmp 0x100047b0
mov edx, dword [0x100138a0]
and edx, 1
je 0x100046cb
lea eax, [ebp - 0x428]
push eax
push 0x100011e0
mov ecx, dword [ebp - 0x35e4]
push ecx
call fcn.10007fa0
add esp, 0xc
lea ecx, [ebp - 0x3260]
call fcn.10007fa0
push 0
lea eax, [ebp - 0x428]
push eax
lea ecx, [ebp - 0x3260]
call fcn.10007fa0
mov ecx, dword [ebp - 0x35e4]
push ecx
call fcn.10007fa0
mov edx, dword [ebp + 0x14]
push edx
call fcn.10007fa0
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 0
jne 0x10004774
lea eax, [ebp - 0x428]
push eax
lea ecx, [ebp - 0x3260]
call fcn.10007fa0
push eax
lea ecx, [ebp - 0x32a8]
push ecx
mov edx, dword [ebp - 0x35e4]
push edx
call fcn.10007fa0
test eax, eax
je 0x1000473a
push 0x37
call dword [sym.imp.kernel32.dll_SetLastError]
lea eax, [ebp - 0x32a8]
push eax
mov ecx, dword [ebp - 0x35e4]
push ecx
call fcn.10007fa0
test eax, eax
je 0x10004759
push 0x37
call dword [sym.imp.kernel32.dll_SetLastError]
lea edx, [ebp - 0x968]
push edx
mov eax, dword [ebp + 0x14]
push eax
call fcn.10007fa0
mov ecx, dword [ebp + 0x14]
push ecx
call fcn.10007fa0
jmp 0x10004796
lea edx, [ebp - 0x968]
push edx
lea eax, [ebp - 0x32a8]
push eax
mov ecx, dword [ebp + 0x18]
push ecx
mov edx, dword [ebp + 0x14]
push edx
mov eax, dword [ebp - 0x35e4]
push eax
call fcn.10007fa0
mov ecx, dword [ebp - 8]
mov dword [ebp - 0x35ec], ecx
lea ecx, [ebp - 0x3260]
call fcn.10007fa0
mov eax, dword [ebp - 0x35ec]
mov ecx, dword [ebp - 0xc]
xor ecx, ebp
call fcn.1000936d
mov esp, ebp
pop ebp
ret 0x14