Function at 0x40a6b0
Capabilities:
Encode data using xor

Disassembly:
push ebx
push edi
push esi
sub esp, 0x58
mov eax, dword [esp + 0x68]
add eax, dword [ecx + 0x60]
mov dword [esp + 8], 0x26d9d3
mov dword [esp + 0xc], 0
mov edx, dword [esp + 0xc]
cmp edx, 3
ja 0x40a715
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov edx, dword [esp + 0xc]
mov esi, dword [esp + 0xc]
movzx esi, byte [esp + esi + 8]
add edx, 0xde12f85b
xor edx, esi
mov dword [esp + 0x18], edx
mov edx, dword [esp + 0x18]
add dl, 0x85
mov esi, dword [esp + 0xc]
mov byte [esp + esi + 8], dl
inc dword [esp + 0xc]
mov edx, dword [esp + 0xc]
cmp edx, 4
jb 0x40a6e0
mov dword [esp + 0xc], 0xe1e1ef9b
mov word [esp + 0x10], 0xf6ef
mov dword [esp + 0x12], 0
mov dword [esp], 0
mov edx, dword [esp]
cmp edx, 9
ja 0x40a770
nop
nop
nop
nop
nop
mov edx, dword [esp]
mov esi, dword [esp]
movzx esi, byte [esp + esi + 0xc]
add edx, 0x6066a655
xor edx, esi
mov dword [esp + 0x18], edx
mov edx, dword [esp + 0x18]
add dl, 0x54
mov esi, dword [esp]
mov byte [esp + esi + 0xc], dl
inc dword [esp]
mov edx, dword [esp]
cmp edx, 0xa
jb 0x40a740
mov dword [esp + 0x18], 0xf4f2c2c3
mov dword [esp + 0x1c], 0xf0f0c6da
mov dword [esp + 0x20], 0xed988ec3
mov dword [esp + 0x24], 0xe895e895
mov dword [esp + 0x28], 0xd0e59d9c
mov dword [esp + 0x2c], 0x9ac7393f
mov dword [esp + 0x30], 0xa7dd9398
mov dword [esp + 0x34], 0xa4f8e6ae
mov dword [esp + 0x38], 0xa2afafad
mov dword [esp + 0x3c], 0xaaada7ab
mov dword [esp + 0x40], 0xcf08fda8
mov dword [esp + 0x44], 0xf0b1b9b5
mov dword [esp + 0x48], 0xc0b4ceca
mov dword [esp + 0x4c], 0xc4ba03e9
mov dword [esp + 0x50], 0xfb15c2bb
mov byte [esp + 0x54], 0xda
mov word [esp + 0x55], 0
mov byte [esp + 0x57], 0
mov dword [esp + 4], 0
mov edx, dword [esp + 4]
cmp edx, 0x3f
ja 0x40a858
nop
nop
nop
nop
nop
nop
mov edx, dword [esp + 4]
mov esi, dword [esp + 4]
movzx esi, byte [esp + esi + 0x18]
lea edi, [edx - 0x3968cb3a]
lea ebx, [edx + esi]
add ebx, 0xc69734c6
add edx, 0xc6
or edx, edi
and edx, esi
add edx, edx
sub ebx, edx
mov dword [esp], ebx
mov edx, dword [esp]
add dl, 0x28
mov esi, dword [esp + 4]
mov byte [esp + esi + 0x18], dl
inc dword [esp + 4]
mov edx, dword [esp + 4]
cmp edx, 0x40
jb 0x40a810
mov esi, dword [esp + 0x6c]
movzx ebx, byte [esp + 0x18]
mov edx, eax
test bl, bl
je 0x40a87b
lea edi, [esp + 0x19]
mov edx, eax
nop
nop
nop
mov byte [edx], bl
inc edx
movzx ebx, byte [edi]
inc edi
test bl, bl
jne 0x40a870
mov byte [edx], 0
movzx ebx, byte [esi]
test bl, bl
je 0x40a89b
inc esi
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov byte [edx], bl
inc edx
movzx ebx, byte [esi]
inc esi
test bl, bl
jne 0x40a890
mov esi, dword [esp + 0x70]
mov byte [edx], 0
movzx ebx, byte [esp + 0xc]
test bl, bl
je 0x40a8bb
lea edi, [esp + 0xd]
nop
mov byte [edx], bl
inc edx
movzx ebx, byte [edi]
inc edi
test bl, bl
jne 0x40a8b0
mov byte [edx], 0
movzx ebx, byte [esi]
test bl, bl
je 0x40a8db
inc esi
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov byte [edx], bl
inc edx
movzx ebx, byte [esi]
inc esi
test bl, bl
jne 0x40a8d0
mov byte [edx], 0
movzx ebx, byte [esp + 8]
test bl, bl
je 0x40a8fb
lea esi, [esp + 9]
nop
nop
nop
nop
nop
mov byte [edx], bl
inc edx
movzx ebx, byte [esi]
inc esi
test bl, bl
jne 0x40a8f0
mov byte [edx], 0
sub edx, eax
mov eax, dword [ecx + 0x60]
mov esi, eax
and esi, edx
xor edx, eax
lea eax, [edx + esi*2]
mov dword [ecx + 0x60], eax
add esp, 0x58
pop esi
pop edi
pop ebx
ret 0xc