Function at 0x41f320
Capabilities:
Encode data using xor

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x44
mov edi, dword [esp + 0x60]
mov ebp, dword [esp + 0x5c]
mov eax, dword [ebp + 4]
lea ecx, [eax - 2]
mov edx, eax
nop
nop
nop
nop
nop
nop
nop
nop
nop
add ecx, 2
cmp word [edx], 0
lea edx, [edx + 2]
jne 0x41f340
mov edx, ecx
xor edx, eax
not eax
and eax, ecx
add eax, eax
sub eax, edx
mov ebx, dword [edi + 4]
xor ecx, ecx
nop
nop
nop
cmp word [ebx + ecx], 0
lea ecx, [ecx + 2]
jne 0x41f360
sar eax, 1
lea edx, [ebx + ecx]
add edx, 0xfffffffe
mov ecx, ebx
not ecx
and ecx, edx
add ecx, ecx
xor edx, ebx
sub ecx, edx
sar ecx, 1
lea edx, [eax + ecx]
add edx, 0x1b
test edx, edx
jns 0x41f391
mov eax, 0xffffffff
jmp 0x41f39a
add eax, ecx
lea eax, [eax*2 + 0x36]
push eax
call fcn.0040c630
add esp, 4
mov dword [esp + 0xc], 0x438e41bc
mov dword [esp + 0x10], 0x47a545ab
mov dword [esp + 0x14], 0x4ba649a9
mov dword [esp + 0x18], 0x4f8b4d6c
mov dword [esp + 0x1c], 0x73e671e8
mov dword [esp + 0x20], 0x77987591
mov dword [esp + 0x24], 0x7b9379eb
mov dword [esp + 0x28], 0x7f907d93
mov dword [esp + 0x2c], 0x63916140
mov dword [esp + 0x30], 0x67f26581
mov dword [esp + 0x34], 0x6b8369fc
mov dword [esp + 0x38], 0x6f896d82
mov dword [esp + 0x3c], 0x13ee1183
mov dword [esp + 0x40], 0x1514
mov dword [esp + 8], eax
mov dword [esp], 0
mov ecx, dword [esp]
cmp ecx, 0x37
ja 0x41f475
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov esi, dword [esp]
mov ecx, dword [esp]
movzx ecx, byte [esp + ecx + 0xc]
mov edx, esi
xor edx, 0xeb4f1e10
and esi, 0xeb4f1e10
lea esi, [edx + esi*2]
lea edx, [esi + ecx]
not ecx
or esi, ecx
sub ecx, esi
lea ecx, [edx + ecx*2]
mov dword [esp + 4], ecx
mov edx, dword [esp + 4]
add dl, 0xb0
mov ecx, dword [esp]
mov byte [esp + ecx + 0xc], dl
inc dword [esp]
mov ecx, dword [esp]
cmp ecx, 0x38
jb 0x41f430
mov ecx, dword [ebp + 4]
movzx edx, word [ecx]
mov esi, eax
test dx, dx
je 0x41f4a1
add ecx, 2
mov esi, eax
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov word [esi], dx
add esi, 2
movzx edx, word [ecx]
add ecx, 2
test dx, dx
jne 0x41f490
mov word [esi], 0
movzx ecx, word [esp + 0xc]
test cx, cx
je 0x41f4d1
lea edx, [esp + 0xe]
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov word [esi], cx
add esi, 2
movzx ecx, word [edx]
add edx, 2
test cx, cx
jne 0x41f4c0
mov word [esi], 0
movzx ecx, word [ebx]
test cx, cx
je 0x41f501
add ebx, 2
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov word [esi], cx
add esi, 2
movzx ecx, word [ebx]
add ebx, 2
test cx, cx
jne 0x41f4f0
mov word [esi], 0
mov esi, ebp
mov ebp, dword [ebp]
xor eax, eax
nop
nop
nop
cmp word [ebp + eax], 0
lea eax, [eax + 2]
jne 0x41f510
lea ecx, [eax + ebp]
add ecx, 0xfffffffe
mov eax, ebp
not eax
and eax, ecx
xor ecx, ebp
add eax, eax
sub eax, ecx
mov ecx, dword [esi + 8]
lea edx, [ecx - 2]
mov ebx, ecx
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
add edx, 2
cmp word [ebx], 0
lea ebx, [ebx + 2]
jne 0x41f540
sar eax, 1
mov ebx, edx
xor ebx, ecx
not ecx
and ecx, edx
add ecx, ecx
sub ecx, ebx
add eax, 0xe
mov ebx, dword [edi]
xor edx, edx
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
cmp word [ebx + edx], 0
lea edx, [edx + 2]
jne 0x41f570
sar ecx, 1
add eax, ecx
add edx, ebx
add edx, 0xfffffffe
mov ecx, ebx
not ecx
and ecx, edx
xor edx, ebx
add ecx, ecx
sub ecx, edx
sar ecx, 1
mov edx, ecx
and edx, eax
xor ecx, eax
lea eax, [ecx + edx*2]
test eax, eax
jns 0x41f5a5
mov eax, 0xffffffff
jmp 0x41f5a7
add eax, eax
push eax
call fcn.0040c630
add esp, 4
mov edi, eax
movzx ecx, word [ebp]
test cx, cx
je 0x41f5d2
add ebp, 2
mov eax, edi
mov word [eax], cx
add eax, 2
movzx ecx, word [ebp]
add ebp, 2
test cx, cx
jne 0x41f5c0
mov word [eax], 0x2f
mov dword [esp + 0xc], 0xe159e7b5
mov dword [esp + 0x10], 0xdd6ee368
mov dword [esp + 0x14], 0xd948df43
mov dword [esp + 0x18], 0xd541db55
mov dword [esp + 0x1c], 0xd140d745
mov dword [esp + 0x20], 0xcd83d35d
mov word [esp + 0x24], 0xcfcc
mov dword [esp + 0x26], 0
mov dword [esp], 0
mov ecx, dword [esp]
cmp ecx, 0x1d
ja 0x41f660
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov ecx, dword [esp]
mov edx, dword [esp]
movzx edx, byte [esp + edx + 0xc]
add ecx, 0x3bce9459
xor ecx, edx
mov dword [esp + 4], ecx
mov ecx, dword [esp + 4]
add cl, 0x43
mov edx, dword [esp]
mov byte [esp + edx + 0xc], cl
inc dword [esp]
mov ecx, dword [esp]
cmp ecx, 0x1e
jb 0x41f630
add eax, 2
mov ecx, dword [esi + 8]
movzx edx, word [ecx]
test dx, dx
je 0x41f693
add ecx, 2
mov esi, dword [esp + 8]
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov word [eax], dx
add eax, 2
movzx edx, word [ecx]
add ecx, 2
test dx, dx
jne 0x41f680
jmp 0x41f697
mov esi, dword [esp + 8]
mov word [eax], 0
movzx ecx, word [esp + 0xc]
test cx, cx
je 0x41f6c1
lea edx, [esp + 0xe]
nop
nop
nop
nop
nop
nop
mov word [eax], cx
add eax, 2
movzx ecx, word [edx]
add edx, 2
test cx, cx
jne 0x41f6b0
mov word [eax], 0
movzx ecx, word [ebx]
test cx, cx
je 0x41f6f1
add ebx, 2
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 [ebx]
add ebx, 2
test cx, cx
jne 0x41f6e0
mov word [eax], 0
mov dword [esp + 0xc], 0x7776095e
mov word [esp + 0x10], 0
mov dword [esp], 0
mov eax, dword [esp]
cmp eax, 5
ja 0x41f760
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov eax, dword [esp]
mov ecx, dword [esp]
movzx ecx, byte [esp + ecx + 0xc]
mov edx, eax
xor edx, 0xed3ffe3e
and eax, 0xed3ffe3e
lea eax, [edx + eax*2]
lea edx, [eax + ecx]
and eax, ecx
add eax, eax
sub edx, eax
mov dword [esp + 4], edx
mov eax, dword [esp + 4]
add al, 0xca
mov ecx, dword [esp]
mov byte [esp + ecx + 0xc], al
inc dword [esp]
mov eax, dword [esp]
cmp eax, 6
jb 0x41f720
lea eax, [esp + 0xc]
push 0
push 0
push 0
push 0xc00000
push eax
push esi
push edi
push dword [esp + 0x74]
call fcn.004220d0
add esp, 0x20
mov ebx, eax
jmp dword [0x44c1e0]