Function at 0x7e76a0
Capabilities:
Set environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
push esi
mov dword [ebp - 0x10], 0
mov dword [ebp - 0x14], 0
cmp dword [ebp + 8], 0
jne 0x7e76e5
xor eax, eax
jne 0x7e76dd
push str.FALSE
push 0
push 0x5a
push str.setenv.c
push 2
call fcn.007d2670
add esp, 0x14
cmp eax, 1
jne 0x7e76dd
int3
or eax, 0xffffffff
jmp 0x7e7a14
mov edx, dword [ebp + 8]
mov eax, dword [edx]
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
je 0x7e7712
push 0x3d
mov ecx, dword [ebp - 0x14]
push ecx
call fcn.007e7b90
add esp, 8
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0x20], 0
je 0x7e7712
mov edx, dword [ebp - 0x14]
cmp edx, dword [ebp - 0x20]
jne 0x7e771a
or eax, 0xffffffff
jmp 0x7e7a14
mov eax, dword [ebp - 0x20]
movsx ecx, byte [eax + 1]
neg ecx
sbb ecx, ecx
inc ecx
mov dword [ebp - 0x1c], ecx
mov edx, dword [0x9baa40]
cmp edx, dword [0x9baa44]
jne 0x7e774a
mov eax, dword [0x9baa40]
push eax
call fcn.007e7aa0
add esp, 4
mov dword [0x9baa40], eax
cmp dword [0x9baa40], 0
jne 0x7e780b
cmp dword [ebp + 0xc], 0
je 0x7e777c
cmp dword [0x9baa48], 0
je 0x7e777c
call fcn.007e6fa0
test eax, eax
je 0x7e7777
or eax, 0xffffffff
jmp 0x7e7a14
jmp 0x7e780b
cmp dword [ebp - 0x1c], 0
je 0x7e7789
xor eax, eax
jmp 0x7e7a14
cmp dword [0x9baa40], 0
jne 0x7e77ca
push 0x9c
push str.setenv.c
push 2
push 4
call fcn.007c6700
add esp, 0x10
mov dword [0x9baa40], eax
cmp dword [0x9baa40], 0
jne 0x7e77be
or eax, 0xffffffff
jmp 0x7e7a14
mov ecx, dword [0x9baa40]
mov dword [ecx], 0
cmp dword [0x9baa48], 0
jne 0x7e780b
push 0xa3
push str.setenv.c
push 2
push 4
call fcn.007c6700
add esp, 0x10
mov dword [0x9baa48], eax
cmp dword [0x9baa48], 0
jne 0x7e77ff
or eax, 0xffffffff
jmp 0x7e7a14
mov edx, dword [0x9baa48]
mov dword [edx], 0
mov eax, dword [0x9baa40]
mov dword [ebp - 8], eax
mov ecx, dword [ebp - 0x20]
sub ecx, dword [ebp - 0x14]
push ecx
mov edx, dword [ebp - 0x14]
push edx
call fcn.007e7a20
add esp, 8
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
jl 0x7e78d4
mov eax, dword [ebp - 8]
cmp dword [eax], 0
je 0x7e78d4
push 2
mov ecx, dword [ebp - 0xc]
mov edx, dword [ebp - 8]
mov eax, dword [edx + ecx*4]
push eax
call fcn.007c7290
add esp, 8
cmp dword [ebp - 0x1c], 0
je 0x7e78ba
jmp 0x7e7864
mov ecx, dword [ebp - 0xc]
add ecx, 1
mov dword [ebp - 0xc], ecx
mov edx, dword [ebp - 0xc]
mov eax, dword [ebp - 8]
cmp dword [eax + edx*4], 0
je 0x7e7885
mov ecx, dword [ebp - 0xc]
mov edx, dword [ebp - 8]
mov eax, dword [ebp - 0xc]
mov esi, dword [ebp - 8]
mov eax, dword [esi + eax*4 + 4]
mov dword [edx + ecx*4], eax
jmp 0x7e785b
push 0xd1
push str.setenv.c
push 2
mov ecx, dword [ebp - 0xc]
shl ecx, 2
push ecx
mov edx, dword [0x9baa40]
push edx
call fcn.007c6bf0
add esp, 0x14
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 0
je 0x7e78b8
mov eax, dword [ebp - 8]
mov dword [0x9baa40], eax
jmp 0x7e78cf
mov ecx, dword [ebp - 0xc]
mov edx, dword [ebp - 8]
mov eax, dword [ebp - 0x14]
mov dword [edx + ecx*4], eax
mov ecx, dword [ebp + 8]
mov dword [ecx], 0
jmp 0x7e796a
cmp dword [ebp - 0x1c], 0
jne 0x7e794c
cmp dword [ebp - 0xc], 0
jge 0x7e78e8
mov edx, dword [ebp - 0xc]
neg edx
mov dword [ebp - 0xc], edx
push 0xe9
push str.setenv.c
push 2
mov eax, dword [ebp - 0xc]
lea ecx, [eax*4 + 8]
push ecx
mov edx, dword [0x9baa40]
push edx
call fcn.007c6bf0
add esp, 0x14
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 0
jne 0x7e791f
or eax, 0xffffffff
jmp 0x7e7a14
mov eax, dword [ebp - 0xc]
mov ecx, dword [ebp - 8]
mov edx, dword [ebp - 0x14]
mov dword [ecx + eax*4], edx
mov eax, dword [ebp - 0xc]
mov ecx, dword [ebp - 8]
mov dword [ecx + eax*4 + 4], 0
mov edx, dword [ebp + 8]
mov dword [edx], 0
mov eax, dword [ebp - 8]
mov dword [0x9baa40], eax
jmp 0x7e796a
push 2
mov ecx, dword [ebp - 0x14]
push ecx
call fcn.007c7290
add esp, 8
mov edx, dword [ebp + 8]
mov dword [edx], 0
xor eax, eax
jmp 0x7e7a14
cmp dword [ebp + 0xc], 0
je 0x7e79fd
push 0x109
push str.setenv.c
push 2
mov eax, dword [ebp - 0x14]
push eax
call fcn.007d0cd0
add esp, 4
add eax, 2
push eax
call fcn.007c6700
add esp, 0x10
mov dword [ebp - 0x18], eax
cmp dword [ebp - 0x18], 0
je 0x7e79fd
mov ecx, dword [ebp - 0x14]
push ecx
mov edx, dword [ebp - 0x18]
push edx
call fcn.007d0bd0
add esp, 8
mov eax, dword [ebp - 0x20]
sub eax, dword [ebp - 0x14]
add eax, dword [ebp - 0x18]
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 4]
mov byte [ecx], 0
mov edx, dword [ebp - 4]
add edx, 1
mov dword [ebp - 4], edx
xor eax, eax
cmp dword [ebp - 0x1c], 0
setne al
dec eax
and eax, dword [ebp - 4]
push eax
mov ecx, dword [ebp - 0x18]
push ecx
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableA]
test eax, eax
jne 0x7e79ef
mov dword [ebp - 0x10], 0xffffffff
push 2
mov edx, dword [ebp - 0x18]
push edx
call fcn.007c7290
add esp, 8
cmp dword [ebp - 0x1c], 0
je 0x7e7a11
push 2
mov eax, dword [ebp - 0x14]
push eax
call fcn.007c7290
add esp, 8
mov eax, dword [ebp - 0x10]
pop esi
mov esp, ebp
pop ebp
ret