Function at 0x409150
Capabilities:
Encode data using xor
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4611fa
mov eax, dword fs:[0]
push eax
sub esp, 0xac
mov eax, dword [0x4790bc]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov edi, ecx
mov dword [ebp - 0xb4], edi
cmp dword [0x4797ec], 0
mov dword [ebp - 4], 0
jne 0x4091df
movaps xmm0, xmmword [0x463d40]
xor ecx, ecx
movups xmmword [ebp - 0x48], xmm0
mov dword [ebp - 0x38], 0x1716155c
mov dword [ebp - 0x34], 0x1c4b4d
mov byte [ebp - 0x30], 1
mov al, cl
add al, 0x14
xor byte [ebp + ecx - 0x48], al
inc ecx
cmp ecx, 0x17
jb 0x4091b8
lea eax, [ebp - 0x48]
mov byte [ebp - 0x30], 0
push 5
push eax
call fcn.00412e10
add esp, 8
mov byte [0x479785], 1
mov dword [ebp - 0x20], 0x65736661
xor ecx, ecx
mov dword [ebp - 0x1c], 0x7e777876
mov word [ebp - 0x18], 0x100
mov al, cl
add al, 0x14
xor byte [ebp + ecx - 0x20], al
inc ecx
cmp ecx, 8
jb 0x4091f5
lea eax, [ebp - 0x20]
mov byte [ebp - 0x17], 0
push eax
call dword [sym.imp.api_ms_win_crt_environment_l1_1_0.dll_getenv]
mov edx, eax
mov dword [ebp - 0xac], 0
mov ecx, edx
mov dword [ebp - 0x9c], 0
add esp, 4
mov dword [ebp - 0x98], 0
lea esi, [ecx + 1]
nop dword [eax]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x409240
sub ecx, esi
push ecx
push edx
lea ecx, [ebp - 0xac]
call fcn.004022a0
mov dword [ebp - 0x68], 0
mov dword [ebp - 0x58], 0
mov dword [ebp - 0x54], 0xf
mov byte [ebp - 0x68], 0
push 4
mov byte [ebp - 4], 2
call fcn.0045f2b0
add esp, 4
mov dword [ebp - 0x28], eax
mov byte [ebp - 4], 3
test eax, eax
je 0x40928f
mov ecx, eax
call fcn.00412930
push 0x1024
mov byte [ebp - 4], 2
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
push 0x1024
mov ebx, eax
push 0
push ebx
call sub.VCRUNTIME140.dll_memset
add esp, 0x10
mov byte [0x479784], 0
mov ecx, 0x479788
push 0
push 0x463c77
call fcn.004035c0
mov dword [ebp - 0x1c], 0x63776756
xor ecx, ecx
mov dword [ebp - 0x18], 0x100786e
mov al, cl
add al, 0x14
xor byte [ebp + ecx - 0x1c], al
inc ecx
cmp ecx, 6
jb 0x4092d8
lea eax, [ebp - 0xae]
mov byte [ebp - 0x15], 0
push eax
lea eax, [ebp - 0x16]
push eax
lea eax, [ebp - 0x1c]
push eax
lea ecx, [ebp - 0x48]
call fcn.004065c0
lea eax, [ebp - 0x48]
mov byte [ebp - 4], 4
push eax
lea eax, [ebp - 0x84]
push eax
call fcn.00413c80
add esp, 8
mov edx, eax
cmp dword [edx + 0x14], 0x10
mov byte [ebp - 4], 5
jb 0x409326
mov edx, dword [edx]
mov dword [ebp - 0x2c], 0x7e627675
xor ecx, ecx
mov dword [ebp - 0x28], 0x1007777
mov al, cl
add al, 0x14
xor byte [ebp + ecx - 0x2c], al
inc ecx
cmp ecx, 6
jb 0x409336
push edx
lea eax, [ebp - 0x2c]
mov byte [ebp - 0x25], 0
push eax
lea ecx, [ebp - 0x68]
call fcn.00411ae0
mov ecx, dword [ebp - 0x70]
mov byte [ebp - 4], 4
cmp ecx, 0x10
jb 0x40938c
mov edx, dword [ebp - 0x84]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x409382
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x4093cb
push ecx
push edx
call fcn.0045f2e0
add esp, 8
mov ecx, dword [ebp - 0x34]
mov dword [ebp - 0x74], 0
mov dword [ebp - 0x70], 0xf
mov byte [ebp - 0x84], 0
mov byte [ebp - 4], 2
cmp ecx, 0x10
jb 0x4093db
mov edx, dword [ebp - 0x48]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x4093d1
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x4093d1
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push ecx
push edx
call fcn.0045f2e0
add esp, 8
lea eax, [ebp - 0x48]
push 0x47980c
push eax
call fcn.00413c80
add esp, 8
mov edx, eax
cmp dword [edx + 0x14], 0x10
mov byte [ebp - 4], 6
jb 0x4093fa
mov edx, dword [edx]
mov dword [ebp - 0x20], 0x7f626075
xor ecx, ecx
mov dword [ebp - 0x1c], 0x7e7047
mov byte [ebp - 0x18], 1
nop
mov al, cl
add al, 0x14
xor byte [ebp + ecx - 0x20], al
inc ecx
cmp ecx, 7
jb 0x409410
push edx
lea eax, [ebp - 0x20]
mov byte [ebp - 0x18], 0
push eax
lea ecx, [ebp - 0x68]
call fcn.00411ae0
mov ecx, dword [ebp - 0x34]
mov byte [ebp - 4], 2
cmp ecx, 0x10
jb 0x409469
mov edx, dword [ebp - 0x48]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x40945f
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x40945f
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push ecx
push edx
call fcn.0045f2e0
add esp, 8
sub esp, 0x18
mov ecx, esp
push 0x4797f4
call fcn.00402540
lea eax, [ebp - 0x48]
push eax
lea ecx, [ebp - 0xad]
call fcn.00415910
mov edx, eax
cmp dword [edx + 0x14], 0x10
mov byte [ebp - 4], 7
jb 0x409495
mov edx, dword [edx]
mov dword [ebp - 0x24], 0x7f626075
xor ecx, ecx
mov dword [ebp - 0x20], 0x726e777d
mov dword [ebp - 0x1c], 0x766a7c7f
mov dword [ebp - 0x18], 0x1004f4f
mov al, cl
add al, 0x14
xor byte [ebp + ecx - 0x24], al
inc ecx
cmp ecx, 0xe
jb 0x4094b3
push edx
lea eax, [ebp - 0x24]
mov byte [ebp - 0x15], 0
push eax
lea ecx, [ebp - 0x68]
call fcn.00411ae0
mov ecx, dword [ebp - 0x34]
mov byte [ebp - 4], 2
cmp ecx, 0x10
jb 0x40950c
mov edx, dword [ebp - 0x48]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x409502
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x409502
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push ecx
push edx
call fcn.0045f2e0
add esp, 8
sub esp, 0x18
mov ecx, esp
push edi
call fcn.00402540
lea eax, [ebp - 0x48]
push eax
lea ecx, [ebp - 0xad]
call fcn.00415910
mov edx, eax
cmp dword [edx + 0x14], 0x10
mov byte [ebp - 4], 8
jb 0x409534
mov edx, dword [edx]
mov dword [ebp - 0x1c], 0x63776756
xor ecx, ecx
mov dword [ebp - 0x18], 0x100786e
mov al, cl
add al, 0x14
xor byte [ebp + ecx - 0x1c], al
inc ecx
cmp ecx, 6
jb 0x409544
push edx
lea eax, [ebp - 0x1c]
mov byte [ebp - 0x15], 0
push eax
lea ecx, [ebp - 0x68]
call fcn.00411ae0
mov ecx, dword [ebp - 0x34]
mov byte [ebp - 4], 2
cmp ecx, 0x10
jb 0x40959d
mov edx, dword [ebp - 0x48]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x409593
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x409593
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push ecx
push edx
call fcn.0045f2e0
add esp, 8
sub esp, 0x18
mov ecx, esp
push 0x4797c4
call fcn.00402540
lea eax, [ebp - 0x48]
push eax
lea ecx, [ebp - 0xad]
call fcn.00415910
mov edx, eax
cmp dword [edx + 0x14], 0x10
mov byte [ebp - 4], 9
jb 0x4095c9
mov edx, dword [edx]
mov dword [ebp - 0x1c], 0x72657a78
xor ecx, ecx
mov word [ebp - 0x18], 0x6a
mov byte [ebp - 0x16], 1
nop dword [eax]
mov al, cl
add al, 0x14
xor byte [ebp + ecx - 0x1c], al
inc ecx
cmp ecx, 5
jb 0x4095e0
push edx
lea eax, [ebp - 0x1c]
mov byte [ebp - 0x16], 0
push eax
lea ecx, [ebp - 0x68]
call fcn.00411ae0
mov ecx, dword [ebp - 0x34]
mov byte [ebp - 4], 2
cmp ecx, 0x10
jb 0x409639
mov edx, dword [ebp - 0x48]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x40962f
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x40962f
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push ecx
push edx
call fcn.0045f2e0
add esp, 8
sub esp, 0x18
lea eax, [ebp - 0xac]
mov ecx, esp
push eax
call fcn.00402540
lea eax, [ebp - 0x48]
push eax
lea ecx, [ebp - 0xad]
call fcn.00415910
mov edx, eax
cmp dword [edx + 0x14], 0x10
mov byte [ebp - 4], 0xa
jb 0x409667
mov edx, dword [edx]
mov dword [ebp - 0x1c], 0x6573667d
xor ecx, ecx
mov word [ebp - 0x18], 0x100
mov al, cl
add al, 0x14
xor byte [ebp + ecx - 0x1c], al
inc ecx
cmp ecx, 4
jb 0x409676
push edx
lea eax, [ebp - 0x1c]
mov byte [ebp - 0x17], 0
push eax
lea ecx, [ebp - 0x68]
call fcn.00411ae0
mov ecx, dword [ebp - 0x34]
mov byte [ebp - 4], 2
cmp ecx, 0x10
jb 0x4096cf
mov edx, dword [ebp - 0x48]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x4096c5
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x4096c5
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push ecx
push edx
call fcn.0045f2e0
add esp, 8
movaps xmm0, xmmword [0x463dd0]
lea ecx, [ebp - 0x68]
movups xmmword [ebp - 0x50], xmm0
push 0
movaps xmm0, xmmword [str.FBK_tKFG]
movups xmmword [ebp - 0x40], xmm0
mov word [ebp - 0x30], 0x100
call fcn.00411ca0
sub esp, 0x18
mov esi, eax
mov edx, esp
mov dword [ebp - 0x28], esp
mov ecx, esi
mov dword [edx], 0
mov dword [edx + 0x10], 0
lea edi, [ecx + 1]
mov dword [edx + 0x14], 0
mov al, byte [ecx]
inc ecx
test al, al
jne 0x409718
sub ecx, edi
push ecx
push esi
mov ecx, edx
call fcn.004022a0
push ebx
sub esp, 0x18
mov byte [ebp - 4], 0xb
mov edx, esp
mov dword [ebp - 0x18], edx
cmp byte [ebp - 0x2f], 0
je 0x409752
xor ecx, ecx
nop
mov al, cl
add al, 0x14
xor byte [ebp + ecx - 0x50], al
inc ecx
cmp ecx, 0x20
jb 0x409740
mov byte [ebp - 0x2f], 0
lea eax, [ebp - 0xae]
mov ecx, edx
push eax
lea eax, [ebp - 0x30]
push eax
lea eax, [ebp - 0x50]
push eax
call fcn.004065c0
mov byte [ebp - 4], 2
call fcn.0040e5b0
movzx ecx, byte [0x479785]
test al, al
mov edx, 1
cmove ecx, edx
cmp ebx, 0x463cbc
push 0x1024
movzx eax, cl
push 0
push dword [0x479858]
cmove eax, edx
mov byte [0x479785], al
call sub.VCRUNTIME140.dll_memset
mov esi, dword [0x479858]
add esp, 0x44
mov edx, ebx
mov al, byte [edx]
lea edx, [edx + 1]
mov byte [esi], al
lea esi, [esi + 1]
test al, al
jne 0x4097b0
push ebx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov ecx, dword [ebp - 0xb4]
add esp, 4
call fcn.004098e0
mov ecx, dword [ebp - 0x54]
cmp ecx, 0x10
jb 0x409803
mov edx, dword [ebp - 0x68]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x4097f9
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x409841
push ecx
push edx
call fcn.0045f2e0
add esp, 8
mov ecx, dword [ebp - 0x98]
mov dword [ebp - 0x58], 0
mov dword [ebp - 0x54], 0xf
mov byte [ebp - 0x68], 0
cmp ecx, 0x10
jb 0x409851
mov edx, dword [ebp - 0xac]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x409847
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x409847
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push ecx
push edx
call fcn.0045f2e0
add esp, 8
mov al, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.0045f2ee
mov esp, ebp
pop ebp
ret