Function at 0x474ba7
Capabilities:
Encode data using xor

Disassembly:
sub esp, 0x90
mov eax, dword [esp + 0x98]
push ebx
mov ebx, dword [esp + 0x98]
push ebp
lea ebp, [eax + 7]
shr ebp, 3
push esi
and eax, 7
push edi
mov dword [esp + 0x2c], ebp
mov dword [esp + 0x24], eax
jne 0x474bda
mov dword [esp + 0x24], 8
xor edx, edx
cmp ebp, 1
mov dword [esp + 0x18], edx
mov dword [esp + 0x14], edx
mov dword [esp + 0x1c], edx
mov dword [esp + 0x20], edx
jbe 0x474d84
xor esi, esi
lea eax, [ebp - 2]
cmp eax, edx
mov dword [esp + 0x28], esi
jbe 0x474d84
nop
cmp esi, edx
mov eax, dword [ebx]
mov ecx, dword [ebx + 4]
mov dword [esp + 0x1c], eax
mov dword [esp + 0x20], ecx
jne 0x474d3a
mov esi, dword [esp + 0xac]
lea edi, [esp + 0x30]
call fcn.004748b7
mov eax, dword [esp + 0x30]
mov esi, dword [esp + 0x34]
mov dword [esp + 0x38], eax
mov edx, 1
jmp 0x474c47
mov edi, dword [esp + edx*4 + 0x34]
lea ecx, [edi + esi]
mov dword [esp + edx*4 + 0x38], ecx
and edi, 0x1f
mov ecx, 0x20
sub ecx, edi
mov ebp, eax
shl ebp, cl
mov ecx, eax
mov dword [esp + 0x10], ecx
mov ecx, edi
mov edi, eax
shr edi, cl
or ebp, edi
xor dword [esp + 0x3c], ebp
mov edi, dword [esp + edx*4 + 0x38]
lea ecx, [edi + esi]
mov dword [esp + edx*4 + 0x3c], ecx
and edi, 0x1f
mov ecx, 0x20
sub ecx, edi
mov ebp, eax
shl ebp, cl
mov ecx, eax
mov dword [esp + 0x10], ecx
mov ecx, edi
mov edi, eax
shr edi, cl
or ebp, edi
xor dword [esp + 0x3c], ebp
mov edi, dword [esp + edx*4 + 0x3c]
lea ecx, [edi + esi]
mov dword [esp + edx*4 + 0x40], ecx
and edi, 0x1f
mov ecx, 0x20
sub ecx, edi
mov ebp, eax
shl ebp, cl
mov ecx, eax
mov dword [esp + 0x10], ecx
mov ecx, edi
mov edi, eax
shr edi, cl
or ebp, edi
xor dword [esp + 0x3c], ebp
mov edi, dword [esp + edx*4 + 0x40]
lea ecx, [edi + esi]
mov dword [esp + edx*4 + 0x44], ecx
and edi, 0x1f
mov ecx, 0x20
sub ecx, edi
mov ebp, eax
shl ebp, cl
mov ecx, eax
mov dword [esp + 0x10], ecx
mov ecx, edi
mov edi, eax
shr edi, cl
or ebp, edi
xor dword [esp + 0x3c], ebp
mov edi, dword [esp + edx*4 + 0x44]
lea ecx, [edi + esi]
mov dword [esp + edx*4 + 0x48], ecx
and edi, 0x1f
mov ecx, 0x20
sub ecx, edi
mov ebp, eax
shl ebp, cl
mov ecx, eax
mov dword [esp + 0x10], ecx
mov ecx, edi
mov edi, eax
shr edi, cl
mov ecx, dword [esp + 0x3c]
or ebp, edi
xor ecx, ebp
add edx, 5
cmp edx, 0x1a
mov dword [esp + 0x3c], ecx
jb 0x474c47
mov ebp, dword [esp + 0x2c]
mov esi, dword [esp + 0x28]
jmp 0x474d49
lea edx, [esp + 0x38]
push edx
mov edi, ebx
call fcn.00472dd7
add esp, 4
mov eax, dword [esp + 0x14]
mov ecx, dword [ebx]
mov edx, dword [esp + 0x1c]
xor ecx, eax
mov eax, dword [ebx + 4]
mov dword [ebx], ecx
mov ecx, dword [esp + 0x18]
xor eax, ecx
mov dword [ebx + 4], eax
mov eax, dword [esp + 0x20]
add ebx, 8
mov dword [esp + 0x18], eax
inc esi
mov dword [esp + 0x14], edx
lea eax, [ebp - 2]
xor edx, edx
cmp esi, eax
mov dword [esp + 0x28], esi
jb 0x474c07
mov ecx, dword [esp + 0x24]
cmp ecx, edx
mov dword [esp + 0x14], edx
mov dword [esp + 0x18], edx
jbe 0x474da9
mov edx, ecx
shr ecx, 2
lea esi, [ebx + 8]
lea edi, [esp + 0x14]
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
cmp ebp, 1
jne 0x474dc1
mov esi, dword [esp + 0xac]
xor edi, edi
call fcn.004748b7
jmp 0x474e45
cmp ebp, 2
jne 0x474dd6
mov esi, dword [esp + 0xac]
xor edi, edi
call fcn.004748b7
jmp 0x474dea
lea eax, [esp + 0x38]
push eax
mov edi, ebx
call fcn.00472dd7
add esp, 4
cmp ebp, 1
jbe 0x474e45
mov edi, dword [esp + 0x14]
mov ecx, dword [ebx]
mov esi, dword [esp + 0x18]
mov edx, dword [ebx + 4]
xor edi, ecx
mov dword [esp + 0x14], edi
mov edi, dword [esp + 0x24]
xor esi, edx
xor eax, eax
test edi, edi
mov dword [esp + 0x18], esi
jbe 0x474e2d
mov ecx, ebx
lea edx, [esp + 0x14]
sub ecx, edx
mov edi, edi
mov dl, byte [ebx + eax + 8]
lea esi, [esp + eax + 0x14]
mov byte [esi + ecx], dl
mov dl, byte [esi]
mov byte [ebx + eax + 8], dl
inc eax
cmp eax, edi
jb 0x474e17
cmp ebp, 2
je 0x474dae
lea eax, [esp + 0x38]
push eax
mov edi, ebx
call fcn.00472dd7
add esp, 4
mov edx, dword [ebx]
mov ecx, dword [esp + 0x1c]
mov eax, dword [ebx + 4]
xor edx, ecx
pop edi
mov dword [ebx], edx
mov edx, dword [esp + 0x1c]
pop esi
xor eax, edx
pop ebp
mov dword [ebx + 4], eax
pop ebx
add esp, 0x90
ret