Function at 0x405ef0
Capabilities:
Encode data using xor

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x2c
mov esi, dword [esp + 0x40]
mov edi, dword [esp + 0x44]
mov ebx, dword [esp + 0x50]
mov edx, dword [esp + 0x54]
mov eax, dword [edx]
mov ebp, dword [esp + 0x58]
test ebp, ebp
jne 0x406060
test eax, eax
je 0x405f74
mov ecx, dword [esp + 0x48]
test ecx, ecx
je 0x406130
mov dword [esp + 0x14], ebx
mov ebx, dword [esp + 0x48]
mov dword [esp + 0x18], ebx
jmp 0x405f4c
mov ecx, dword [esp + 0x18]
test ecx, ecx
je 0x406130
mov edx, dword [esp + 0x14]
add edx, eax
mov cl, byte [esi]
mov bl, byte [edx]
xor ebx, ecx
mov byte [edi], bl
inc edi
inc esi
mov byte [edx], cl
dec dword [esp + 0x18]
inc eax
and eax, 0xf
jne 0x405f40
mov eax, dword [esp + 0x18]
mov dword [esp + 0x48], eax
mov ebx, dword [esp + 0x14]
cmp dword [esp + 0x48], 0xf
jbe 0x406008
mov edx, dword [esp + 0x48]
mov dword [esp + 0x14], edx
xor eax, eax
mov ebp, eax
mov dword [esp + 0x18], esi
mov dword [esp + 0x1c], edi
lea esi, [esi]
lea edi, [edi]
mov edi, dword [esp + 0x1c]
sub edi, ebp
mov esi, dword [esp + 0x18]
sub esi, ebp
mov eax, dword [esp + 0x4c]
mov dword [esp + 8], eax
mov dword [esp + 4], ebx
mov dword [esp], ebx
call dword [esp + 0x5c]
xor eax, eax
mov edx, dword [esi + eax]
mov ecx, dword [ebx + eax]
xor ecx, edx
mov dword [edi + eax], ecx
mov dword [ebx + eax], edx
add eax, 4
cmp eax, 0x10
jne 0x405fc1
sub dword [esp + 0x14], 0x10
sub ebp, 0x10
cmp dword [esp + 0x14], 0xf
ja 0x405fa0
mov esi, dword [esp + 0x18]
mov edi, dword [esp + 0x1c]
mov eax, dword [esp + 0x48]
sub eax, 0x10
mov edx, eax
and edx, 0xf
mov dword [esp + 0x48], edx
and eax, 0xfffffff0
add eax, 0x10
add edi, eax
add esi, eax
mov edx, dword [esp + 0x48]
test edx, edx
je 0x406130
mov eax, dword [esp + 0x4c]
mov dword [esp + 8], eax
mov dword [esp + 4], ebx
mov dword [esp], ebx
call dword [esp + 0x5c]
xor eax, eax
mov ebp, dword [esp + 0x48]
lea esi, [esi]
mov dl, byte [esi + eax]
mov cl, dl
xor cl, byte [ebx + eax]
mov byte [edi + eax], cl
mov byte [ebx + eax], dl
inc eax
cmp eax, ebp
jne 0x406030
mov edx, dword [esp + 0x54]
mov dword [edx], eax
add esp, 0x2c
pop ebx
pop esi
pop edi
pop ebp
ret
test eax, eax
je 0x4060a0
mov edx, dword [esp + 0x48]
test edx, edx
je 0x406130
mov ebp, dword [esp + 0x48]
jmp 0x406088
test ebp, ebp
je 0x406130
lea ecx, [ebx + eax]
mov dl, byte [ecx]
xor dl, byte [esi]
mov byte [ecx], dl
mov byte [edi], dl
inc edi
inc esi
dec ebp
inc eax
and eax, 0xf
jne 0x406080
mov dword [esp + 0x48], ebp
cmp dword [esp + 0x48], 0xf
jbe 0x406127
mov eax, dword [esp + 0x48]
mov dword [esp + 0x14], eax
xor eax, eax
mov dword [esp + 0x18], esi
mov dword [esp + 0x1c], edi
mov edi, eax
nop
mov ebp, dword [esp + 0x1c]
add ebp, edi
mov esi, dword [esp + 0x18]
add esi, edi
mov edx, dword [esp + 0x4c]
mov dword [esp + 8], edx
mov dword [esp + 4], ebx
mov dword [esp], ebx
call dword [esp + 0x5c]
xor eax, eax
mov edx, dword [esi + eax]
xor edx, dword [ebx + eax]
mov dword [ebx + eax], edx
mov dword [ebp + eax], edx
add eax, 4
cmp eax, 0x10
jne 0x4060e1
sub dword [esp + 0x14], 0x10
add edi, 0x10
cmp dword [esp + 0x14], 0xf
ja 0x4060c0
mov esi, dword [esp + 0x18]
mov edi, dword [esp + 0x1c]
mov eax, dword [esp + 0x48]
sub eax, 0x10
mov edx, eax
and edx, 0xf
mov dword [esp + 0x48], edx
and eax, 0xfffffff0
add eax, 0x10
add edi, eax
add esi, eax
mov ebp, dword [esp + 0x48]
test ebp, ebp
jne 0x406140
nop
xor eax, eax
mov edx, dword [esp + 0x54]
mov dword [edx], eax
add esp, 0x2c
pop ebx
pop esi
pop edi
pop ebp
ret
mov eax, dword [esp + 0x4c]
mov dword [esp + 8], eax
mov dword [esp + 4], ebx
mov dword [esp], ebx
call dword [esp + 0x5c]
xor eax, eax
mov ecx, dword [esp + 0x48]
lea esi, [esi]
mov dl, byte [esi + eax]
xor dl, byte [ebx + eax]
mov byte [ebx + eax], dl
mov byte [edi + eax], dl
inc eax
cmp eax, ecx
jne 0x406160
mov edx, dword [esp + 0x54]
mov dword [edx], eax
add esp, 0x2c
pop ebx
pop esi
pop edi
pop ebp
ret