Function at 0x4134d6
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff8
sub esp, 0xc0
mov ebx, ecx
lea eax, [esp + 0x7c]
lea esi, [esp + 0x38]
mov ecx, esi
push 0x50090a
push eax
push dword [ebp + 8]
call fcn.00419120
add esp, 0xc
mov al, byte [esi + 8]
cmp al, 3
jne 0x413514
mov dword [ebx], 2
jmp 0x413a4f
mov edi, dword [ebp + 0xc]
mov ecx, dword [edi + 0x28]
test ecx, ecx
mov dword [esp + 0x2c], ecx
je 0x41360a
mov ecx, dword [esp + 0x38]
mov edx, dword [esp + 0x3c]
mov byte [esp + 3], al
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x18], ecx
mov ecx, dword [edi]
mov dword [esp + 0x10], edx
xor ecx, 2
or ecx, dword [edi + 4]
jne 0x413611
mov eax, dword [edi + 8]
mov edx, dword [edi + 0xc]
mov esi, dword [edi + 0x10]
mov ebx, edi
lea ecx, [esp + 0x38]
mov edi, eax
xor edi, 0x70736575
mov dword [ecx], edi
mov edi, edx
xor edi, 0x736f6d65
mov dword [ecx + 4], edi
mov edi, eax
xor edi, 0x6e657261
mov dword [ecx + 8], edi
mov edi, edx
xor edi, 0x6c796765
mov dword [ecx + 0xc], edi
mov edi, esi
xor edi, 0x6e646f6d
mov dword [ecx + 0x10], edi
mov edi, dword [ebx + 0x14]
mov ebx, edi
xor ebx, 0x646f7261
mov dword [ecx + 0x14], ebx
mov ebx, esi
xor ebx, 0x79746573
mov dword [ecx + 0x18], ebx
mov ebx, edi
xor ebx, 0x74656462
mov dword [ecx + 0x1c], ebx
mov bl, byte [esp + 3]
mov dword [ecx + 0x20], eax
xor eax, eax
mov dword [ecx + 0x24], edx
mov dword [ecx + 0x28], esi
mov dword [ecx + 0x2c], edi
lea edx, [esp + 0x28]
mov dword [ecx + 0x38], eax
mov dword [ecx + 0x3c], eax
mov dword [ecx + 0x30], eax
mov dword [ecx + 0x34], eax
xor eax, eax
cmp bl, 2
setne al
mov dword [edx], eax
push 4
call fcn.0040a1d4
add esp, 4
cmp bl, 2
jne 0x413691
movzx eax, byte [esp + 0x18]
lea edx, [esp + 0x28]
lea ecx, [esp + 0x38]
mov dword [edx], eax
push 4
jmp 0x4136a7
xor eax, eax
jmp 0x4139f1
xor eax, eax
cmp byte [esp + 3], 2
mov ebx, 0xcbf29ce4
mov edx, 0x84222325
mov esi, 0xfffffffc
setne al
mov dword [esp + 0x38], eax
movzx ecx, byte [esp + esi + 0x3c]
imul ebx, ebx, 0x1b3
xor ecx, edx
mov edx, 0x1b3
mov eax, ecx
shl ecx, 8
mul edx
add ecx, edx
mov edx, eax
add ebx, ecx
inc esi
jne 0x41362e
mov al, byte [esp + 3]
cmp al, 2
jne 0x4139fb
movzx eax, byte [esp + 0x18]
mov esi, 0xfffffffc
mov dword [esp + 0x38], eax
movzx ecx, byte [esp + esi + 0x3c]
imul ebx, ebx, 0x1b3
xor ecx, edx
mov edx, 0x1b3
mov eax, ecx
shl ecx, 8
mul edx
add ecx, edx
mov edx, eax
add ebx, ecx
inc esi
jne 0x41366a
jmp 0x4138bf
test bl, bl
mov eax, ebx
je 0x413a57
mov edx, dword [esp + 0x18]
lea ecx, [esp + 0x38]
push dword [esp + 0x10]
call fcn.0040a1d4
add esp, 4
mov edx, dword [esp + 0x70]
mov ecx, dword [esp + 0x54]
mov esi, dword [esp + 0x68]
mov eax, dword [esp + 0x48]
mov ebx, dword [esp + 0x4c]
mov edi, dword [esp + 0x3c]
shl edx, 0x18
mov dword [esp + 0x24], esi
mov dword [esp + 4], eax
or edx, dword [esp + 0x6c]
mov dword [esp + 0xc], edx
xor ecx, edx
mov edx, dword [esp + 0x50]
xor edx, esi
mov esi, dword [esp + 0x38]
add esi, eax
mov eax, dword [esp + 4]
mov dword [esp + 0x14], esi
mov esi, dword [esp + 4]
adc edi, ebx
mov dword [esp + 8], edi
shld eax, ebx, 0xd
shld ebx, esi, 0xd
mov esi, dword [esp + 0x14]
xor ebx, edi
mov edi, dword [esp + 0x44]
xor eax, esi
mov dword [esp + 0x34], eax
mov eax, dword [esp + 0x40]
add eax, edx
mov dword [esp + 4], eax
mov eax, edx
adc edi, ecx
shrd edx, ecx, 0x10
shld eax, ecx, 0x10
xor edx, edi
xor eax, dword [esp + 4]
add dword [esp + 8], eax
mov ecx, eax
adc esi, edx
shrd eax, edx, 0xb
shld ecx, edx, 0x15
xor eax, esi
xor ecx, dword [esp + 8]
mov dword [esp + 0x30], eax
mov eax, dword [esp + 0x34]
add dword [esp + 4], eax
mov edx, eax
adc edi, ebx
shld edx, ebx, 0x11
shrd eax, ebx, 0xf
mov ebx, esi
mov esi, dword [esp + 0x24]
mov dword [esp + 0x20], edx
xor eax, edi
xor ebx, dword [esp + 0xc]
xor edi, 0xff
mov edx, dword [esp + 0x20]
mov dword [esp + 0xc], edi
xor dword [esp + 8], esi
mov esi, ecx
xor edx, dword [esp + 4]
add dword [esp + 8], edx
mov edi, edx
adc ebx, eax
shrd edx, eax, 0x13
shld edi, eax, 0xd
mov eax, dword [esp + 0x30]
xor edx, ebx
mov dword [esp + 0x14], ebx
mov ebx, dword [esp + 4]
xor edi, dword [esp + 8]
mov dword [esp + 0x20], edx
mov edx, dword [esp + 0xc]
add edx, ecx
adc ebx, eax
shld esi, eax, 0x10
shrd ecx, eax, 0x10
mov dword [esp + 0xc], edx
xor esi, edx
mov edx, dword [esp + 0x14]
xor ecx, ebx
mov dword [esp + 4], ebx
mov ebx, dword [esp + 8]
mov eax, esi
add edx, esi
adc ebx, ecx
shld eax, ecx, 0x15
shrd esi, ecx, 0xb
mov ecx, edx
mov dword [esp + 0x14], edx
mov ecx, edi
xor eax, edx
xor esi, ebx
mov dword [esp + 8], ebx
add dword [esp + 0xc], edi
mov ebx, dword [esp + 4]
mov edx, dword [esp + 0x20]
adc ebx, edx
shrd edi, edx, 0xf
shld ecx, edx, 0x11
mov dword [esp + 4], ebx
xor edi, ebx
mov ebx, dword [esp + 0xc]
xor ecx, ebx
add dword [esp + 0x14], ecx
mov edx, ecx
adc dword [esp + 8], edi
shrd ecx, edi, 0x13
shld edx, edi, 0xd
mov edi, dword [esp + 0x14]
xor ecx, dword [esp + 8]
xor edx, edi
add dword [esp + 4], eax
adc ebx, esi
mov dword [esp + 0xc], ebx
mov ebx, eax
shrd eax, esi, 0x10
shld ebx, esi, 0x10
xor eax, dword [esp + 0xc]
xor ebx, dword [esp + 4]
add dword [esp + 8], ebx
mov esi, ebx
adc edi, eax
shld esi, eax, 0x15
shrd ebx, eax, 0xb
mov eax, dword [esp + 0xc]
xor ebx, edi
xor esi, dword [esp + 8]
add dword [esp + 4], edx
mov dword [esp + 0x14], edi
mov edi, edx
adc eax, ecx
shld edi, ecx, 0x11
shrd edx, ecx, 0xf
mov ecx, dword [esp + 8]
xor edi, dword [esp + 4]
xor edx, eax
mov dword [esp + 0xc], eax
add ecx, edi
mov eax, edi
adc dword [esp + 0x14], edx
shrd edi, edx, 0x13
shld eax, edx, 0xd
mov edx, edi
mov edi, dword [esp + 0xc]
xor eax, ecx
mov ecx, dword [esp + 4]
xor edx, dword [esp + 0x14]
add edi, esi
adc ecx, ebx
shrd esi, ebx, 0x10
xor esi, ecx
shr esi, 0xb
add edi, eax
adc ecx, edx
shr edx, 0xf
xor edx, ecx
xor edx, esi
xor edx, edi
mov edi, dword [ebp + 0xc]
movzx eax, word [edi + 0x38]
and edx, 0x7fff
mov dword [esp + 8], 0
mov dword [esp + 0x20], edx
movzx ecx, ax
mov eax, edi
mov edi, edx
mov esi, dword [eax + 0x18]
mov ebx, dword [eax + 0x1c]
mov eax, dword [eax + 0x24]
and edi, ecx
mov dword [esp + 0x14], ecx
mov dword [esp + 0x24], eax
mov dword [esp + 0xc], esi
mov eax, edi
mov edi, eax
xor eax, eax
cmp edi, ebx
jae 0x4138f5
movzx ecx, word [esi + edi*4]
xor eax, eax
cmp ecx, 0xffff
je 0x4139ed
mov dword [esp + 4], ecx
movzx ecx, word [esi + edi*4 + 2]
mov eax, dword [esp + 0x14]
mov esi, edi
mov edx, ecx
and edx, eax
sub esi, edx
and esi, eax
cmp dword [esp + 8], esi
ja 0x4139f3
mov edx, dword [esp + 0x20]
mov esi, dword [esp + 0xc]
cmp cx, dx
jne 0x4139e3
mov ecx, dword [esp + 4]
cmp dword [esp + 0x2c], ecx
jbe 0x413ad4
mov edx, dword [esp + 0x24]
imul eax, ecx, 0x34
lea eax, [edx + eax + 0x20]
cmp dword [eax], 0
je 0x413992
cmp byte [esp + 3], 2
je 0x4139e3
cmp byte [esp + 3], 0
mov ecx, dword [eax + 8]
je 0x4139a7
cmp ecx, dword [esp + 0x10]
jne 0x4139e3
push dword [esp + 0x10]
push dword [esp + 0x1c]
push dword [eax + 4]
call fcn.004e5584
add esp, 0xc
test eax, eax
jne 0x4139e3
jmp 0x413a3c
cmp byte [esp + 3], 2
jne 0x4139e3
mov ecx, dword [esp + 0x18]
cmp byte [eax + 4], cl
jne 0x4139e3
jmp 0x413a3c
cmp ecx, dword [esp + 0x10]
jne 0x4139e3
cmp dword [esp + 0x10], 0
je 0x413a3c
mov esi, dword [eax + 4]
xor eax, eax
mov ecx, dword [esp + 0x18]
movzx edx, byte [ecx + eax]
mov ch, byte [esi + eax]
cmp ch, byte [edx + 0x50090a]
jne 0x4139d9
inc eax
cmp dword [esp + 0x10], eax
jne 0x4139bd
jmp 0x413a3c
cmp eax, dword [esp + 0x10]
mov esi, dword [esp + 0xc]
jae 0x413a3c
inc dword [esp + 8]
inc edi
jmp 0x4138f3
mov ebx, dword [esp + 0x1c]
jmp 0x413a47
mov ebx, dword [esp + 0x1c]
xor eax, eax
jmp 0x413a47
test al, al
je 0x413a94
cmp dword [esp + 0x10], 0
je 0x4138bf
mov edi, dword [esp + 0x10]
mov esi, dword [esp + 0x18]
movzx ecx, byte [esi]
imul ebx, ebx, 0x1b3
inc esi
xor ecx, edx
mov edx, 0x1b3
mov eax, ecx
shl ecx, 8
mul edx
add ecx, edx
mov edx, eax
add ebx, ecx
dec edi
jne 0x413a16
jmp 0x4138bc
mov ebx, dword [esp + 0x1c]
mov ecx, dword [esp + 4]
xor eax, eax
inc eax
mov dword [ebx], eax
mov dword [ebx + 4], edi
mov dword [ebx + 8], ecx
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret
cmp dword [esp + 0x10], 0
je 0x4136af
mov edi, dword [esp + 0x10]
mov esi, dword [esp + 0x18]
lea ebx, [esp + 0x28]
movzx eax, byte [esi]
inc esi
lea ecx, [esp + 0x38]
mov edx, ebx
mov al, byte [eax + 0x50090a]
mov byte [esp + 0x28], al
push 1
call fcn.0040a1d4
add esp, 4
dec edi
jne 0x413a6e
jmp 0x4136af
cmp dword [esp + 0x10], 0
je 0x4138bf
mov edi, dword [esp + 0x10]
mov esi, dword [esp + 0x18]
movzx eax, byte [esi]
imul ebx, ebx, 0x1b3
inc esi
movzx ecx, byte [eax + 0x50090a]
xor ecx, edx
mov edx, 0x1b3
mov eax, ecx
shl ecx, 8
mul edx
add ecx, edx
mov edx, eax
add ebx, ecx
dec edi
jne 0x413aa7
jmp 0x4138bc
mov edx, dword [esp + 0x2c]
push 0x5011cc
call fcn.004e8970