Function at 0x472860
Capabilities:
Encode data using xor

Disassembly:
mov eax, dword [esp + 4]
sub esp, 0x100
cmp eax, 5
push ebx
push esi
push edi
jne 0x472a41
mov eax, dword [esp + 0x118]
lea ecx, [esp + 0x5c]
push eax
push ecx
call fcn.0047bd60
mov esi, dword [esp + 0x11c]
lea edx, [esp + 0x64]
push esi
push edx
call fcn.0047c080
add esp, 0x10
xor eax, eax
mov cl, byte [eax + esi + 0x10]
mov bl, byte [eax + esi]
xor bl, cl
mov byte [eax + esi], bl
inc eax
cmp eax, 0x10
jb 0x47289f
lea edi, [esi + 0x10]
lea edx, [esp + 0x5c]
push edi
push edx
call fcn.0047c080
mov ecx, 0xfffffff0
add esp, 8
mov eax, edi
sub ecx, esi
mov dl, byte [eax + 0x10]
mov bl, byte [eax]
xor bl, dl
mov byte [eax], bl
inc eax
lea edx, [ecx + eax]
cmp edx, 0x10
jb 0x4728cb
lea edi, [esi + 0x20]
lea eax, [esp + 0x5c]
push edi
push eax
call fcn.0047c080
mov ecx, 0xffffffe0
add esp, 8
mov eax, edi
sub ecx, esi
mov dl, byte [eax + 0x10]
mov bl, byte [eax]
xor bl, dl
mov byte [eax], bl
inc eax
lea edx, [ecx + eax]
cmp edx, 0x10
jb 0x4728f7
lea eax, [esi + 0x30]
lea ecx, [esp + 0x5c]
push eax
push ecx
call fcn.0047c080
lea edx, [esp + 0x14]
lea eax, [esp + 0x64]
push edx
push eax
call fcn.0047bd60
mov al, byte [esi + 0x3d]
add esp, 0x10
cmp al, 0x53
je 0x472940
pop edi
pop esi
mov ax, 2
pop ebx
add esp, 0x100
ret 0x18
mov al, byte [esi + 0x3c]
test al, 0x80
je 0x4729df
and eax, 0x9f
add eax, 0xffffff80
cmp eax, 8
ja case.default.0x472958
jmp dword [eax*4 + 0x472adc]
pop edi
pop esi
mov ax, 0x41
pop ebx
add esp, 0x100
ret 0x18
pop edi
pop esi
mov ax, 4
pop ebx
add esp, 0x100
ret 0x18
pop edi
pop esi
mov ax, 0xa
pop ebx
add esp, 0x100
ret 0x18
pop edi
pop esi
mov ax, 0x15
pop ebx
add esp, 0x100
ret 0x18
pop edi
pop esi
mov ax, 0x4a
pop ebx
add esp, 0x100
ret 0x18
pop edi
pop esi
mov ax, 0x3f
pop ebx
add esp, 0x100
ret 0x18
pop edi
pop esi
mov ax, 0x10
pop ebx
add esp, 0x100
ret 0x18
pop edi
pop esi
mov ax, 0xff
pop ebx
add esp, 0x100
ret 0x18
cmp al, 0x3c
ja case.0x472958.132
mov edx, dword [esp + 0x120]
and eax, 0xff
cmp eax, edx
ja case.0x472958.132
mov ecx, dword [esp + 0x124]
mov dword [ecx], eax
xor ecx, ecx
mov cl, byte [esi + 0x3c]
cmp edx, ecx
jb 0x472a31
mov edi, dword [esp + 0x11c]
mov edx, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
pop edi
pop esi
xor ax, ax
pop ebx
add esp, 0x100
ret 0x18
pop edi
pop esi
mov ax, 0x49
pop ebx
add esp, 0x100
ret 0x18
cmp eax, 7
jne case.0x472958.128
mov esi, dword [esp + 0x114]
mov eax, dword [esp + 0x118]
mov ecx, 0x12
lea edi, [esp + 0xc]
rep movsd dword es:[edi], dword [esi]
lea ecx, [esp + 0x5c]
push eax
push ecx
call fcn.0047bd60
lea edx, [esp + 0x64]
lea eax, [esp + 0x14]
push edx
push eax
call fcn.0047c490
add esp, 0x10
test al, al
jne 0x472ac9
mov edx, dword [esp + 0x124]
mov ecx, dword [esp + 0x120]
push ebp
mov ebp, dword [esp + 0x120]
lea edi, [esp + 0x12]
mov dword [edx], ecx
xor esi, esi
mov edx, ebp
sub edi, ebp
test ecx, ecx
jbe 0x472ab3
mov bl, byte [edi + edx]
inc esi
mov byte [edx], bl
inc edx
dec ecx
cmp esi, 4
jb 0x472aa2
mov edx, ecx
lea esi, [esp + 0x18]
lea edi, [ebp + 4]
pop ebp
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
push eax
call fcn.004703b0
pop edi
pop esi
pop ebx
add esp, 0x100
ret 0x18