Function at 0x409170
Capabilities:
Encode data using xor

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x54
mov esi, dword [esp + 0x6c]
mov dword [esp + 0x20], ecx
mov eax, dword [ecx + 0x80]
mov dword [esp + 0x1c], eax
mov word [esp + 8], 0x1715
mov byte [esp + 0xa], 0xe
mov word [esp + 0xb], 0
xor ebx, ebx
nop
nop
movzx eax, byte [esp + ebx + 8]
lea edi, [ebx - 0x637e3b7e]
mov ecx, 0x7d
sub ecx, ebx
xor ecx, edi
and ecx, eax
xor ecx, edi
lea eax, [ecx - 0xe88d68b]
mov edi, eax
xor edi, 0xfe
mov ebp, eax
or ebp, 1
and ebp, edi
mov edi, eax
and edi, 0xfe
xor eax, 1
add eax, ecx
add eax, 0xf1772975
sub eax, edi
add eax, ebp
mov byte [esp + ebx + 8], al
mov eax, ebx
and eax, 1
xor ebx, 1
lea ebx, [ebx + eax*2]
cmp ebx, 5
jb 0x4091a0
mov dword [esp + 0x10], 0x8a8488a2
mov word [esp + 0x14], 0xbf86
mov dword [esp + 0x16], 0
mov byte [esp + 0x1a], 0
mov edi, 0x91e7ce5f
nop
nop
nop
nop
nop
nop
nop
nop
movzx ecx, byte [esp + edi + 0x6e1831b1]
xor ecx, edi
lea eax, [ecx + ecx]
mov ebx, eax
and ebx, 0x48
xor ecx, 0x24
add ecx, ebx
and eax, 2
xor ecx, 1
add ecx, eax
mov byte [esp + edi + 0x6e1831b1], cl
inc edi
cmp edi, 0x91e7ce6a
jne 0x409220
mov dword [esp + 0x24], 0x805b2523
mov dword [esp + 0x28], 0x8b75878e
mov dword [esp + 0x2c], 0x92524880
mov dword [esp + 0x30], 0x989b9b9d
mov dword [esp + 0x34], 0x90959b97
mov dword [esp + 0x38], 0x6322499e
mov dword [esp + 0x3c], 0x66999595
mov dword [esp + 0x40], 0x5eae585c
mov dword [esp + 0x44], 0x52a01f71
mov dword [esp + 0x48], 0x177d54af
mov byte [esp + 0x4c], 0x34
mov dword [esp + 0x4d], 0
mov dword [esp + 0x50], 0
mov ebx, 0xf9ab0905
mov ebp, 0x654f6fa
nop
nop
movzx ecx, byte [esp + ebx + 0x654f71f]
mov edi, ecx
not edi
and edi, ebx
mov edx, ebx
xor edx, ecx
mov eax, edx
sub eax, edi
add eax, ebx
and ecx, ebx
sub edi, edx
add edi, ebp
and edi, ecx
not ecx
and ecx, eax
sub ecx, edi
lea eax, [ecx + 0xe6]
mov edx, 0x19
sub edx, ecx
and ecx, 1
and edx, 0x53
and eax, 0xac
or eax, edx
xor eax, 0x52
lea eax, [eax + ecx*2]
mov byte [esp + ebx + 0x654f71f], al
inc ebx
dec ebp
cmp ebx, 0xf9ab0935
jne 0x4092c0
mov ebp, dword [esp + 0x68]
add ebp, dword [esp + 0x1c]
mov word [esp], 0x6857
mov byte [esp + 2], 0xba
mov word [esp + 3], 0
mov ecx, 0x91a2b65f
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
movzx eax, byte [esp + ecx + 0x6e5d49a1]
xor eax, ecx
mov edx, eax
and edx, 1
xor eax, 1
lea eax, [eax + edx*2]
add al, 0x24
mov byte [esp + ecx + 0x6e5d49a1], al
inc ecx
cmp ecx, 0x91a2b664
jne 0x409340
movzx ecx, byte [esp]
mov edi, ebp
test cl, cl
je 0x40938b
lea ebx, [esp + 1]
mov edi, ebp
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov byte [edi], cl
inc edi
movzx ecx, byte [ebx]
inc ebx
test cl, cl
jne 0x409380
mov byte [edi], 0
mov eax, dword [esp + 0x20]
movzx ecx, byte [eax + 0x60]
test cl, cl
je 0x4093bd
lea ebx, [eax + 0x61]
mov edx, dword [esp + 0x70]
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov byte [edi], cl
inc edi
movzx ecx, byte [ebx]
inc ebx
test cl, cl
jne 0x4093b0
jmp 0x4093c1
mov edx, dword [esp + 0x70]
mov byte [edi], 0
movzx ecx, byte [esp + 0x24]
test cl, cl
je 0x4093eb
lea ebx, [esp + 0x25]
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov byte [edi], cl
inc edi
movzx ecx, byte [ebx]
inc ebx
test cl, cl
jne 0x4093e0
mov byte [edi], 0
movzx ecx, byte [esi]
test cl, cl
je 0x40940b
inc esi
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov byte [edi], cl
inc edi
movzx ecx, byte [esi]
inc esi
test cl, cl
jne 0x409400
mov byte [edi], 0
movzx ecx, byte [esp + 0x10]
test cl, cl
je 0x40942b
lea esi, [esp + 0x11]
nop
nop
nop
nop
nop
mov byte [edi], cl
inc edi
movzx ecx, byte [esi]
inc esi
test cl, cl
jne 0x409420
mov byte [edi], 0
movzx ecx, byte [edx]
test cl, cl
je 0x40944b
inc edx
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov byte [edi], cl
inc edi
movzx ecx, byte [edx]
inc edx
test cl, cl
jne 0x409440
mov byte [edi], 0
movzx ecx, byte [esp + 8]
test cl, cl
je 0x40946b
lea edx, [esp + 9]
nop
nop
nop
nop
nop
mov byte [edi], cl
inc edi
movzx ecx, byte [edx]
inc edx
test cl, cl
jne 0x409460
mov byte [edi], 0
sub edi, ebp
add dword [eax + 0x80], edi
add esp, 0x54
pop esi
pop edi
pop ebx
pop ebp
ret 0xc