Function at 0x40a330
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
lea esp, [esp - 0x5c]
push ebx
push esi
push edi
mov bl, al
mov byte [ebp - 0x5c], dl
mov byte [ebp - 0x58], cl
mov al, byte [ebp + 0x24]
mov byte [ebp - 0x54], al
mov esi, dword [ebp + 0x20]
mov al, byte [ebp + 0x1c]
mov byte [ebp - 0x40], al
mov eax, dword [ebp + 0x18]
mov dword [ebp - 0x50], eax
mov eax, dword [ebp + 0x14]
mov dword [ebp - 0x4c], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x48], eax
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x44], eax
mov eax, dword [ebp + 8]
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x38], 0
mov dword [ebp - 0x34], 0
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x18], 0
mov dword [ebp - 8], 0
xor eax, eax
push fcn.0040a300
push ebp
push 0x458b20
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, dword [ebp - 0x3c]
xor edx, edx
call fcn.0044c930
movzx eax, bl
shl eax, 7
mov bl, al
movzx eax, byte [ebp - 0x5c]
shl eax, 6
movzx edx, bl
add eax, edx
mov bl, al
movzx eax, byte [ebp - 0x58]
shl eax, 5
movzx edx, bl
add eax, edx
mov bl, al
movzx eax, byte [ebp - 0x54]
shl eax, 4
movzx edx, bl
add eax, edx
mov bl, al
and eax, 0xff
add eax, esi
mov bl, al
push 0
mov al, bl
lea ecx, [ebp - 8]
xor dx, dx
call fcn.0044d220
mov ecx, dword [ebp - 8]
mov eax, dword [ebp - 0x3c]
mov edx, dword [eax]
mov eax, dword [ebp - 0x3c]
call fcn.0044ca30
movzx eax, byte [ebp - 0x40]
shl eax, 7
mov bl, al
mov ecx, dword [ebp - 0x4c]
mov esi, ecx
sar esi, 0x1f
mov edx, dword [ebp - 0x44]
mov eax, edx
sar eax, 0x1f
add ecx, edx
adc esi, eax
mov edi, ecx
test esi, esi
jl 0x40a433
jg 0x40a443
cmp edi, 0x7e
jae 0x40a443
movzx eax, bl
mov edx, 0
add eax, edi
adc edx, esi
mov bl, al
jmp 0x40a463
test esi, esi
jl 0x40a451
jg 0x40a45b
cmp edi, 0x10000
jae 0x40a45b
movzx eax, bl
add eax, 0x7e
mov bl, al
jmp 0x40a463
movzx eax, bl
add eax, 0x7f
mov bl, al
push 0
mov al, bl
lea ecx, [ebp - 8]
xor dx, dx
call fcn.0044d220
mov ecx, dword [ebp - 8]
mov eax, dword [ebp - 0x3c]
mov edx, dword [eax]
mov eax, dword [ebp - 0x3c]
call fcn.0044ca30
test esi, esi
jg 0x40a495
jl 0x40a594
cmp edi, 0x7e
jb 0x40a594
test esi, esi
jl 0x40a4a3
jg 0x40a4fd
cmp edi, 0x10000
jae 0x40a4fd
push 0
mov edx, dword [ebp - 0x3c]
mov eax, dword [edx]
mov dword [ebp - 0x14], eax
mov edx, edi
mov eax, esi
shrd edx, eax, 8
shr eax, 8
mov eax, edx
and eax, 0xff
lea ecx, [ebp - 0x18]
xor dx, dx
call fcn.0044d220
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x10], eax
mov eax, edi
and eax, 0xff
lea ecx, [ebp - 0x1c]
xor dx, dx
call fcn.0044d220
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 0xc], eax
lea edx, [ebp - 0x14]
mov eax, dword [ebp - 0x3c]
mov ecx, 2
call fcn.0044ccc0
jmp 0x40a594
push 0
mov eax, dword [ebp - 0x3c]
mov edx, dword [eax]
mov dword [ebp - 0x30], edx
mov eax, edi
mov edx, esi
shrd eax, edx, 0x18
shr edx, 0x18
and eax, 0xff
lea ecx, [ebp - 0x1c]
xor dx, dx
call fcn.0044d220
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 0x2c], eax
mov eax, edi
mov edx, esi
shrd eax, edx, 0x10
shr edx, 0x10
and eax, 0xff
lea ecx, [ebp - 0x18]
xor dx, dx
call fcn.0044d220
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x28], eax
mov edx, edi
mov eax, esi
shrd edx, eax, 8
shr eax, 8
mov eax, edx
and eax, 0xff
lea ecx, [ebp - 0x34]
xor dx, dx
call fcn.0044d220
mov eax, dword [ebp - 0x34]
mov dword [ebp - 0x24], eax
mov eax, edi
and eax, 0xff
lea ecx, [ebp - 0x38]
xor dx, dx
call fcn.0044d220
mov eax, dword [ebp - 0x38]
mov dword [ebp - 0x20], eax
lea edx, [ebp - 0x30]
mov eax, dword [ebp - 0x3c]
mov ecx, 4
call fcn.0044ccc0
mov al, byte [ebp - 0x40]
test al, al
je 0x40a654
mov eax, 0x100
call fcn.00452cc0
mov byte [ebp - 4], al
mov eax, 0x100
call fcn.00452cc0
mov byte [ebp - 3], al
mov eax, 0x100
call fcn.00452cc0
mov byte [ebp - 2], al
mov eax, 0x100
call fcn.00452cc0
mov byte [ebp - 1], al
push 0
mov al, byte [ebp - 4]
lea ecx, [ebp - 8]
xor dx, dx
call fcn.0044d220
mov ecx, dword [ebp - 8]
mov eax, dword [ebp - 0x3c]
mov edx, dword [eax]
mov eax, dword [ebp - 0x3c]
call fcn.0044ca30
push 0
mov al, byte [ebp - 3]
lea ecx, [ebp - 8]
xor dx, dx
call fcn.0044d220
mov ecx, dword [ebp - 8]
mov eax, dword [ebp - 0x3c]
mov edx, dword [eax]
mov eax, dword [ebp - 0x3c]
call fcn.0044ca30
push 0
mov al, byte [ebp - 2]
lea ecx, [ebp - 8]
xor dx, dx
call fcn.0044d220
mov ecx, dword [ebp - 8]
mov eax, dword [ebp - 0x3c]
mov edx, dword [eax]
mov eax, dword [ebp - 0x3c]
call fcn.0044ca30
push 0
mov al, byte [ebp - 1]
lea ecx, [ebp - 8]
xor dx, dx
call fcn.0044d220
mov ecx, dword [ebp - 8]
mov eax, dword [ebp - 0x3c]
mov edx, dword [eax]
mov eax, dword [ebp - 0x3c]
call fcn.0044ca30
nop
mov edx, dword [ebp - 0x3c]
mov eax, dword [edx]
test eax, eax
je 0x40a660
mov eax, dword [eax - 4]
mov edi, eax
mov eax, dword [ebp - 0x4c]
lea ecx, [edi + eax]
mov edx, dword [ebp - 0x44]
add edx, ecx
mov eax, dword [ebp - 0x3c]
xor cx, cx
call fcn.0044d580
mov eax, dword [ebp - 0x3c]
call fcn.00447cb0
lea edx, [edi + 1]
lea edx, [eax + edx - 1]
mov eax, dword [ebp - 0x50]
mov ecx, dword [ebp - 0x4c]
call fcn.004477c0
mov eax, dword [ebp - 0x3c]
call fcn.00447cb0
mov edx, dword [ebp - 0x4c]
lea ecx, [edi + edx]
lea edx, [ecx + 1]
lea edx, [eax + edx - 1]
mov eax, dword [ebp - 0x48]
mov ecx, dword [ebp - 0x44]
call fcn.004477c0
mov al, byte [ebp - 0x40]
test al, al
je 0x40a6f8
mov eax, dword [ebp - 0x3c]
mov edx, dword [eax]
lea eax, [edi + 1]
lea esi, [edx + eax - 1]
mov eax, dword [ebp - 0x3c]
mov ebx, dword [eax]
test ebx, ebx
je 0x40a6d1
mov ebx, dword [ebx - 4]
sub ebx, edi
sub ebx, 1
test ebx, ebx
jl 0x40a6f8
mov ecx, 0xffffffff
nop
add ecx, 1
mov eax, ecx
and eax, 3
mov dl, byte [ebp + eax - 4]
xor byte [esi], dl
add esi, 1
cmp ebx, ecx
jg 0x40a6e0
lea esi, [esi]
xor eax, eax
pop edx
add esp, 0xc
mov dword fs:[eax], edx
mov eax, ebp
call fcn.0040a300
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x20