Function at 0x10017f10
Capabilities:
Encode data using xor

Disassembly:
mov edx, dword [esp + 8]
cmp edx, 0
jne 0x10017f1a
ret
push ebp
push ebx
push esi
xor eax, eax
push edi
xor ebx, ebx
mov ebp, dword [esp + 0x14]
mov esi, dword [esp + 0x1c]
mov al, byte [ebp]
mov bl, byte [ebp + 4]
mov edi, dword [esp + 0x20]
inc al
sub esp, 0xc
add ebp, 8
cmp dword [ebp + 0x100], 0xffffffff
je 0x10018214
lea edx, [edx + esi - 8]
mov dword [esp + 8], edx
mov ecx, dword [ebp + eax*4]
cmp edx, esi
jb 0x100180a5
add esi, 8
add bl, cl
mov edx, dword [ebp + ebx*4]
mov dword [ebp + eax*4], edx
add edx, ecx
mov dword [ebp + ebx*4], ecx
and edx, 0xff
inc al
mov ecx, dword [ebp + eax*4]
mov edx, dword [ebp + edx*4]
mov byte [esp], dl
add bl, cl
mov edx, dword [ebp + ebx*4]
mov dword [ebp + eax*4], edx
add edx, ecx
mov dword [ebp + ebx*4], ecx
and edx, 0xff
inc al
mov ecx, dword [ebp + eax*4]
mov edx, dword [ebp + edx*4]
mov byte [esp + 1], dl
add bl, cl
mov edx, dword [ebp + ebx*4]
mov dword [ebp + eax*4], edx
add edx, ecx
mov dword [ebp + ebx*4], ecx
and edx, 0xff
inc al
mov ecx, dword [ebp + eax*4]
mov edx, dword [ebp + edx*4]
mov byte [esp + 2], dl
add bl, cl
mov edx, dword [ebp + ebx*4]
mov dword [ebp + eax*4], edx
add edx, ecx
mov dword [ebp + ebx*4], ecx
and edx, 0xff
inc al
mov ecx, dword [ebp + eax*4]
mov edx, dword [ebp + edx*4]
mov byte [esp + 3], dl
add bl, cl
mov edx, dword [ebp + ebx*4]
mov dword [ebp + eax*4], edx
add edx, ecx
mov dword [ebp + ebx*4], ecx
and edx, 0xff
inc al
mov ecx, dword [ebp + eax*4]
mov edx, dword [ebp + edx*4]
mov byte [esp + 4], dl
add bl, cl
mov edx, dword [ebp + ebx*4]
mov dword [ebp + eax*4], edx
add edx, ecx
mov dword [ebp + ebx*4], ecx
and edx, 0xff
inc al
mov ecx, dword [ebp + eax*4]
mov edx, dword [ebp + edx*4]
mov byte [esp + 5], dl
add bl, cl
mov edx, dword [ebp + ebx*4]
mov dword [ebp + eax*4], edx
add edx, ecx
mov dword [ebp + ebx*4], ecx
and edx, 0xff
inc al
mov ecx, dword [ebp + eax*4]
mov edx, dword [ebp + edx*4]
mov byte [esp + 6], dl
add bl, cl
mov edx, dword [ebp + ebx*4]
mov dword [ebp + eax*4], edx
add edx, ecx
mov dword [ebp + ebx*4], ecx
and edx, 0xff
inc al
mov edx, dword [ebp + edx*4]
add edi, 8
mov byte [esp + 7], dl
mov ecx, dword [esp]
mov edx, dword [esi - 8]
xor ecx, edx
mov edx, dword [esi - 4]
mov dword [edi - 8], ecx
mov ecx, dword [esp + 4]
xor ecx, edx
mov edx, dword [esp + 8]
mov dword [edi - 4], ecx
mov ecx, dword [ebp + eax*4]
cmp esi, edx
jbe 0x10017f5d
add edx, 8
inc esi
cmp edx, esi
jb 0x10018244
mov dword [esp + 8], edx
add bl, cl
mov edx, dword [ebp + ebx*4]
mov dword [ebp + eax*4], edx
add edx, ecx
mov dword [ebp + ebx*4], ecx
and edx, 0xff
inc al
mov ecx, dword [ebp + eax*4]
mov edx, dword [ebp + edx*4]
mov dh, byte [esi - 1]
xor dl, dh
mov byte [edi], dl
mov edx, dword [esp + 8]
cmp edx, esi
jbe 0x10018244
inc esi
add bl, cl
mov edx, dword [ebp + ebx*4]
mov dword [ebp + eax*4], edx
add edx, ecx
mov dword [ebp + ebx*4], ecx
and edx, 0xff
inc al
mov ecx, dword [ebp + eax*4]
mov edx, dword [ebp + edx*4]
mov dh, byte [esi - 1]
xor dl, dh
mov byte [edi + 1], dl
mov edx, dword [esp + 8]
cmp edx, esi
jbe 0x10018244
inc esi
add bl, cl
mov edx, dword [ebp + ebx*4]
mov dword [ebp + eax*4], edx
add edx, ecx
mov dword [ebp + ebx*4], ecx
and edx, 0xff
inc al
mov ecx, dword [ebp + eax*4]
mov edx, dword [ebp + edx*4]
mov dh, byte [esi - 1]
xor dl, dh
mov byte [edi + 2], dl
mov edx, dword [esp + 8]
cmp edx, esi
jbe 0x10018244
inc esi
add bl, cl
mov edx, dword [ebp + ebx*4]
mov dword [ebp + eax*4], edx
add edx, ecx
mov dword [ebp + ebx*4], ecx
and edx, 0xff
inc al
mov ecx, dword [ebp + eax*4]
mov edx, dword [ebp + edx*4]
mov dh, byte [esi - 1]
xor dl, dh
mov byte [edi + 3], dl
mov edx, dword [esp + 8]
cmp edx, esi
jbe 0x10018244
inc esi
add bl, cl
mov edx, dword [ebp + ebx*4]
mov dword [ebp + eax*4], edx
add edx, ecx
mov dword [ebp + ebx*4], ecx
and edx, 0xff
inc al
mov ecx, dword [ebp + eax*4]
mov edx, dword [ebp + edx*4]
mov dh, byte [esi - 1]
xor dl, dh
mov byte [edi + 4], dl
mov edx, dword [esp + 8]
cmp edx, esi
jbe 0x10018244
inc esi
add bl, cl
mov edx, dword [ebp + ebx*4]
mov dword [ebp + eax*4], edx
add edx, ecx
mov dword [ebp + ebx*4], ecx
and edx, 0xff
inc al
mov ecx, dword [ebp + eax*4]
mov edx, dword [ebp + edx*4]
mov dh, byte [esi - 1]
xor dl, dh
mov byte [edi + 5], dl
mov edx, dword [esp + 8]
cmp edx, esi
jbe 0x10018244
inc esi
add bl, cl
mov edx, dword [ebp + ebx*4]
mov dword [ebp + eax*4], edx
add edx, ecx
mov dword [ebp + ebx*4], ecx
and edx, 0xff
inc al
mov edx, dword [ebp + edx*4]
mov dh, byte [esi - 1]
xor dl, dh
mov byte [edi + 6], dl
jmp 0x10018244
lea edx, [esi + edx]
mov dword [esp + 8], edx
movzx ecx, byte [ebp + eax]
add bl, cl
movzx edx, byte [ebp + ebx]
mov byte [ebp + ebx], cl
mov byte [ebp + eax], dl
add dl, cl
movzx edx, byte [ebp + edx]
xor dl, byte [esi]
mov byte [edi], dl
inc al
inc esi
inc edi
cmp esi, dword [esp + 8]
jb 0x1001821b
dec eax
add esp, 0xc
mov byte [ebp - 4], bl
mov byte [ebp - 8], al
pop edi
pop esi
pop ebx
pop ebp
ret