Function at 0x402c8a
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
push ebx
push esi
mov byte [ebp - 1], 0x33
movzx eax, byte [ebp - 1]
xor edx, edx
mov ecx, 0x2e8
div ecx
or al, 0x21
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x10]
xor eax, 0x14c
movzx ecx, byte [ebp - 1]
or eax, ecx
mov dword [ebp - 0xc], eax
movzx ecx, word [ebp - 0x10]
mov eax, 0x382
xor edx, edx
div ecx
add eax, 0x35b
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x10]
sub eax, 0x1a
xor eax, 0x18c
mov dword [ebp - 0x10], eax
xor ebx, ebx
cmp word [ebp - 0xc], 0x5b
jae 0x402d0a
mov eax, dword [ebp - 0x10]
add eax, 0x61
mov dword [ebp - 0x10], eax
cmp word [ebp - 0xc], 0x36
jae 0x402d88
movzx eax, byte [ebp - 1]
add eax, 0x1aa
mov dword [ebp - 0x10], eax
jmp 0x402de6
cmp word [ebp - 0xc], 0x17f
jne 0x402d75
cmp byte [ebp - 1], 0x33
jne 0x402d22
mov eax, 0x40daca
mov dword [ebp - 0x14], eax
jmp 0x402cee
cmp byte [ebp - 1], bl
jae 0x402d42
movzx eax, word [ebp - 0x10]
xor edx, edx
mov ecx, 0xfa
div ecx
xor edx, edx
mov ecx, 0x38f
div ecx
mov byte [ebp - 1], dl
jmp 0x402cee
cmp byte [ebp - 1], 0x3c
jbe 0x402d56
movzx eax, byte [ebp - 1]
shl eax, 2
or al, 0x74
mov dword [ebp - 0x14], eax
jmp 0x402cee
cmp byte [ebp - 1], 0x2c
ja 0x402cee
movzx eax, byte [ebp - 1]
movzx ecx, byte [ebp - 1]
xor edx, edx
div ecx
or dx, 0x254
mov dword [ebp - 8], edx
jmp 0x402cee
cmp word [ebp - 0xc], 1
jne 0x402cee
mov al, byte [ebp - 0xc]
jmp 0x402f7f
cmp word [ebp - 0xc], 0x46
ja 0x402daa
movzx ecx, word [ebp - 0xc]
mov eax, 0x34a
xor edx, edx
div ecx
push 0x3a
pop ecx
mov eax, edx
xor edx, edx
div ecx
mov dword [ebp - 8], eax
jmp 0x402de6
cmp word [ebp - 0xc], 0x24
ja 0x402db9
mov al, byte [ebp - 1]
jmp 0x402f7f
cmp word [ebp - 0xc], 0x17f
jne 0x402de6
movzx eax, word [ebp - 0xc]
xor edx, edx
mov ecx, 0x328
div ecx
mov ecx, 0x1ab
mov eax, edx
xor edx, edx
div ecx
mov ecx, dword [ebp - 0x14]
lea eax, [ecx + eax + 0x2448]
mov dword [ebp - 0x14], eax
mov al, byte [ebp - 0x10]
add eax, 0x169
mov byte [ebp - 1], al
movzx eax, byte [ebp - 1]
imul eax, eax, 0x3f97b
movzx ecx, word [ebp - 0xc]
xor edx, edx
div ecx
sub edx, 0x10
je 0x402f6a
push 0x2e
pop esi
mov dword [ebp - 8], esi
mov al, byte [ebp - 8]
and ax, 0xdb
mov cl, byte [ebp - 8]
or eax, ecx
mov byte [ebp - 2], al
cmp byte [ebp - 2], 0x2e
jne 0x402f33
cmp word [ebp - 8], 0x32
jne 0x402e5a
movzx eax, byte [ebp - 2]
movzx ecx, word [ebp - 8]
sub ecx, eax
push ecx
movzx eax, word [ebp - 8]
movzx ecx, word [ebp - 8]
xor edx, edx
push 0x17
div ecx
pop ecx
sub ecx, eax
push ecx
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
jmp 0x402f33
cmp word [ebp - 8], si
jne 0x402ed5
cmp word [ebp - 8], 0x18
jae 0x402e72
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
jmp 0x402f33
cmp word [ebp - 8], si
jne 0x402f33
cmp byte [ebp - 2], 0x2e
jne 0x402e96
mov eax, dword [ebp - 0x14]
mov al, byte [ebx + eax]
cmp al, byte [ebp + 8]
je 0x402f83
jmp 0x402f33
cmp byte [ebp - 2], 0x19
jne 0x402eac
movzx eax, word [ebp - 8]
or ax, 0x149
mov dword [ebp - 0x18], eax
jmp 0x402f33
cmp byte [ebp - 2], 0x16
jb 0x402f87
cmp byte [ebp - 2], 0x4f
jbe 0x402ec9
movzx eax, byte [ebp - 2]
and ax, 0x3d5
mov dword [ebp - 0x18], eax
jmp 0x402f33
cmp byte [ebp - 2], 0x31
ja 0x402f8c
jmp 0x402f33
cmp word [ebp - 8], 0xf
jae 0x402ee8
mov al, byte [ebp - 8]
and ax, 0xbdc9
mov byte [ebp - 2], al
jmp 0x402f33
cmp word [ebp - 8], 0x52
jne 0x402f0b
movzx eax, word [ebp - 8]
imul eax, eax, 0x1ac
movzx ecx, word [ebp - 8]
add eax, ecx
xor eax, 0x67
push eax
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
jmp 0x402f33
cmp word [ebp - 8], 0x3a
jbe 0x402f33
movzx eax, byte [ebp - 2]
xor edx, edx
mov ecx, 0x38c
div ecx
mov ecx, edx
movzx eax, byte [ebp - 2]
xor edx, edx
mov esi, 0x323
div esi
xor ecx, eax
mov byte [ebp - 2], cl
movzx eax, word [ebp - 8]
xor edx, edx
mov ecx, 0xbd
div ecx
xor edx, edx
mov ecx, 0x20a
div ecx
mov byte [ebp - 2], dl
inc ebx
movzx eax, byte [ebp - 1]
imul eax, eax, 0x3f97b
movzx ecx, word [ebp - 0xc]
xor edx, edx
div ecx
sub edx, 0x10
cmp ebx, edx
jb 0x402e0c
movzx ecx, word [ebp - 0x10]
push 0x1e
xor edx, edx
pop eax
div ecx
mov al, byte [ebp - 0x10]
sub edx, eax
mov byte [ebp - 1], dl
xor al, al
pop esi
pop ebx
leave
ret
mov al, bl
jmp 0x402f7f
mov al, byte [ebp - 2]
jmp 0x402f7f
mov al, byte [ebp - 8]
jmp 0x402f7f