Function at 0x41f020
Capabilities:
Encode data using xor

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x46c
cmp byte [esp + 0x484], 0
jne 0x41f177
mov ebp, dword [esp + 0x480]
mov dword [esp + 0xc], 0
mov dword [esp + 0x10], 0
mov dword [esp + 0x14], 0x6508630d
mov dword [esp + 0x18], 0x693b6703
mov dword [esp + 0x1c], 0x6d426b38
mov dword [esp + 0x20], 0x91fc6f0a
mov dword [esp + 0x24], 0x959493fe
mov eax, 0x67e7e4f2
nop
nop
nop
nop
movzx edx, byte [esp + eax - 0x67e7e4de]
xor edx, eax
mov ecx, edx
and ecx, 0x6f
xor edx, 0xc0c0d86f
lea esi, [edx + ecx*2]
and edx, 1
lea ecx, [edx + edx]
or esi, 1
sub ecx, edx
add ecx, esi
mov byte [esp + eax - 0x67e7e4de], cl
inc eax
cmp eax, 0x67e7e506
jne 0x41f080
lea eax, [esp + 0x14]
lea ecx, [esp + 0xc]
push eax
call fcn.00436bd0
push 0xebc73df8
push dword [esp + 0x10]
call fcn.00438950
add esp, 8
mov ecx, esp
push ecx
push 0x43b598
push 1
push 0
push 0x43b5a8
call eax
test eax, eax
js 0x41f177
mov eax, dword [esp]
mov ecx, dword [eax]
lea edx, [esp + 8]
push edx
push 0x43b5b8
push eax
call dword [ecx]
xor ebx, ebx
test eax, eax
js 0x41f332
nop
nop
nop
nop
nop
nop
cmp word [ebp + ebx], 0
lea ebx, [ebx + 2]
jne 0x41f110
lea eax, [ebx + ebp]
add eax, 0xfffffffe
add ebx, ebp
mov ecx, 1
sub ecx, ebx
and ecx, ebp
mov edi, ebp
not edi
and edi, eax
sub edi, ecx
mov eax, dword [esp + 0x48c]
mov ebx, dword [eax + 8]
xor eax, eax
cmp word [ebx + eax], 0
lea eax, [eax + 2]
jne 0x41f140
sar edi, 1
lea ecx, [ebx + eax]
add ecx, 0xfffffffe
add eax, ebx
mov edx, 1
sub edx, eax
and edx, ebx
mov eax, ebx
not eax
and eax, ecx
sub eax, edx
sar eax, 1
add eax, edi
add eax, 2
test eax, eax
jns 0x41f17e
mov eax, 0xffffffff
jmp 0x41f180
xor ebx, ebx
jmp 0x41f33b
add eax, eax
push eax
call fcn.00408310
add esp, 4
mov esi, eax
movzx ecx, word [ebx]
test cx, cx
je 0x41f1b1
add ebx, 2
mov eax, esi
nop
nop
nop
nop
nop
nop
nop
nop
mov word [eax], cx
add eax, 2
movzx ecx, word [ebx]
add ebx, 2
test cx, cx
jne 0x41f1a0
mov word [eax], 0x5c
add eax, 2
movzx ecx, word [ebp]
test cx, cx
je 0x41f1e1
lea edx, [ebp + 2]
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov word [eax], cx
add eax, 2
movzx ecx, word [edx]
add edx, 2
test cx, cx
jne 0x41f1d0
mov word [eax], 0
mov eax, dword [esp + 8]
mov ecx, dword [eax]
push 0
push esi
push eax
call dword [ecx + 0x14]
test eax, eax
js 0x41f270
mov eax, dword [esp]
mov ecx, dword [eax]
push 1
push 0
push eax
call dword [ecx + 0x4c]
test eax, eax
js 0x41f270
mov eax, dword [esp]
mov ecx, dword [eax]
lea ebx, [esp + 0x264]
push 1
lea edx, [esp + 0x18]
push edx
push 0x104
push ebx
push eax
call dword [ecx + 0xc]
xor ebx, ebx
test eax, eax
js 0x41f31f
mov dword [esp + 4], esi
add edi, 2
mov eax, dword [esp + 0x48c]
mov esi, dword [eax + 4]
cmp word [esi + ebx], 0
lea ebx, [ebx + 2]
jne 0x41f240
lea eax, [esi + ebx]
add eax, 0xfffffffe
add ebx, esi
mov ecx, 1
sub ecx, ebx
and ecx, esi
mov edx, esi
not edx
and edx, eax
sub edx, ecx
sar edx, 1
add edi, edx
jns 0x41f277
mov edi, 0xffffffff
jmp 0x41f279
xor ebx, ebx
jmp 0x41f31f
add edi, edi
push edi
call fcn.00408310
add esp, 4
mov edi, eax
movzx ecx, word [esi]
test cx, cx
je 0x41f2b1
add esi, 2
mov eax, edi
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov word [eax], cx
add eax, 2
movzx ecx, word [esi]
add esi, 2
test cx, cx
jne 0x41f2a0
mov word [eax], 0x2f
add eax, 2
movzx ecx, word [ebp]
test cx, cx
je 0x41f2e4
add ebp, 2
mov esi, dword [esp + 4]
nop
nop
nop
nop
nop
nop
nop
mov word [eax], cx
add eax, 2
movzx ecx, word [ebp]
add ebp, 2
test cx, cx
jne 0x41f2d0
jmp 0x41f2e8
mov esi, dword [esp + 4]
mov word [eax], 0
mov ecx, dword [esp + 0x48c]
mov eax, dword [ecx + 0x14]
dec eax
push 1
push eax
push dword [ecx + 0x10]
push dword [ecx + 0xc]
lea eax, [esp + 0x274]
push eax
push edi
push dword [ecx]
call fcn.0041e110
add esp, 0x1c
mov ebx, eax
push edi
call fcn.00408320
add esp, 4
mov eax, dword [esp + 8]
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
push esi
call fcn.00408320
add esp, 4
mov eax, dword [esp]
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, ebx
add esp, 0x46c
pop esi
pop edi
pop ebx
pop ebp
ret 0x10