Function at 0x409510
Capabilities:
Encode data using xor

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x4c
mov esi, dword [esp + 0x64]
mov eax, dword [esp + 0x60]
mov dword [esp + 0x14], eax
mov eax, dword [ecx + 0x80]
mov dword [esp + 0x18], eax
mov word [esp + 8], 0x383c
mov byte [esp + 0xa], 0x23
mov word [esp + 0xb], 0
xor eax, eax
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov ebx, eax
add bl, 0x69
xor bl, byte [esp + eax + 8]
add bl, 0xb8
mov byte [esp + eax + 8], bl
inc eax
cmp eax, 5
jne 0x409550
mov dword [esp + 0xe], 0x9b9f9981
mov word [esp + 0x12], 0x589d
xor eax, eax
nop
nop
nop
nop
nop
nop
nop
nop
nop
movzx edi, byte [esp + eax + 0xe]
lea ebx, [eax - 0x725dc085]
and ebx, edi
add ebx, ebx
neg ebx
add ebx, eax
add ebx, 0x8da23f7b
add ebx, edi
mov edi, ebx
and edi, 0x27
mov edx, ebx
and edx, 0xd8
add edi, ebx
xor ebx, 0x27
add ebx, edi
sub ebx, edx
inc bl
mov byte [esp + eax + 0xe], bl
lea edx, [eax + eax]
and edx, 2
mov edi, edx
and edi, eax
or edx, eax
xor edx, 1
add edx, edi
mov eax, edx
cmp edx, 6
jb 0x409580
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x22], 0xbc91dbdd
mov dword [esp + 0x26], 0xb9b3a1ba
mov dword [esp + 0x2a], 0xb29ef4ac
mov dword [esp + 0x2e], 0xacb1adaf
mov dword [esp + 0x32], 0x8c8b9589
mov dword [esp + 0x36], 0x81c6df8a
mov dword [esp + 0x3a], 0xc6879b87
mov dword [esp + 0x3e], 0x8e9a8c88
mov dword [esp + 0x42], 0x929cd1cb
mov dword [esp + 0x46], 0xd5cb9099
mov word [esp + 0x4a], 0xf8
mov ebx, 0x4190450
nop
movzx eax, byte [esp + ebx - 0x419042e]
xor eax, ebx
mov edi, eax
and edi, 0x411047d
mov ebp, eax
and ebp, 2
mov ecx, ebp
xor ecx, 2
imul ecx, edi
or edi, 2
imul edi, ebp
xor eax, 0xdf37dd7f
add eax, ecx
add eax, edi
mov ecx, eax
xor ecx, 0xfffffffe
mov edi, eax
or edi, 1
and edi, ecx
mov ecx, edi
and ecx, 0xfd
mov ebp, edi
and ebp, 2
or edi, 2
imul edi, ebp
xor ebp, 2
imul ebp, ecx
xor eax, 1
add eax, edi
add eax, ebp
mov byte [esp + ebx - 0x419042e], al
inc ebx
cmp ebx, 0x419047a
jne 0x409630
mov eax, dword [esp + 0x18]
add dword [esp + 0x14], eax
mov word [esp + 2], 0x4445
mov byte [esp + 4], 0x6a
mov word [esp + 5], 0
mov byte [esp + 7], 0
mov eax, 0x28
mov edi, 0xd7
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
movzx ebx, byte [esp + eax - 0x26]
mov ebp, eax
and ebp, ebx
mov edx, edi
and edx, ebx
mov ecx, eax
xor ecx, ebx
sub ecx, ebx
add ecx, ebp
or ecx, edx
add cl, 0xc0
mov byte [esp + eax - 0x26], cl
inc eax
dec edi
cmp eax, 0x2e
jne 0x4096d0
movzx eax, byte [esp + 2]
mov ebx, dword [esp + 0x14]
mov edi, ebx
test al, al
je 0x40971b
lea ecx, [esp + 3]
mov edi, ebx
nop
nop
nop
nop
nop
nop
mov byte [edi], al
inc edi
movzx eax, byte [ecx]
inc ecx
test al, al
jne 0x409710
mov byte [edi], 0
mov edx, dword [esp + 0x1c]
movzx eax, byte [edx + 0x60]
test al, al
je 0x40973b
lea ecx, [edx + 0x61]
nop
nop
nop
mov byte [edi], al
inc edi
movzx eax, byte [ecx]
inc ecx
test al, al
jne 0x409730
mov byte [edi], 0
movzx eax, byte [esp + 0x22]
test al, al
je 0x40975b
lea ecx, [esp + 0x23]
nop
nop
nop
nop
nop
mov byte [edi], al
inc edi
movzx eax, byte [ecx]
inc ecx
test al, al
jne 0x409750
mov byte [edi], 0
movzx eax, byte [esi]
test al, al
je 0x40977b
inc esi
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov byte [edi], al
inc edi
movzx eax, byte [esi]
inc esi
test al, al
jne 0x409770
mov byte [edi], 0
movzx eax, byte [esp + 0xe]
test al, al
je 0x40979b
lea ecx, [esp + 0xf]
nop
nop
nop
nop
nop
mov byte [edi], al
inc edi
movzx eax, byte [ecx]
inc ecx
test al, al
jne 0x409790
mov byte [edi], 0
mov ecx, dword [esp + 0x68]
movzx eax, byte [ecx]
test al, al
je 0x4097bb
inc ecx
nop
nop
nop
nop
nop
nop
mov byte [edi], al
inc edi
movzx eax, byte [ecx]
inc ecx
test al, al
jne 0x4097b0
mov byte [edi], 0
movzx eax, byte [esp + 8]
test al, al
je 0x4097db
lea ecx, [esp + 9]
nop
nop
nop
nop
nop
mov byte [edi], al
inc edi
movzx eax, byte [ecx]
inc ecx
test al, al
jne 0x4097d0
mov byte [edi], 0
sub edi, ebx
add dword [edx + 0x80], edi
add esp, 0x4c
pop esi
pop edi
pop ebx
pop ebp
ret 0xc