Function at 0x101564c0
Capabilities:
Encode data using xor

Disassembly:
mov eax, 0x2c
call fcn.101ebae0
mov eax, dword [0x102ab2c0]
xor eax, esp
mov dword [esp + 0x28], eax
push ebx
push esi
mov esi, dword [esp + 0x38]
push edi
mov edi, dword [esp + 0x44]
mov dword [esp + 0x18], edi
mov bl, byte [esi]
mov ecx, dword [esi + 0x28]
mov eax, dword [esi + 0x2c]
mov byte [esp + 0xf], bl
mov dword [esp + 0x10], ecx
mov dword [esp + 0x14], eax
test bl, 0x40
jne 0x10156508
push eax
lea eax, [esi + 0x10]
push eax
push esi
call ecx
add esp, 0xc
movzx eax, bl
mov edx, 0xf
and eax, 7
xor ecx, ecx
sub edx, eax
mov dword [esp + 0x20], eax
mov byte [esi], al
cmp edx, 0xf
jae 0x10156535
movzx eax, byte [esi + edx]
or ecx, eax
mov byte [esi + edx], 0
inc edx
shl ecx, 8
cmp edx, 0xf
jb 0x10156522
movzx eax, byte [esi + 0xf]
mov ebx, dword [esp + 0x48]
or ecx, eax
mov byte [esi + 0xf], 1
cmp ecx, ebx
je 0x1015655c
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov ecx, dword [esp + 0x28]
xor ecx, esp
call fcn.101ebfaa
add esp, 0x2c
ret
push ebp
mov ebp, dword [esp + 0x44]
cmp ebx, 0x10
jb 0x10156601
mov edi, 0xfffffff8
mov eax, ebx
sub edi, esi
shr eax, 4
mov dword [esp + 0x20], eax
nop word [eax + eax]
push dword [esp + 0x18]
lea eax, [esp + 0x2c]
push eax
push esi
call dword [esp + 0x20]
add esp, 0xc
lea eax, [esi + 0x10]
add byte [eax - 1], 1
lea eax, [eax - 1]
jne 0x101565a4
lea ecx, [edi + eax]
test ecx, ecx
jne 0x10156594
mov eax, dword [ebp + 4]
mov edx, dword [esp + 0x1c]
xor eax, dword [esp + 0x2c]
mov ecx, dword [esp + 0x28]
xor ecx, dword [ebp]
push dword [esp + 0x18]
mov dword [edx + 4], eax
mov dword [edx], ecx
xor dword [esi + 0x14], eax
xor dword [esi + 0x10], ecx
mov eax, dword [ebp + 0xc]
mov ecx, dword [esp + 0x34]
xor ecx, dword [ebp + 8]
xor eax, dword [esp + 0x38]
mov dword [edx + 0xc], eax
mov dword [edx + 8], ecx
xor dword [esi + 0x1c], eax
lea eax, [esi + 0x10]
xor dword [esi + 0x18], ecx
push eax
push eax
call dword [esp + 0x20]
add dword [esp + 0x28], 0x10
add esp, 0xc
add ebp, 0x10
sub ebx, 0x10
sub dword [esp + 0x20], 1
jne 0x10156580
mov edi, dword [esp + 0x1c]
test ebx, ebx
je 0x10156654
push dword [esp + 0x18]
lea eax, [esp + 0x2c]
push eax
push esi
call dword [esp + 0x20]
add esp, 0xc
test ebx, ebx
je 0x1015663f
lea ecx, [esp + 0x28]
mov eax, ecx
lea edx, [esi + 0x10]
sub ebp, eax
sub edi, eax
mov al, byte [ecx + ebp]
lea ecx, [ecx + 1]
xor al, byte [ecx - 1]
lea edx, [edx + 1]
mov byte [edi + ecx - 1], al
xor byte [edx - 1], al
sub ebx, 1
jne 0x10156627
mov ebp, dword [esp + 0x18]
lea eax, [esi + 0x10]
mov ebx, dword [esp + 0x14]
push ebp
push eax
push eax
call ebx
add esp, 0xc
jmp 0x1015665c
mov ebx, dword [esp + 0x14]
mov ebp, dword [esp + 0x18]
mov ecx, 0xf
sub ecx, dword [esp + 0x24]
cmp ecx, 0x10
jae 0x10156680
mov eax, 0x10
sub eax, ecx
push eax
lea eax, [ecx + esi]
push 0
push eax
call fcn.101eec70
add esp, 0xc
push ebp
lea eax, [esp + 0x2c]
push eax
push esi
call ebx
mov eax, dword [esp + 0x34]
add esp, 0xc
xor dword [esi + 0x10], eax
mov eax, dword [esp + 0x2c]
xor dword [esi + 0x14], eax
mov eax, dword [esp + 0x30]
xor dword [esi + 0x18], eax
mov eax, dword [esp + 0x34]
xor dword [esi + 0x1c], eax
mov al, byte [esp + 0x13]
mov ecx, dword [esp + 0x38]
pop ebp
pop edi
mov byte [esi], al
xor eax, eax
pop esi
pop ebx
xor ecx, esp
call fcn.101ebfaa
add esp, 0x2c
ret