Function at 0x40c2ad
Capabilities:
Set environment variable

Disassembly:
push ebp
lea ebp, [esp - 0x68]
sub esp, 0x8a8
push ebx
push esi
mov esi, dword [0x4228a4]
xor ebx, ebx
cmp esi, ebx
je 0x40c68b
push edi
push 0x7fe
lea eax, [ebp - 0x83e]
push ebx
push eax
mov word [ebp - 0x840], bx
call sub.MSVCRT.dll_memset
push 0x9e
lea eax, [ebp - 0x3e]
push ebx
push eax
mov word [ebp - 0x40], bx
call sub.MSVCRT.dll_memset
mov edi, dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x18
cmp byte [ebp + 0x70], 9
jbe 0x40c324
cmp dword [ebp + 0x78], ebx
jne 0x40c324
movzx eax, byte [ebp + 0x7c]
push eax
lea eax, [ebp - 0x40]
push 0x4025ac
push eax
call edi
mov esi, dword [0x4228a4]
add esp, 0xc
movzx eax, byte [ebp + 0x70]
cmp eax, 0x12
ja case.default.0x40c331
jmp dword [eax*4 + 0x40c695]
cmp esi, ebx
je case.default.0x40c331
add esi, 0x10
cmp dword [ebp + 0x78], ebx
jne 0x40c67e
mov ebx, dword [0x4228a4]
add ebx, 0xb0
jmp 0x40c67e
mov eax, dword [0x4228a8]
cmp eax, ebx
je case.default.0x40c331
mov ecx, dword [ebp + 0x74]
imul ecx, ecx, 0x368
add eax, ecx
cmp dword [ebp + 0x78], ebx
lea esi, [eax + 0x10]
jne 0x40c67e
lea ebx, [eax + 0xb0]
jmp 0x40c67e
mov eax, dword [0x4228ac]
cmp eax, ebx
je case.default.0x40c331
mov ecx, dword [ebp + 0x74]
imul ecx, ecx, 0x4cc
jmp 0x40c373
mov eax, dword [0x4228b4]
cmp eax, ebx
je case.default.0x40c331
mov ecx, dword [ebp + 0x74]
imul ecx, ecx, 0xb04
jmp 0x40c373
mov eax, dword [0x4228b8]
cmp eax, ebx
je case.default.0x40c331
mov esi, dword [ebp + 0x74]
imul esi, esi, 0x364
add eax, esi
cmp dword [ebp + 0x78], ebx
lea ecx, [eax + 0x10]
mov dword [ebp + 0x64], esi
mov dword [ebp + 0x60], ecx
jne 0x40c3f0
lea ebx, [eax + 0xb0]
push ebx
push ecx
call dword [sym.imp.KERNEL32.DLL_SetEnvironmentVariableW]
push ebx
push dword [ebp + 0x60]
call dword [sym.imp.KERNEL32.DLL_SetEnvironmentVariableW]
mov eax, dword [0x4228b8]
push 0x4028c4
lea eax, [esi + eax + 0x10]
push eax
lea eax, [ebp - 0x840]
push 0x4028b8
push eax
call edi
xor ebx, ebx
add esp, 0x10
cmp dword [ebp + 0x78], ebx
lea esi, [ebp - 0x840]
jne 0x40c682
mov eax, dword [0x4228b8]
mov ecx, dword [ebp + 0x64]
movzx eax, byte [ecx + eax + 0x35c]
push eax
lea eax, [ebp - 0x40]
push 0x4025ac
push eax
call edi
add esp, 0xc
lea ebx, [ebp - 0x40]
jmp 0x40c682
mov eax, dword [0x4228c0]
cmp eax, ebx
je case.default.0x40c331
mov esi, dword [ebp + 0x74]
imul esi, esi, 0x368
add eax, esi
cmp dword [ebp + 0x78], ebx
lea ecx, [eax + 0x10]
mov dword [ebp + 0x64], esi
mov dword [ebp + 0x60], ecx
jne 0x40c486
lea ebx, [eax + 0xb0]
push ebx
push ecx
call dword [sym.imp.KERNEL32.DLL_SetEnvironmentVariableW]
push ebx
push dword [ebp + 0x60]
call dword [sym.imp.KERNEL32.DLL_SetEnvironmentVariableW]
mov eax, dword [0x4228c0]
push 0x4028c4
lea eax, [esi + eax + 0x10]
push eax
lea eax, [ebp - 0x840]
push 0x4028b8
push eax
call edi
xor ebx, ebx
add esp, 0x10
cmp dword [ebp + 0x78], ebx
lea esi, [ebp - 0x840]
jne 0x40c682
mov eax, dword [0x4228c0]
mov ecx, dword [ebp + 0x64]
jmp 0x40c433
mov eax, dword [0x4228bc]
cmp eax, ebx
je case.default.0x40c331
mov ecx, dword [ebp + 0x74]
imul ecx, ecx, 0x154
jmp 0x40c373
mov eax, dword [0x4228c4]
cmp eax, ebx
je case.default.0x40c331
mov ecx, dword [ebp + 0x74]
imul ecx, ecx, 0x3560
jmp 0x40c373
mov eax, dword [0x4228c8]
cmp eax, ebx
je case.default.0x40c331
mov ecx, dword [ebp + 0x74]
imul ecx, ecx, 0x2b0
cmp dword [ebp + 0x78], ebx
lea esi, [ecx + eax]
jne 0x40c67e
push dword [esi + 0xa0]
lea eax, [ebp - 0x40]
push 0x4025ac
push eax
call edi
add esp, 0xc
jmp 0x40c67b
mov eax, dword [0x4228d8]
cmp eax, ebx
je case.default.0x40c331
mov ecx, dword [ebp + 0x74]
imul ecx, ecx, 0xb8
add eax, ecx
cmp dword [ebp + 0x78], ebx
lea esi, [eax + 0x10]
jne 0x40c67e
push dword [eax + 0xb0]
jmp 0x40c52c
mov eax, dword [0x4228b8]
cmp eax, ebx
je case.default.0x40c331
mov ecx, dword [ebp + 0x74]
imul ecx, ecx, 0x364
push 0x4028a8
lea eax, [ecx + eax + 0x10]
push eax
lea eax, [ebp - 0x840]
push 0x4028b8
push eax
call edi
add esp, 0x10
lea esi, [ebp - 0x840]
jmp 0x40c44a
mov eax, dword [0x4228b0]
cmp eax, ebx
je case.default.0x40c331
push 0x4028a8
mov ecx, dword [ebp + 0x74]
imul ecx, ecx, 0xacc
jmp 0x40c586
mov eax, dword [0x4228cc]
cmp eax, ebx
je case.default.0x40c331
mov ecx, dword [ebp + 0x74]
imul ecx, ecx, 0x4b8
push 0x4028a8
add ecx, eax
push ecx
jmp 0x40c58b
mov eax, dword [0x4228c0]
cmp eax, ebx
je case.default.0x40c331
mov ecx, dword [ebp + 0x74]
imul ecx, ecx, 0x368
jmp 0x40c581
mov eax, dword [0x4228ac]
cmp eax, ebx
je case.default.0x40c331
mov ecx, dword [ebp + 0x74]
imul ecx, ecx, 0x4cc
jmp 0x40c581
mov eax, dword [0x4228a8]
jmp 0x40c5e9
mov eax, dword [0x4228c4]
cmp eax, ebx
je case.default.0x40c331
mov ecx, dword [ebp + 0x74]
imul ecx, ecx, 0x3560
jmp 0x40c581
mov eax, dword [0x4228b0]
cmp eax, ebx
je case.default.0x40c331
push 0x402894
jmp 0x40c5b9
mov eax, dword [0x4228ac]
cmp eax, ebx
je case.default.0x40c331
mov ecx, dword [ebp + 0x74]
imul ecx, ecx, 0x4cc
push 0x402894
lea eax, [ecx + eax + 0x10]
push eax
lea eax, [ebp - 0x840]
push 0x4028b8
push eax
call edi
add esp, 0x10
lea esi, [ebp - 0x840]
lea ebx, [ebp - 0x40]
test esi, esi
je case.default.0x40c331
push ebx
push esi
call dword [sym.imp.KERNEL32.DLL_SetEnvironmentVariableW]
pop edi
pop esi
pop ebx
add ebp, 0x68
leave
ret