Function at 0x401030
Capabilities:
Encode data using xor

Disassembly:
push ebp
push esi
push edi
mov ebp, esp
sub esp, 0x1ae
mov edi, esp
add edi, 0x100
mov esi, 0x406ea4
mov ecx, 0x20
rep movsd dword es:[edi], dword [esi]
mov edi, esp
add edi, 0x188
mov esi, dword [0x407170]
mov ecx, 0x20
rep movsb byte es:[edi], byte [esi]
mov edi, esp
add edi, 0x1aa
mov esi, 0x407094
mov ecx, 4
rep movsb byte es:[edi], byte [esi]
mov eax, dword [0x407174]
mov ecx, 5
cmp cx, ax
jne 0x4010b8
movzx edx, byte [esp + 0x1ab]
movzx eax, byte [esp + 0x1ac]
movzx ecx, byte [esp + 0x1ad]
shl eax, 8
or eax, edx
movzx edx, byte [esp + 0x1aa]
shl eax, 8
or eax, ecx
shl eax, 8
or eax, edx
jmp 0x4010e9
movzx edx, byte [esp + 0x1ab]
movzx eax, byte [esp + 0x1ac]
movzx ecx, byte [esp + 0x1aa]
shl eax, 8
or eax, ecx
movzx ecx, byte [esp + 0x1ad]
shl eax, 8
or eax, edx
shl eax, 8
or eax, ecx
jmp 0x4010e9
mov ecx, eax
shr ecx, 0x10
mov dword [esp + 0x10], ecx
movzx ebx, ax
lea edx, [esp + 0x1a8]
mov dword [esp + 0x18], 4
sub edx, 8
movzx eax, word [edx + 6]
xor eax, ebx
mov ecx, eax
mov esi, eax
and ecx, 1
mov edi, eax
shl ecx, 4
shr esi, 0xc
or ecx, esi
mov esi, eax
and eax, 0x1f
mov dword [esp + 0x2c], eax
mov eax, dword [esp + ecx*4 + 0x100]
mov ecx, dword [esp + 0x2c]
shl eax, 4
shr esi, 8
and esi, 0x1f
or eax, dword [esp + esi*4 + 0x100]
shr edi, 4
shl eax, 4
and edi, 0x1f
or eax, dword [esp + edi*4 + 0x100]
shl eax, 4
or eax, dword [esp + ecx*4 + 0x100]
mov ecx, eax
and ecx, 7
shl ecx, 0xd
shr eax, 3
or ecx, eax
xor ecx, dword [esp + 0x10]
movzx eax, word [edx + 4]
xor eax, ecx
mov dword [esp + 0x10], ecx
mov ecx, eax
mov esi, eax
and ecx, 1
shl ecx, 4
mov edi, eax
shr esi, 0xc
or ecx, esi
mov esi, eax
and eax, 0x1f
mov dword [esp + 0x2c], eax
mov eax, dword [esp + ecx*4 + 0x100]
mov ecx, dword [esp + 0x2c]
shl eax, 4
shr esi, 8
and esi, 0x1f
or eax, dword [esp + esi*4 + 0x100]
shr edi, 4
shl eax, 4
and edi, 0x1f
or eax, dword [esp + edi*4 + 0x100]
shl eax, 4
or eax, dword [esp + ecx*4 + 0x100]
mov ecx, eax
and ecx, 7
shl ecx, 0xd
shr eax, 3
or ecx, eax
movzx eax, word [edx + 2]
xor ecx, ebx
mov ebx, dword [esp + 0x10]
xor eax, ecx
mov dword [esp + 0x10], ecx
mov ecx, eax
mov esi, eax
and ecx, 1
shr esi, 0xc
shl ecx, 4
or ecx, esi
mov esi, eax
mov edi, eax
and eax, 0x1f
shr esi, 8
shr edi, 4
mov dword [esp + 0x2c], eax
mov eax, dword [esp + ecx*4 + 0x100]
and esi, 0x1f
and edi, 0x1f
shl eax, 4
or eax, dword [esp + esi*4 + 0x100]
mov ecx, dword [esp + 0x2c]
shl eax, 4
or eax, dword [esp + edi*4 + 0x100]
shl eax, 4
or eax, dword [esp + ecx*4 + 0x100]
mov ecx, eax
and ecx, 7
shr eax, 3
shl ecx, 0xd
or ecx, eax
movzx eax, word [edx]
xor ecx, ebx
mov ebx, dword [esp + 0x10]
xor eax, ecx
mov dword [esp + 0x10], ecx
mov ecx, eax
mov esi, eax
and ecx, 1
shl ecx, 4
mov edi, eax
shr esi, 0xc
or ecx, esi
mov esi, eax
and eax, 0x1f
mov dword [esp + 0x2c], eax
mov eax, dword [esp + ecx*4 + 0x100]
mov ecx, dword [esp + 0x2c]
shl eax, 4
shr esi, 8
and esi, 0x1f
or eax, dword [esp + esi*4 + 0x100]
shr edi, 4
shl eax, 4
and edi, 0x1f
or eax, dword [esp + edi*4 + 0x100]
shl eax, 4
or eax, dword [esp + ecx*4 + 0x100]
mov ecx, eax
and ecx, 7
shl ecx, 0xd
shr eax, 3
or ecx, eax
mov eax, dword [esp + 0x10]
xor ecx, ebx
dec dword [esp + 0x18]
mov dword [esp + 0x10], eax
mov ebx, ecx
jne 0x401104
shl ecx, 0x10
or ecx, eax
mov eax, ecx
mov esp, ebp
pop edi
pop esi
pop ebp
ret