Function at 0x40e410
Capabilities:
Encode data using xor

Disassembly:
sub esp, 0x1c
push ebx
mov ebx, dword [esp + 0x28]
mov eax, ebx
push ebp
and eax, 0x11000
mov byte [esp + 0x1c], bl
mov dword [esp + 0x20], eax
push esi
push edi
mov edi, dword [esp + 0x30]
cmp eax, 0x1000
jne 0x40e49b
xor edx, edx
movzx eax, bl
movzx ecx, dl
imul ecx, eax
mov al, byte [edx + edi]
sub al, cl
xor al, bl
mov byte [edx + edi], al
inc edx
cmp edx, 0x40
jb 0x40e437
mov eax, dword [edi + 0x3c]
lea esi, [eax + 0xf8]
cmp edx, esi
jae 0x40e47b
lea ecx, [ecx]
movzx eax, bl
movzx ecx, dl
imul ecx, eax
mov al, byte [edx + edi]
sub al, cl
xor al, bl
mov byte [edx + edi], al
inc edx
cmp edx, esi
jb 0x40e460
mov eax, dword [edi + 0x3c]
mov esi, dword [eax + edi + 0x54]
cmp edx, esi
jae 0x40e49b
movzx eax, bl
movzx ecx, dl
imul ecx, eax
mov al, byte [edx + edi]
sub al, cl
xor al, bl
mov byte [edx + edi], al
inc edx
cmp edx, esi
jb 0x40e483
mov ecx, dword [edi + 0x3c]
lea esi, [ecx + edi]
mov dword [esp + 0x34], esi
test ebx, 0x2000
je 0x40e7da
mov edx, dword [esi + 0x80]
test edx, edx
je 0x40e7da
cmp byte [esp + 0x38], 0
je 0x40e516
movzx eax, word [esi + 0x14]
movzx ebp, word [esi + 6]
add eax, ecx
lea ecx, [edi + 0x18]
xor edi, edi
add ecx, eax
test ebp, ebp
je 0x40e4f8
jmp 0x40e4e0
mov esi, dword [ecx + 0xc]
cmp esi, edx
ja 0x40e4f0
mov eax, dword [ecx + 8]
add eax, esi
cmp eax, edx
ja 0x40e500
inc edi
add ecx, 0x28
cmp edi, ebp
jl 0x40e4e0
mov edi, dword [esp + 0x30]
xor eax, eax
jmp 0x40e518
mov edi, dword [esp + 0x30]
sub edx, esi
cmp edx, dword [ecx + 0x10]
jb 0x40e50f
xor eax, eax
jmp 0x40e518
mov eax, dword [ecx + 0x14]
add eax, edx
jmp 0x40e518
mov eax, edx
add eax, edi
mov dword [esp + 0x1c], 0
mov dword [esp + 0x20], eax
cmp dword [eax + 0x10], 0
je 0x40e7da
mov ecx, ebx
mov dword [esp + 0x18], eax
and ecx, 0x10000
mov edi, eax
mov dword [esp + 0x14], ecx
cmp byte [esp + 0x38], 0
mov esi, dword [edi + 0xc]
je 0x40e5ae
mov ebp, dword [esp + 0x30]
xor edi, edi
mov ecx, dword [ebp + 0x3c]
lea edx, [ebp + 0x18]
movzx eax, word [ecx + ebp + 0x14]
movzx ebp, word [ecx + ebp + 6]
add eax, ecx
add edx, eax
test ebp, ebp
je 0x40e588
lea ebx, [ebx]
mov ecx, dword [edx + 0xc]
cmp ecx, esi
ja 0x40e580
mov eax, dword [edx + 8]
add eax, ecx
cmp eax, esi
ja 0x40e594
inc edi
add edx, 0x28
cmp edi, ebp
jl 0x40e570
mov edi, dword [esp + 0x18]
xor eax, eax
mov ecx, dword [esp + 0x14]
jmp 0x40e5b0
mov edi, dword [esp + 0x18]
sub esi, ecx
mov ecx, dword [esp + 0x14]
cmp esi, dword [edx + 0x10]
jb 0x40e5a7
xor eax, eax
jmp 0x40e5b0
mov eax, dword [edx + 0x14]
add eax, esi
jmp 0x40e5b0
mov eax, esi
mov edx, dword [esp + 0x30]
lea esi, [eax + edx]
test esi, esi
je 0x40e62f
test ecx, ecx
je 0x40e604
test bl, bl
je 0x40e62f
xor edx, edx
cmp byte [esi], dl
je 0x40e5ef
lea esp, [esp]
cmp edx, 0xffffffff
jae 0x40e5ef
movsx eax, bl
movsx ecx, dl
imul ecx, eax
mov al, byte [edx + esi]
xor al, bl
add cl, al
mov byte [edx + esi], cl
inc edx
cmp byte [edx + esi], 0
jne 0x40e5d0
movsx eax, bl
movsx ecx, dl
imul ecx, eax
mov al, byte [edx + esi]
xor al, bl
add cl, al
mov byte [edx + esi], cl
jmp 0x40e62b
test bl, bl
je 0x40e62f
xor edx, edx
lea ebx, [ebx]
movsx eax, bl
movsx ecx, dl
imul ecx, eax
mov al, byte [edx + esi]
sub al, cl
xor al, bl
mov byte [edx + esi], al
je 0x40e62b
inc edx
cmp edx, 0xffffffff
jb 0x40e610
mov edx, dword [esp + 0x30]
cmp byte [esp + 0x38], 0
mov esi, dword [edi]
je 0x40e684
mov ecx, dword [edx + 0x3c]
xor edi, edi
movzx eax, word [ecx + edx + 0x14]
add eax, 0x18
add eax, ecx
add edx, eax
mov eax, dword [esp + 0x30]
movzx ebp, word [ecx + eax + 6]
test ebp, ebp
je 0x40e679
mov ecx, dword [edx + 0xc]
cmp ecx, esi
ja 0x40e666
mov eax, dword [edx + 8]
add eax, ecx
cmp eax, esi
ja 0x40e672
inc edi
add edx, 0x28
cmp edi, ebp
jl 0x40e656
xor eax, eax
jmp 0x40e686
sub esi, ecx
cmp esi, dword [edx + 0x10]
jb 0x40e67d
xor eax, eax
jmp 0x40e686
mov eax, dword [edx + 0x14]
add eax, esi
jmp 0x40e686
mov eax, esi
mov ecx, dword [esp + 0x30]
xor ebp, ebp
add ecx, eax
mov dword [esp + 0x18], ebp
mov dword [esp + 0x10], ecx
mov esi, dword [ecx]
test esi, esi
je 0x40e7b0
js 0x40e79f
cmp byte [esp + 0x38], 0
je 0x40e70e
mov ebp, dword [esp + 0x30]
xor edi, edi
mov ecx, dword [ebp + 0x3c]
lea edx, [ebp + 0x18]
movzx eax, word [ecx + ebp + 0x14]
movzx ebp, word [ecx + ebp + 6]
add eax, ecx
add edx, eax
test ebp, ebp
je 0x40e6e8
jmp 0x40e6d0
mov ecx, dword [edx + 0xc]
cmp ecx, esi
ja 0x40e6e0
mov eax, dword [edx + 8]
add eax, ecx
cmp eax, esi
ja 0x40e6f4
inc edi
add edx, 0x28
cmp edi, ebp
jl 0x40e6d0
mov ebp, dword [esp + 0x18]
xor eax, eax
mov ecx, dword [esp + 0x10]
jmp 0x40e710
mov ebp, dword [esp + 0x18]
sub esi, ecx
mov ecx, dword [esp + 0x10]
cmp esi, dword [edx + 0x10]
jb 0x40e707
xor eax, eax
jmp 0x40e710
mov eax, dword [edx + 0x14]
add eax, esi
jmp 0x40e710
mov eax, esi
mov edi, dword [esp + 0x30]
add edi, 2
add edi, eax
cmp dword [esp + 0x14], 0
je 0x40e772
test edi, edi
je 0x40e79f
test bl, bl
je 0x40e79f
xor edx, edx
mov dword [esp + 0x18], edx
cmp byte [edi], dl
je 0x40e755
mov esi, edi
cmp edx, 0xffffffff
jae 0x40e751
movsx eax, bl
movsx ecx, dl
inc edx
imul ecx, eax
mov al, byte [esi]
xor al, bl
add cl, al
mov byte [esi], cl
inc esi
cmp byte [esi], 0
jne 0x40e734
mov dword [esp + 0x18], edx
mov ecx, dword [esp + 0x18]
mov dl, byte [edx + edi]
movsx eax, bl
xor dl, bl
movsx ecx, cl
imul ecx, eax
mov eax, dword [esp + 0x18]
add dl, cl
mov byte [eax + edi], dl
jmp 0x40e79b
test edi, edi
je 0x40e79f
test bl, bl
je 0x40e79f
xor eax, eax
lea esp, [esp]
movsx ecx, bl
movsx edx, al
imul edx, ecx
mov cl, byte [eax + edi]
sub cl, dl
xor cl, bl
mov byte [eax + edi], cl
je 0x40e79b
inc eax
cmp eax, 0xffffffff
jb 0x40e780
mov ecx, dword [esp + 0x10]
mov esi, dword [ecx + ebp*4 + 4]
inc ebp
mov dword [esp + 0x18], ebp
test esi, esi
jne 0x40e6a0
mov edx, dword [esp + 0x1c]
mov ecx, dword [esp + 0x20]
inc edx
mov dword [esp + 0x1c], edx
lea eax, [edx + edx*4]
cmp dword [ecx + eax*4 + 0x10], 0
lea edi, [ecx + eax*4]
mov ecx, dword [esp + 0x14]
mov dword [esp + 0x18], edi
jne 0x40e542
mov edi, dword [esp + 0x30]
mov ebp, dword [esp + 0x34]
test ebx, 0x4000
je 0x40ea75
mov esi, dword [ebp + 0x78]
test esi, esi
je 0x40ea75
cmp byte [esp + 0x38], 0
je 0x40e856
mov ecx, dword [edi + 0x3c]
lea edx, [edi + 0x18]
movzx eax, word [ecx + edi + 0x14]
xor edi, edi
add eax, ecx
add edx, eax
mov eax, dword [esp + 0x30]
movzx ebp, word [ecx + eax + 6]
test ebp, ebp
je 0x40e838
lea ebx, [ebx]
mov ecx, dword [edx + 0xc]
cmp ecx, esi
ja 0x40e830
mov eax, dword [edx + 8]
add eax, ecx
cmp eax, esi
ja 0x40e840
inc edi
add edx, 0x28
cmp edi, ebp
jl 0x40e820
mov edi, dword [esp + 0x30]
xor eax, eax
jmp 0x40e858
mov edi, dword [esp + 0x30]
sub esi, ecx
cmp esi, dword [edx + 0x10]
jb 0x40e84f
xor eax, eax
jmp 0x40e858
mov eax, dword [edx + 0x14]
add eax, esi
jmp 0x40e858
mov eax, esi
cmp byte [esp + 0x38], 0
lea ebp, [eax + edi]
mov esi, dword [ebp + 0xc]
mov dword [esp + 0x18], ebp
je 0x40e8c5
mov ecx, dword [edi + 0x3c]
lea edx, [edi + 0x18]
movzx eax, word [ecx + edi + 0x14]
xor edi, edi
add eax, ecx
add edx, eax
mov eax, dword [esp + 0x30]
movzx ebp, word [ecx + eax + 6]
test ebp, ebp
je 0x40e89f
mov ecx, dword [edx + 0xc]
cmp ecx, esi
ja 0x40e897
mov eax, dword [edx + 8]
add eax, ecx
cmp eax, esi
ja 0x40e8ab
inc edi
add edx, 0x28
cmp edi, ebp
jl 0x40e887
mov ebp, dword [esp + 0x18]
xor eax, eax
mov edi, dword [esp + 0x30]
jmp 0x40e8c7
mov ebp, dword [esp + 0x18]
sub esi, ecx
mov edi, dword [esp + 0x30]
cmp esi, dword [edx + 0x10]
jb 0x40e8be
xor eax, eax
jmp 0x40e8c7
mov eax, dword [edx + 0x14]
add eax, esi
jmp 0x40e8c7
mov eax, esi
lea esi, [eax + edi]
mov eax, ebx
and eax, 0x10000
mov dword [esp + 0x20], eax
je 0x40e8e6
push 0
push dword [esp + 0x28]
push esi
push esi
call fcn.004114d0
jmp 0x40e90b
test esi, esi
je 0x40e90b
test bl, bl
je 0x40e90b
xor edx, edx
movsx eax, bl
movsx ecx, dl
imul ecx, eax
mov al, byte [edx + esi]
sub al, cl
xor al, bl
mov byte [edx + esi], al
je 0x40e90b
inc edx
cmp edx, 0xffffffff
jb 0x40e8f0
cmp dword [ebp + 0x18], 0
mov dword [esp + 0x14], 0
jbe 0x40ea71
lea ecx, [ecx]
cmp byte [esp + 0x38], 0
mov esi, dword [ebp + 0x20]
je 0x40e97e
mov ecx, dword [edi + 0x3c]
lea edx, [edi + 0x18]
movzx eax, word [ecx + edi + 0x14]
xor edi, edi
add eax, ecx
add edx, eax
mov eax, dword [esp + 0x30]
movzx ebp, word [ecx + eax + 6]
test ebp, ebp
je 0x40e960
mov ecx, dword [edx + 0xc]
cmp ecx, esi
ja 0x40e958
mov eax, dword [edx + 8]
add eax, ecx
cmp eax, esi
ja 0x40e968
inc edi
add edx, 0x28
cmp edi, ebp
jl 0x40e948
mov edi, dword [esp + 0x30]
xor eax, eax
jmp 0x40e980
mov edi, dword [esp + 0x30]
sub esi, ecx
cmp esi, dword [edx + 0x10]
jb 0x40e977
xor eax, eax
jmp 0x40e980
mov eax, dword [edx + 0x14]
add eax, esi
jmp 0x40e980
mov eax, esi
cmp byte [esp + 0x38], 0
mov ecx, dword [esp + 0x14]
lea eax, [eax + ecx*4]
mov esi, dword [eax + edi]
je 0x40e9e6
mov ecx, dword [edi + 0x3c]
lea edx, [edi + 0x18]
movzx eax, word [ecx + edi + 0x14]
xor edi, edi
add eax, ecx
add edx, eax
mov eax, dword [esp + 0x30]
movzx ebp, word [ecx + eax + 6]
test ebp, ebp
je 0x40e9c8
nop
mov ecx, dword [edx + 0xc]
cmp ecx, esi
ja 0x40e9c0
mov eax, dword [edx + 8]
add eax, ecx
cmp eax, esi
ja 0x40e9d0
inc edi
add edx, 0x28
cmp edi, ebp
jl 0x40e9b0
mov edi, dword [esp + 0x30]
xor eax, eax
jmp 0x40e9e8
mov edi, dword [esp + 0x30]
sub esi, ecx
cmp esi, dword [edx + 0x10]
jb 0x40e9df
xor eax, eax
jmp 0x40e9e8
mov eax, dword [edx + 0x14]
add eax, esi
jmp 0x40e9e8
mov eax, esi
cmp dword [esp + 0x20], 0
lea esi, [eax + edi]
je 0x40ea34
test esi, esi
je 0x40ea5b
test bl, bl
je 0x40ea5b
xor edx, edx
cmp byte [esi], dl
je 0x40ea1f
cmp edx, 0xffffffff
jae 0x40ea1f
movsx eax, bl
movsx ecx, dl
imul ecx, eax
mov al, byte [edx + esi]
xor al, bl
add cl, al
mov byte [edx + esi], cl
inc edx
cmp byte [edx + esi], 0
jne 0x40ea00
movsx eax, bl
movsx ecx, dl
imul ecx, eax
mov al, byte [edx + esi]
xor al, bl
add cl, al
mov byte [edx + esi], cl
jmp 0x40ea5b
test esi, esi
je 0x40ea5b
test bl, bl
je 0x40ea5b
xor edx, edx
mov edi, edi
movsx eax, bl
movsx ecx, dl
imul ecx, eax
mov al, byte [edx + esi]
sub al, cl
xor al, bl
mov byte [edx + esi], al
je 0x40ea5b
inc edx
cmp edx, 0xffffffff
jb 0x40ea40
mov eax, dword [esp + 0x14]
mov ebp, dword [esp + 0x18]
inc eax
mov dword [esp + 0x14], eax
cmp eax, dword [ebp + 0x18]
jb 0x40e920
mov ebp, dword [esp + 0x34]
test ebx, 0x8000
je 0x40eb5c
mov esi, dword [ebp + 0x88]
test esi, esi
je 0x40eb5c
cmp byte [esp + 0x38], 0
je 0x40eaf2
mov ecx, dword [edi + 0x3c]
lea edx, [edi + 0x18]
movzx eax, word [ecx + edi + 0x14]
xor edi, edi
add eax, ecx
add edx, eax
mov eax, dword [esp + 0x30]
movzx ebp, word [ecx + eax + 6]
test ebp, ebp
je 0x40eacc
mov ecx, dword [edx + 0xc]
cmp ecx, esi
ja 0x40eac4
mov eax, dword [edx + 8]
add eax, ecx
cmp eax, esi
ja 0x40ead8
inc edi
add edx, 0x28
cmp edi, ebp
jl 0x40eab4
mov edi, dword [esp + 0x30]
xor eax, eax
mov ebp, dword [esp + 0x34]
jmp 0x40eaf4
mov edi, dword [esp + 0x30]
sub esi, ecx
mov ebp, dword [esp + 0x34]
cmp esi, dword [edx + 0x10]
jb 0x40eaeb
xor eax, eax
jmp 0x40eaf4
mov eax, dword [edx + 0x14]
add eax, esi
jmp 0x40eaf4
mov eax, esi
lea esi, [eax + edi]
mov eax, dword [ebp + 0x8c]
test ebx, 0x10000
je 0x40eb36
xor ecx, ecx
mov dword [esp + 0x38], ecx
test eax, eax
je 0x40eb5c
nop
mov dl, byte [ecx + esi]
movzx ecx, cl
xor dl, bl
movzx eax, bl
imul ecx, eax
add dl, cl
mov ecx, dword [esp + 0x38]
mov byte [ecx + esi], dl
inc ecx
mov dword [esp + 0x38], ecx
cmp ecx, dword [ebp + 0x8c]
jb 0x40eb10
jmp 0x40eb5c
xor edx, edx
test eax, eax
je 0x40eb5c
lea esp, [esp]
movzx eax, bl
movzx ecx, dl
imul ecx, eax
mov al, byte [edx + esi]
sub al, cl
xor al, bl
mov byte [edx + esi], al
inc edx
cmp edx, dword [ebp + 0x8c]
jb 0x40eb40
cmp dword [esp + 0x28], 0x11000
jne 0x40eb93
mov esi, dword [ebp + 0x54]
xor ecx, ecx
mov dword [esp + 0x38], ecx
test esi, esi
je 0x40eb93
mov dl, byte [ecx + edi]
movzx ecx, cl
xor dl, bl
movzx eax, bl
imul ecx, eax
add dl, cl
mov ecx, dword [esp + 0x38]
mov byte [ecx + edi], dl
inc ecx
mov dword [esp + 0x38], ecx
cmp ecx, esi
jb 0x40eb73
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x1c
ret 0xc