Function at 0x4c2970
Capabilities:
Encode data using xor

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x24
mov ebp, dword [esp + 0x38]
mov edi, dword [esp + 0x48]
mov esi, 0xffffffe0
mov ebx, 0xf
mov edx, dword [ebp + 0x38]
mov ecx, dword [ebp + 0x3c]
add edx, edi
adc ecx, 0
xor eax, eax
cmp esi, edx
sbb ebx, ecx
jb 0x4c3005
mov dword [ebp + 0x38], edx
mov dword [ebp + 0x3c], ecx
cmp dword [ebp + 0x174], 0
je 0x4c2a8b
movzx ebx, byte [ebp + 0x4f]
mov edi, ebp
mov dword [esp], 0
mov esi, ebx
and esi, 0xf
shl esi, 4
mov eax, dword [ebp + esi + 0x60]
mov ecx, dword [ebp + esi + 0x64]
mov edx, dword [ebp + esi + 0x6c]
mov ebp, dword [ebp + esi + 0x68]
nop dword [eax + eax]
mov esi, ecx
and ebx, 0xfffffff0
shr ecx, 4
xor ecx, dword [edi + ebx + 0x64]
shld esi, eax, 0x1c
shld eax, edx, 0x1c
shld edx, ebp, 0x1c
and ebp, 0xf
xor esi, dword [edi + ebx + 0x60]
xor eax, dword [edi + ebx + 0x6c]
xor edx, dword [edi + ebx + 0x68]
xor ecx, dword [ebp*4 + 0x520ab4]
cmp dword [esp], 0xfffffff1
mov ebp, edi
je 0x4c2a69
mov edi, dword [esp]
dec dword [esp]
movzx ebx, byte [ebp + edi + 0x4e]
mov edi, ebp
mov ebp, ebx
mov dword [esp + 4], ebx
mov ebx, ecx
shr ecx, 4
and ebp, 0xf
shld ebx, esi, 0x1c
shld esi, eax, 0x1c
shld eax, edx, 0x1c
and edx, 0xf
shl ebp, 4
xor ecx, dword [edi + ebp + 0x64]
xor ebx, dword [edi + ebp + 0x60]
xor eax, dword [edi + ebp + 0x68]
xor esi, dword [edi + ebp + 0x6c]
xor ecx, dword [edx*4 + 0x520ab4]
mov ebp, eax
mov eax, ebx
mov ebx, dword [esp + 4]
mov edx, esi
jmp 0x4c29e0
mov edi, dword [esp + 0x48]
bswap ecx
bswap esi
bswap eax
bswap edx
mov dword [ebp + 0x44], esi
mov dword [ebp + 0x40], ecx
mov dword [ebp + 0x4c], edx
mov dword [ebp + 0x48], eax
mov dword [ebp + 0x174], 0
mov eax, dword [ebp + 0x170]
mov ebx, dword [esp + 0x44]
mov edx, dword [esp + 0x40]
test eax, eax
je 0x4c2bcd
test edi, edi
je 0x4c2ffa
nop dword [eax]
movzx ecx, byte [ebp + eax + 0x10]
xor cl, byte [edx]
inc edx
mov byte [ebx], cl
xor byte [ebp + eax + 0x40], cl
inc eax
inc ebx
and eax, 0xf
cmp edi, 1
lea edi, [edi - 1]
je 0x4c2acf
test eax, eax
jne 0x4c2ab0
test eax, eax
jne 0x4c2ffa
movzx esi, byte [ebp + 0x4f]
mov dword [esp + 8], edx
mov dword [esp + 0x14], edi
mov dword [esp + 4], 0
mov dword [esp + 0xc], ebx
mov dword [esp], esi
and esi, 0xf
shl esi, 4
mov eax, dword [ebp + esi + 0x60]
mov ecx, dword [ebp + esi + 0x64]
mov edx, dword [ebp + esi + 0x6c]
mov ebp, dword [ebp + esi + 0x68]
nop dword [eax + eax]
mov esi, dword [esp]
and esi, 0xfffffff0
mov edi, esi
mov dword [esp], esi
mov esi, ecx
shr ecx, 4
shld esi, eax, 0x1c
shld eax, edx, 0x1c
shld edx, ebp, 0x1c
and ebp, 0xf
mov dword [esp + 0x10], ebp
mov ebp, dword [esp + 0x38]
xor ecx, dword [ebp + edi + 0x64]
mov edi, dword [esp + 0x10]
xor ecx, dword [edi*4 + 0x520ab4]
mov edi, dword [esp]
xor esi, dword [ebp + edi + 0x60]
xor eax, dword [ebp + edi + 0x6c]
xor edx, dword [ebp + edi + 0x68]
cmp dword [esp + 4], 0xfffffff1
je 0x4c2bb1
mov edi, dword [esp + 4]
mov ebx, ecx
shr ecx, 4
dec dword [esp + 4]
shld ebx, esi, 0x1c
shld esi, eax, 0x1c
shld eax, edx, 0x1c
and edx, 0xf
movzx edi, byte [ebp + edi + 0x4e]
mov dword [esp], edi
mov edi, ebp
mov ebp, dword [esp]
and ebp, 0xf
shl ebp, 4
xor ecx, dword [edi + ebp + 0x64]
xor ebx, dword [edi + ebp + 0x60]
xor eax, dword [edi + ebp + 0x68]
xor esi, dword [edi + ebp + 0x6c]
xor ecx, dword [edx*4 + 0x520ab4]
mov ebp, eax
mov eax, ebx
mov ebx, dword [esp + 0xc]
mov edx, esi
jmp 0x4c2b10
bswap ecx
bswap esi
bswap edx
mov edi, dword [esp + 0x14]
bswap eax
mov dword [ebp + 0x44], esi
mov dword [ebp + 0x40], ecx
mov dword [ebp + 0x4c], edx
mov edx, dword [esp + 8]
mov dword [ebp + 0x48], eax
mov eax, dword [ebp + 0xc]
cmp edi, 0xc00
bswap eax
mov dword [esp + 0x18], eax
jae 0x4c2c1a
jmp 0x4c2d5d
mov edi, dword [esp + 0x14]
mov ebx, dword [esp + 0xc]
mov edx, dword [esp + 8]
add edi, 0xfffff400
add ebx, 0xc00
add edx, 0xc00
cmp edi, 0xbff
jbe 0x4c2d5d
mov dword [esp + 0x14], edi
push ebp
push dword [esp + 0x40]
push 0xc0
push ebx
mov dword [esp + 0x18], edx
push edx
call dword [esp + 0x60]
add esp, 0x14
mov eax, dword [esp + 0x18]
mov dword [esp + 0xc], ebx
add eax, 0xc0
mov dword [esp + 0x18], eax
bswap eax
mov dword [ebp + 0xc], eax
mov eax, 0xc00
mov dl, byte [ebp + 0x4f]
jmp 0x4c2c91
mov ebx, dword [esp + 0x10]
mov ecx, dword [esp + 0x38]
mov eax, dword [esp + 0x1c]
bswap esi
bswap ebp
bswap edx
bswap edi
mov dword [ecx + 0x44], ebp
mov dword [ecx + 0x40], esi
mov dword [ecx + 0x4c], edx
add ebx, 0x10
shr edx, 0x18
add eax, 0xfffffff0
mov ebp, ecx
mov dword [ecx + 0x48], edi
je 0x4c2bf0
xor dl, byte [ebx + 0xf]
mov dword [esp + 0x10], ebx
mov dword [esp + 0x1c], eax
mov dword [esp], 0
movzx ebx, dl
mov eax, ebx
and eax, 0xf
shl eax, 4
mov edi, dword [ebp + eax + 0x60]
mov esi, dword [ebp + eax + 0x64]
mov edx, dword [ebp + eax + 0x6c]
mov ecx, dword [ebp + eax + 0x68]
nop
mov eax, dword [esp + 0x38]
mov ebp, esi
and ebx, 0xfffffff0
shr esi, 4
shld ebp, edi, 0x1c
shld edi, edx, 0x1c
shld edx, ecx, 0x1c
and ecx, 0xf
xor esi, dword [eax + ebx + 0x64]
xor ebp, dword [eax + ebx + 0x60]
xor edi, dword [eax + ebx + 0x6c]
xor edx, dword [eax + ebx + 0x68]
xor esi, dword [ecx*4 + 0x520ab4]
cmp dword [esp], 0xfffffff1
je 0x4c2c60
mov eax, dword [esp + 0x10]
mov ecx, dword [esp]
mov ebx, dword [esp + 0x38]
movzx ecx, byte [eax + ecx + 0xe]
mov eax, dword [esp]
dec dword [esp]
xor cl, byte [ebx + eax + 0x4e]
mov eax, esi
shr esi, 4
shld eax, ebp, 0x1c
shld ebp, edi, 0x1c
shld edi, edx, 0x1c
and edx, 0xf
movzx ecx, cl
mov dword [esp + 4], ecx
and ecx, 0xf
shl ecx, 4
xor esi, dword [ebx + ecx + 0x64]
xor eax, dword [ebx + ecx + 0x60]
xor ebp, dword [ebx + ecx + 0x6c]
xor edi, dword [ebx + ecx + 0x68]
mov ebx, dword [esp + 4]
xor esi, dword [edx*4 + 0x520ab4]
mov ecx, edi
mov edx, ebp
mov edi, eax
jmp 0x4c2cc0
mov eax, edi
and eax, 0xfffffff0
je 0x4c2ec1
mov esi, edi
mov dword [esp + 0x14], edi
shr esi, 4
push ebp
push dword [esp + 0x40]
push esi
push ebx
push edx
mov edi, edx
mov dword [esp + 0x34], eax
call dword [esp + 0x60]
add esp, 0x14
mov eax, dword [esp + 0x18]
mov dword [esp + 0xc], ebx
add eax, esi
mov dword [esp + 0x18], eax
bswap eax
mov dword [ebp + 0xc], eax
mov eax, dword [esp + 0x20]
mov dl, byte [ebp + 0x4f]
add edi, eax
mov dword [esp + 8], edi
jmp 0x4c2de1
mov ebx, dword [esp + 0x10]
mov ecx, dword [esp + 0x38]
mov eax, dword [esp + 0x1c]
bswap ebp
bswap esi
bswap edx
bswap edi
mov dword [ecx + 0x40], ebp
mov dword [ecx + 0x44], esi
mov dword [ecx + 0x4c], edx
add ebx, 0x10
shr edx, 0x18
add eax, 0xfffffff0
mov ebp, ecx
mov dword [ecx + 0x48], edi
je 0x4c2ead
xor dl, byte [ebx + 0xf]
mov dword [esp + 0x10], ebx
mov dword [esp + 0x1c], eax
mov ecx, ebp
mov dword [esp], 0
movzx ebx, dl
mov eax, ebx
and eax, 0xf
shl eax, 4
mov edi, dword [ebp + eax + 0x60]
mov ebp, dword [ebp + eax + 0x64]
mov edx, dword [ecx + eax + 0x6c]
mov eax, dword [ecx + eax + 0x68]
mov ecx, dword [esp + 0x38]
mov esi, ebp
and ebx, 0xfffffff0
shr ebp, 4
shld esi, edi, 0x1c
shld edi, edx, 0x1c
shld edx, eax, 0x1c
and eax, 0xf
xor ebp, dword [ecx + ebx + 0x64]
xor esi, dword [ecx + ebx + 0x60]
xor edi, dword [ecx + ebx + 0x6c]
xor edx, dword [ecx + ebx + 0x68]
xor ebp, dword [eax*4 + 0x520ab4]
cmp dword [esp], 0xfffffff1
je 0x4c2db0
mov eax, dword [esp + 0x10]
mov ecx, dword [esp]
mov ebx, dword [esp + 0x38]
movzx eax, byte [eax + ecx + 0xe]
mov ecx, dword [esp]
dec dword [esp]
xor al, byte [ebx + ecx + 0x4e]
mov ecx, ebp
shr ebp, 4
shld ecx, esi, 0x1c
shld esi, edi, 0x1c
shld edi, edx, 0x1c
and edx, 0xf
movzx eax, al
mov dword [esp + 4], eax
and eax, 0xf
shl eax, 4
xor ebp, dword [ebx + eax + 0x64]
xor ecx, dword [ebx + eax + 0x60]
xor esi, dword [ebx + eax + 0x6c]
xor edi, dword [ebx + eax + 0x68]
mov ebx, dword [esp + 4]
xor ebp, dword [edx*4 + 0x520ab4]
mov eax, edi
mov edx, esi
mov edi, ecx
jmp 0x4c2e10
mov edi, dword [esp + 0x14]
mov eax, dword [esp + 0x20]
mov ebx, dword [esp + 0xc]
mov edx, dword [esp + 8]
sub edi, eax
add ebx, eax
test edi, edi
je 0x4c2ff8
mov dword [esp + 0xc], ebx
lea ebx, [ebp + 0x10]
mov dword [esp + 8], edx
push dword [esp + 0x3c]
push ebx
push ebp
call dword [ebp + 0x168]
add esp, 0xc
mov eax, dword [esp + 0x18]
mov edx, 0
mov ecx, edi
inc eax
bswap eax
mov dword [ebp + 0xc], eax
xor eax, eax
cmp edi, 0x10
jb 0x4c2fcb
mov ecx, dword [esp + 0xc]
lea esi, [ebp + edi + 0x40]
mov dword [esp + 0x14], edi
mov dword [esp + 4], esi
lea edx, [ecx + edi]
cmp ecx, esi
mov edi, dword [esp + 0x14]
mov dword [esp + 0x1c], edx
mov edx, dword [esp + 8]
setb byte [esp]
mov esi, dword [esp + 0x1c]
add edi, edx
cmp esi, ebx
seta byte [esp + 0x10]
cmp ecx, edi
setb byte [esp + 0x18]
cmp edx, esi
mov cl, byte [esp + 0x10]
setb byte [esp + 0x1c]
cmp edi, ebx
mov edi, dword [esp + 0x14]
seta bl
cmp edx, dword [esp + 4]
mov edx, 0
setb bh
test byte [esp], cl
mov ecx, edi
jne 0x4c2fcb
mov cl, byte [esp + 0x1c]
mov edx, 0
and byte [esp + 0x18], cl
mov ecx, edi
jne 0x4c2fcb
and bl, bh
mov edx, 0
mov ecx, edi
jne 0x4c2fcb
mov edx, edi
mov ecx, edi
mov ebx, dword [esp + 0xc]
xor esi, esi
and edx, 0xfffffff0
sub ecx, edx
mov dword [esp], ecx
mov ecx, dword [esp + 8]
nop word cs:[eax + eax]
nop dword [eax + eax]
movups xmm0, xmmword [ecx + esi]
movups xmm1, xmmword [ebp + esi + 0x10]
xorps xmm1, xmm0
movups xmmword [ebx + esi], xmm1
movups xmm0, xmmword [ebp + esi + 0x40]
xorps xmm0, xmm1
movups xmmword [ebp + esi + 0x40], xmm0
add esi, 0x10
cmp edx, esi
jne 0x4c2fa0
mov ecx, dword [esp]
cmp edi, edx
je 0x4c2ff4
mov ebx, dword [esp + 0xc]
mov dword [esp], ecx
mov ecx, dword [esp + 8]
lea esi, [ebp + edx + 0x40]
add ecx, edx
add ebx, edx
nop
movzx edx, byte [esi + eax - 0x30]
xor dl, byte [ecx + eax]
mov byte [ebx + eax], dl
xor byte [esi + eax], dl
inc eax
cmp dword [esp], eax
jne 0x4c2fe0
mov eax, edi
jmp 0x4c2ffa
xor eax, eax
mov dword [ebp + 0x170], eax
mov eax, 1
add esp, 0x24
pop esi
pop edi
pop ebx
pop ebp
ret