Function at 0x413310
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
push ebx
mov ebx, edx
mov eax, dword [ebx + 4]
push esi
mov esi, ecx
mov dword [ebp - 4], ebx
push edi
lea edi, [ebx + 4]
mov dword [ebp - 0x18], edi
mov dword [esi + 0x10], eax
nop dword [eax]
mov eax, dword [esi]
cmp eax, 9
ja case.default.0x413337
jmp dword [eax*4 + 0x413af8]
mov ecx, dword [edi]
mov edx, dword [esi + 0xa0]
mov eax, dword [esi + 0xa4]
mov edi, dword [ebx + 8]
sub eax, edx
sub edi, ecx
cmp edi, eax
cmovae edi, eax
mov eax, dword [ebx]
add eax, ecx
push edi
push eax
lea eax, [esi + 0xa8]
add eax, edx
push eax
call fcn.004241c0
add dword [ebx + 4], edi
add esp, 0xc
add dword [esi + 0xa0], edi
mov eax, dword [esi + 0xa0]
cmp eax, dword [esi + 0xa4]
jne 0x413aef
mov dword [esi + 0xa0], 0
mov dword [esi], 1
cmp dword [esi + 0xa8], 0x587a37fd
jne 0x4136df
cmp word [esi + 0xac], 0x5a
jne 0x4136df
lea edi, [esi + 0xae]
or edx, 0xffffffff
mov ebx, 2
movzx eax, byte [edi]
lea edi, [edi + 1]
movzx ecx, dl
xor ecx, eax
shr edx, 8
xor edx, dword [ecx*4 + 0x454c70]
sub ebx, 1
jne 0x4133c6
movzx ecx, byte [esi + 0xb3]
not edx
movzx eax, byte [esi + 0xb2]
mov ebx, dword [ebp - 4]
shl ecx, 8
or ecx, eax
movzx eax, byte [esi + 0xb1]
shl ecx, 8
or ecx, eax
movzx eax, byte [esi + 0xb0]
shl ecx, 8
or ecx, eax
cmp edx, ecx
jne 0x413a50
cmp byte [esi + 0xae], 0
jne 0x4136d3
movzx eax, byte [esi + 0xaf]
mov dword [esi + 0x1c], eax
cmp eax, 1
ja 0x4136d3
lea edi, [ebx + 4]
mov ecx, dword [edi]
cmp ecx, dword [ebx + 8]
je 0x413aef
mov eax, dword [ebx]
mov al, byte [ecx + eax]
test al, al
jne 0x41345f
mov dword [esi + 0x10], ecx
inc dword [edi]
mov dword [esi], 6
jmp case.default.0x413337
movzx eax, al
mov dword [esi + 0xa0], 0
mov dword [esi], 2
lea eax, [eax*4 + 4]
mov dword [esi + 0x38], eax
mov dword [esi + 0xa4], eax
mov ecx, dword [edi]
mov edx, dword [esi + 0xa0]
mov eax, dword [esi + 0xa4]
mov edi, dword [ebx + 8]
sub eax, edx
sub edi, ecx
cmp edi, eax
cmovae edi, eax
mov eax, dword [ebx]
add eax, ecx
push edi
push eax
lea eax, [esi + 0xa8]
add eax, edx
push eax
call fcn.004241c0
add dword [ebx + 4], edi
add esp, 0xc
add dword [esi + 0xa0], edi
mov eax, dword [esi + 0xa0]
cmp eax, dword [esi + 0xa4]
jne 0x413aef
mov ecx, esi
mov dword [esi + 0xa0], 0
call fcn.004130c0
test eax, eax
jne 0x413af1
mov dword [esi], 3
lea edi, [ebx + 4]
mov eax, dword [edi]
mov edx, ebx
mov ecx, dword [esi + 0x4a8]
mov dword [esi + 0x10], eax
mov eax, dword [ebx + 0x10]
mov dword [esi + 0x14], eax
call fcn.00414420
mov ecx, eax
mov edx, 0
mov eax, dword [edi]
sub eax, dword [esi + 0x10]
add dword [esi + 0x40], eax
mov edi, dword [esi + 0x2c]
adc dword [esi + 0x44], 0
mov eax, dword [ebx + 0x10]
sub eax, dword [esi + 0x14]
add eax, dword [esi + 0x48]
mov dword [ebp - 0xc], ecx
adc edx, dword [esi + 0x4c]
mov dword [ebp - 0x10], edx
mov dword [esi + 0x4c], edx
mov edx, dword [esi + 0x28]
mov dword [esi + 0x48], eax
cmp dword [esi + 0x44], edi
ja 0x4136eb
jb 0x41354d
cmp dword [esi + 0x40], edx
ja 0x4136eb
mov edi, dword [esi + 0x34]
mov edx, dword [esi + 0x30]
cmp dword [ebp - 0x10], edi
ja 0x4136eb
jb 0x413566
cmp eax, edx
ja 0x4136eb
cmp dword [esi + 0x1c], 1
jne 0x4135ac
mov edi, dword [ebx + 0xc]
mov eax, dword [ebx + 0x10]
add edi, dword [esi + 0x14]
mov edx, dword [esi + 0x18]
sub eax, dword [esi + 0x14]
not edx
mov dword [ebp - 0x10], eax
je 0x4135a1
mov ebx, eax
movzx eax, byte [edi]
lea edi, [edi + 1]
movzx ecx, dl
xor ecx, eax
shr edx, 8
xor edx, dword [ecx*4 + 0x454c70]
sub ebx, 1
jne 0x413584
mov ecx, dword [ebp - 0xc]
mov edi, dword [esi + 0x34]
not edx
mov dword [esi + 0x18], edx
mov edx, dword [esi + 0x30]
cmp ecx, 1
jne 0x4136f0
mov ecx, dword [esi + 0x28]
mov eax, ecx
and eax, dword [esi + 0x2c]
cmp eax, 0xffffffff
je 0x4135d7
cmp ecx, dword [esi + 0x40]
jne 0x4136eb
mov eax, dword [esi + 0x2c]
cmp eax, dword [esi + 0x44]
jne 0x4136eb
mov eax, edx
and eax, edi
cmp eax, 0xffffffff
je 0x4135f2
cmp edx, dword [esi + 0x48]
jne 0x4136eb
cmp edi, dword [esi + 0x4c]
jne 0x4136eb
mov eax, dword [esi + 0x38]
lea edi, [esi + 0x58]
xor ecx, ecx
add eax, dword [edi]
adc ecx, dword [edi + 4]
add eax, dword [esi + 0x40]
mov dword [edi], eax
adc ecx, dword [esi + 0x44]
cmp dword [esi + 0x1c], 1
mov dword [edi + 4], ecx
jne 0x41361b
add eax, 4
mov dword [edi], eax
adc ecx, 0
mov dword [edi + 4], ecx
mov eax, dword [esi + 0x48]
mov ebx, 0x18
add dword [esi + 0x60], eax
mov edx, dword [esi + 0x68]
mov eax, dword [esi + 0x4c]
not edx
adc dword [esi + 0x64], eax
movzx eax, byte [edi]
lea edi, [edi + 1]
movzx ecx, dl
xor ecx, eax
shr edx, 8
xor edx, dword [ecx*4 + 0x454c70]
sub ebx, 1
jne 0x413631
mov ebx, dword [ebp - 4]
not edx
add dword [esi + 0x50], 1
mov dword [esi + 0x68], edx
adc dword [esi + 0x54], 0
mov dword [esi], 4
lea edi, [ebx + 4]
mov eax, dword [esi + 0x40]
and eax, 3
or eax, 0
je 0x4136a6
nop
mov edx, dword [edi]
cmp edx, dword [ebx + 8]
je 0x413aef
mov eax, dword [ebx]
mov cl, byte [edx + eax]
lea eax, [edx + 1]
mov dword [edi], eax
test cl, cl
jne 0x413a50
add dword [esi + 0x40], 1
mov ecx, dword [esi + 0x40]
adc dword [esi + 0x44], 0
and ecx, 3
or ecx, 0
mov eax, dword [esi + 0x44]
mov dword [ebp - 0x10], eax
jne 0x413670
mov dword [esi], 5
cmp dword [esi + 0x1c], 1
jne 0x4136c8
push ecx
mov edx, ebx
mov ecx, esi
call fcn.00413060
add esp, 4
cmp eax, 1
jne 0x413af1
mov dword [esi], 1
jmp case.default.0x413337
pop edi
pop esi
mov eax, 6
pop ebx
mov esp, ebp
pop ebp
ret
pop edi
pop esi
mov eax, 5
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, 7
pop edi
pop esi
mov eax, ecx
pop ebx
mov esp, ebp
pop ebp
ret
push dword [ebx + 8]
mov edx, dword [ebx]
mov ecx, esi
push edi
call fcn.00412fc0
add esp, 8
mov dword [ebp - 0xc], eax
cmp eax, 1
jne 0x413a5c
mov eax, dword [esi + 0x70]
sub eax, 0
je 0x4137b3
sub eax, 1
je 0x413798
sub eax, 1
jne 0x4137de
mov eax, dword [esi + 8]
lea edi, [esi + 0x88]
add dword [esi + 0x90], eax
mov ebx, 0x18
mov edx, dword [esi + 0x98]
mov eax, dword [esi + 0xc]
not edx
adc dword [esi + 0x94], eax
nop dword [eax + eax]
movzx eax, byte [edi]
lea edi, [edi + 1]
movzx ecx, dl
xor ecx, eax
shr edx, 8
xor edx, dword [ecx*4 + 0x454c70]
sub ebx, 1
jne 0x413760
mov ebx, dword [ebp - 4]
not edx
add dword [esi + 0x80], 0xffffffff
mov dword [esi + 0x98], edx
adc dword [esi + 0x84], 0xffffffff
lea edi, [ebx + 4]
jmp 0x4137d7
mov eax, dword [esi + 8]
add dword [esi + 0x88], eax
mov eax, dword [esi + 0xc]
adc dword [esi + 0x8c], eax
mov dword [esi + 0x70], 2
jmp 0x4137de
mov eax, dword [esi + 8]
mov ecx, dword [esi + 0xc]
mov dword [esi + 0x80], eax
mov dword [esi + 0x84], ecx
cmp eax, dword [esi + 0x50]
jne 0x413a50
cmp ecx, dword [esi + 0x54]
jne 0x413a50
mov dword [esi + 0x70], 1
cmp dword [esi + 0x84], 0
ja case.0x413337.6
jb 0x4137fa
cmp dword [esi + 0x80], 0
ja case.0x413337.6
mov dword [esi], 7
mov eax, dword [esi + 0x78]
mov edx, dword [edi]
mov ecx, dword [esi + 0x10]
mov dword [ebp - 8], eax
mov eax, dword [esi + 0x7c]
mov dword [ebp - 0xc], eax
mov eax, edx
sub eax, ecx
mov dword [ebp - 0x10], ecx
add eax, dword [esi + 0x78]
and eax, 3
or eax, 0
je 0x41386c
mov eax, dword [esi + 0x78]
mov dword [ebp - 8], eax
mov eax, dword [esi + 0x7c]
mov dword [ebp - 0x10], ecx
mov dword [ebp - 0xc], eax
cmp edx, dword [ebx + 8]
je 0x413aa9
mov eax, dword [ebx]
mov al, byte [edx + eax]
inc edx
mov dword [edi], edx
test al, al
jne 0x413a50
mov eax, dword [esi + 0x78]
mov ecx, dword [esi + 0x10]
mov dword [ebp - 8], eax
mov eax, dword [esi + 0x7c]
mov dword [ebp - 0xc], eax
mov eax, edx
sub eax, ecx
mov dword [ebp - 0x10], ecx
add eax, dword [esi + 0x78]
and eax, 3
or eax, 0
jne 0x413832
sub edx, ecx
xor ecx, ecx
mov eax, edx
add eax, dword [ebp - 8]
mov dword [esi + 0x78], eax
adc ecx, dword [ebp - 0xc]
mov dword [esi + 0x7c], ecx
mov eax, dword [ebx]
add eax, dword [ebp - 0x10]
mov dword [ebp - 0xc], eax
mov eax, dword [esi + 0x18]
not eax
mov dword [ebp - 0x10], eax
test edx, edx
je 0x4138bd
mov edi, dword [ebp - 0xc]
mov ebx, eax
movzx eax, byte [edi]
lea edi, [edi + 1]
movzx ecx, bl
xor ecx, eax
shr ebx, 8
xor ebx, dword [ecx*4 + 0x454c70]
sub edx, 1
jne 0x413897
mov edi, dword [ebp - 0x18]
mov dword [ebp - 0x10], ebx
mov ebx, dword [ebp - 4]
mov eax, dword [ebp - 0x10]
not eax
mov dword [ebp - 0x10], 0x14
mov dword [esi + 0x18], eax
lea edx, [esi + 0x88]
lea ecx, [esi + 0x58]
mov eax, dword [ecx]
cmp eax, dword [edx]
jne 0x413a50
add ecx, 4
add edx, 4
sub dword [ebp - 0x10], 4
jae 0x4138d2
mov dword [esi], 8
push ecx
mov edx, ebx
mov ecx, esi
call fcn.00413060
add esp, 4
cmp eax, 1
jne 0x413af1
mov dword [esi + 0xa4], 0xc
mov dword [esi], 9
mov ecx, dword [edi]
mov edx, dword [esi + 0xa0]
mov eax, dword [esi + 0xa4]
mov edi, dword [ebx + 8]
sub eax, edx
sub edi, ecx
cmp edi, eax
cmovae edi, eax
mov eax, dword [ebx]
add eax, ecx
push edi
push eax
lea eax, [esi + 0xa8]
add eax, edx
push eax
call fcn.004241c0
add dword [ebx + 4], edi
add esp, 0xc
add dword [esi + 0xa0], edi
mov eax, dword [esi + 0xa0]
cmp eax, dword [esi + 0xa4]
jne 0x413aef
mov eax, 0x5a59
mov dword [esi + 0xa0], 0
cmp word [esi + 0xb2], ax
jne 0x413a50
lea edi, [esi + 0xac]
or edx, 0xffffffff
mov ebx, 6
nop word [eax + eax]
movzx eax, byte [edi]
lea edi, [edi + 1]
movzx ecx, dl
xor ecx, eax
shr edx, 8
xor edx, dword [ecx*4 + 0x454c70]
sub ebx, 1
jne 0x413990
movzx ecx, byte [esi + 0xab]
not edx
movzx eax, byte [esi + 0xaa]
shl ecx, 8
or ecx, eax
movzx eax, byte [esi + 0xa9]
shl ecx, 8
or ecx, eax
movzx eax, byte [esi + 0xa8]
shl ecx, 8
or ecx, eax
cmp edx, ecx
jne 0x413a50
movzx eax, byte [esi + 0xaf]
cdq
mov ecx, eax
mov edi, edx
movzx eax, byte [esi + 0xae]
shld edi, ecx, 8
cdq
shl ecx, 8
or edi, edx
or ecx, eax
movzx eax, byte [esi + 0xad]
shld edi, ecx, 8
cdq
shl ecx, 8
or edi, edx
or ecx, eax
movzx eax, byte [esi + 0xac]
shld edi, ecx, 8
cdq
shl ecx, 8
or edi, edx
mov edx, dword [esi + 0x7c]
or ecx, eax
mov eax, dword [esi + 0x78]
shrd eax, edx, 2
shr edx, 2
cmp eax, ecx
jne 0x413a50
cmp edx, edi
jne 0x413a50
cmp byte [esi + 0xb0], bl
jne 0x413a50
movzx eax, byte [esi + 0xb1]
cmp eax, dword [esi + 0x1c]
lea eax, [ebx + 1]
je 0x413af1
pop edi
pop esi
mov eax, 7
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, dword [edi]
sub ecx, dword [esi + 0x10]
add dword [esi + 0x78], ecx
mov edx, dword [esi + 0x18]
adc dword [esi + 0x7c], 0
not edx
mov edi, dword [ebx]
mov ebx, ecx
add edi, dword [esi + 0x10]
mov dword [ebp - 0x10], ecx
test ebx, ebx
je 0x413a9a
nop dword [eax + eax]
movzx eax, byte [edi]
lea edi, [edi + 1]
movzx ecx, dl
xor ecx, eax
shr edx, 8
xor edx, dword [ecx*4 + 0x454c70]
sub ebx, 1
jne 0x413a80
mov eax, dword [ebp - 0xc]
not edx
pop edi
mov dword [esi + 0x18], edx
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
sub edx, ecx
xor ecx, ecx
mov eax, edx
add eax, dword [ebp - 8]
mov dword [esi + 0x78], eax
adc ecx, dword [ebp - 0xc]
mov dword [esi + 0x7c], ecx
mov edi, dword [ebx]
add edi, dword [ebp - 0x10]
mov ebx, dword [esi + 0x18]
not ebx
test edx, edx
je 0x413aea
nop dword [eax]
movzx eax, byte [edi]
lea edi, [edi + 1]
movzx ecx, bl
xor ecx, eax
shr ebx, 8
xor ebx, dword [ecx*4 + 0x454c70]
sub edx, 1
jne 0x413ad0
not ebx
mov dword [esi + 0x18], ebx
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret