Function at 0x4045a0
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x154
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
movzx eax, byte [esi + 0x68]
mov byte [eax + esi + 0x28], 0x80
mov eax, 0x40
inc byte [esi + 0x68]
movzx ecx, byte [esi + 0x68]
sub eax, ecx
push eax
lea eax, [esi + 0x28]
add eax, ecx
push 0
push eax
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
lea edi, [esi + 0x28]
cmp byte [esi + 0x68], 0x38
jbe 0x40464c
push edi
push esi
call fcn.004043c0
mov dword [esi + 0x28], 0
add esp, 8
mov dword [esi + 0x2c], 0
mov dword [esi + 0x30], 0
mov dword [esi + 0x34], 0
mov dword [esi + 0x38], 0
mov dword [esi + 0x3c], 0
mov dword [esi + 0x40], 0
mov dword [esi + 0x44], 0
mov dword [esi + 0x48], 0
mov dword [esi + 0x4c], 0
mov dword [esi + 0x50], 0
mov dword [esi + 0x54], 0
mov dword [esi + 0x58], 0
mov dword [esi + 0x5c], 0
mov ecx, dword [esi]
mov eax, dword [esi + 4]
shld eax, ecx, 3
shl ecx, 3
mov byte [esi + 0x67], cl
shrd ecx, eax, 8
shr eax, 8
mov byte [esi + 0x66], cl
shrd ecx, eax, 8
shr eax, 8
mov byte [esi + 0x65], cl
shrd ecx, eax, 8
shr eax, 8
mov byte [esi + 0x64], cl
shrd ecx, eax, 8
shr eax, 8
mov byte [esi + 0x63], cl
shrd ecx, eax, 8
shr eax, 8
mov byte [esi + 0x62], cl
shrd ecx, eax, 8
shr eax, 8
mov byte [esi + 0x61], cl
shrd ecx, eax, 8
xor edx, edx
mov byte [esi + 0x60], cl
movzx ecx, byte [edi]
lea edi, [edi + 4]
movzx eax, byte [edi - 3]
shl ecx, 8
or ecx, eax
movzx eax, byte [edi - 2]
shl ecx, 8
or ecx, eax
movzx eax, byte [edi - 1]
shl ecx, 8
or ecx, eax
mov dword [ebp + edx*4 - 0x154], ecx
inc edx
cmp edx, 0x10
jb 0x4046a0
lea ebx, [ebp - 0x11c]
mov esi, 0x30
nop dword [eax]
mov ecx, dword [ebx - 0x34]
lea ebx, [ebx + 4]
mov edx, dword [ebx - 4]
mov edi, ecx
mov eax, ecx
ror edi, 0x12
ror eax, 7
xor edi, eax
shr ecx, 3
xor edi, ecx
mov eax, edx
mov ecx, edx
ror eax, 0x11
ror ecx, 0x13
xor ecx, eax
shr edx, 0xa
xor ecx, edx
add edi, ecx
add edi, dword [ebx - 0x3c]
add edi, dword [ebx - 0x18]
mov dword [ebx + 4], edi
sub esi, 1
jne 0x4046e0
mov esi, dword [ebp + 8]
mov edx, dword [esi + 0x14]
mov eax, dword [esi + 8]
mov ecx, dword [esi + 0x10]
mov dword [ebp - 0x38], edx
mov dword [ebp - 0x1c], edx
mov edx, dword [esi + 0x18]
mov ebx, edx
mov dword [ebp - 0x3c], edx
mov edx, dword [esi + 0x1c]
mov edi, edx
mov dword [ebp - 0x44], edx
mov edx, dword [esi + 0x20]
mov dword [ebp - 0x4c], edx
mov dword [ebp - 4], edx
mov edx, dword [esi + 0x24]
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x54], edx
mov dword [ebp - 0x18], edx
xor edx, edx
mov dword [ebp - 0x24], eax
mov eax, dword [esi + 0xc]
mov esi, dword [ebp - 0x14]
mov dword [ebp - 0x28], eax
mov dword [ebp - 0xc], eax
mov dword [ebp - 0x30], ecx
mov dword [ebp - 8], ecx
mov dword [ebp - 0x10], edi
mov dword [ebp - 0x20], edx
nop
mov eax, dword [ebp - 4]
mov dword [ebp - 0x50], eax
mov eax, dword [ebp - 0xc]
mov dword [ebp - 0x2c], eax
mov eax, ebx
ror eax, 0xb
mov dword [ebp - 0x48], edi
mov edi, ebx
ror edi, 0x19
xor edi, eax
mov dword [ebp - 0x34], ecx
mov eax, ebx
mov dword [ebp - 0x14], esi
ror eax, 6
mov ecx, ebx
xor edi, eax
mov dword [ebp - 0x40], ebx
mov eax, dword [ebp - 0x10]
not ecx
and ecx, dword [ebp - 4]
and eax, ebx
xor ecx, eax
mov eax, esi
add edi, ecx
ror eax, 0xd
add edi, dword [edx + 0x4083a8]
add edi, dword [ebp + edx - 0x154]
mov edx, esi
add edi, dword [ebp - 0x18]
ror edx, 0x16
xor edx, eax
mov eax, esi
ror eax, 2
xor edx, eax
mov eax, dword [ebp - 0xc]
mov ecx, eax
and eax, dword [ebp - 8]
xor ecx, dword [ebp - 8]
and ecx, esi
xor ecx, eax
mov eax, dword [ebp - 4]
add edx, ecx
mov dword [ebp - 0x18], eax
mov ecx, dword [ebp - 0xc]
mov eax, dword [ebp - 0x10]
mov dword [ebp - 0x10], ebx
mov ebx, dword [ebp - 0x1c]
mov dword [ebp - 0xc], esi
add ebx, edi
lea esi, [edx + edi]
mov dword [ebp - 4], eax
mov edx, dword [ebp - 0x20]
mov eax, dword [ebp - 8]
add edx, 4
mov edi, dword [ebp - 0x10]
mov dword [ebp - 0x1c], eax
mov dword [ebp - 8], ecx
mov dword [ebp - 0x20], edx
cmp edx, 0x100
jb 0x404770
mov eax, dword [ebp - 0x24]
add eax, esi
mov esi, dword [ebp + 8]
pop edi
mov dword [esi + 8], eax
mov eax, dword [ebp - 0x14]
add eax, dword [ebp - 0x28]
mov dword [esi + 0xc], eax
mov eax, dword [ebp - 0x2c]
add eax, dword [ebp - 0x30]
mov dword [esi + 0x10], eax
mov eax, dword [ebp - 0x34]
add eax, dword [ebp - 0x38]
mov dword [esi + 0x14], eax
mov eax, dword [ebp - 0x3c]
add eax, ebx
mov dword [esi + 0x18], eax
mov eax, dword [ebp - 0x40]
add eax, dword [ebp - 0x44]
mov dword [esi + 0x1c], eax
mov eax, dword [ebp - 0x48]
add eax, dword [ebp - 0x4c]
mov dword [esi + 0x20], eax
mov eax, dword [ebp - 0x50]
add eax, dword [ebp - 0x54]
mov dword [esi + 0x24], eax
pop esi
pop ebx
mov esp, ebp
pop ebp
ret