Function at 0x401d90
Capabilities:
Encode data using xor
Encrypt data using rc4 ksa

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x15c
push ebx
push esi
xor esi, esi
push edi
mov ecx, 0x352f
mov edi, 0x740a
mov ebx, 0xbd
mov dword [ebp - 0x54], 0x728a
mov dword [ebp - 0x38], 0x50ae
mov dword [ebp - 0x40], 0xae
mov dword [ebp - 8], esi
mov dword [ebp - 4], 0x77d7
mov dword [ebp - 0x2c], esi
mov dword [ebp - 0x50], esi
mov dword [ebp - 0x30], 0x8a
mov dword [ebp - 0x5c], 0x2377
mov dword [ebp - 0x48], 0x7f3b
mov dword [ebp - 0x58], esi
mov dword [ebp - 0x28], esi
mov dword [ebp - 0xc], esi
mov dword [ebp - 0x34], 0xd2
mov dword [ebp - 0x3c], 0x1790
mov dword [ebp - 0x44], 0x74ae
mov dword [ebp - 0x4c], 0x6533
lea esp, [esp]
mov eax, 0x8d3dcb09
imul ecx
add edx, ecx
sar edx, 5
mov ecx, edx
shr ecx, 0x1f
add ecx, edx
jne 0x401e10
cmp dword [ebp + 8], esi
je 0x4024b7
mov edx, dword [ebp + 0xc]
test edx, edx
je 0x4024b7
mov ecx, dword [ebp + 0x10]
mov eax, dword [ecx + 0xd8]
xor eax, dword [ecx]
cmp edx, eax
jl 0x4024b7
call fcn.004033f0
mov edx, dword [ebp + 0x10]
mov dword [edx + 0xc4], eax
lea ebx, [ebx]
mov eax, 0xe1fc780f
imul edi
add edx, edi
sar edx, 7
mov edi, edx
shr edi, 0x1f
add edi, edx
jne 0x401e60
mov edx, dword [ebp + 0x10]
mov esi, 0x14a0
mov eax, dword [edx + 0xd8]
xor dword [edx + 4], eax
mov edi, dword [edx + 4]
lea ecx, [edx + 0xd8]
nop
mov eax, 0x4bda12f7
imul esi
sar edx, 6
mov esi, edx
shr esi, 0x1f
add esi, edx
jne 0x401e90
mov edx, dword [ebp + 0x10]
mov eax, 0x459e
mov dword [edx + 0x170], ecx
mov ecx, 0x69
cmp ebx, ecx
cmovl ebx, ecx
dec eax
jne 0x401eb6
mov edi, edi
inc esi
mov eax, esi
and eax, 0x80000007
jns 0x401ecf
dec eax
or eax, 0xfffffff8
inc eax
jne 0x401ed2
inc esi
cmp esi, 0x29a1
jl 0x401ec0
mov eax, 0x6f
mov edx, 0x5b
mov ecx, 0xa1
lea esp, [esp]
cmp ecx, edx
cmovl ecx, edx
dec eax
jne 0x401ef0
mov eax, dword [ebp + 0xc]
xor edx, edx
div edi
mov ecx, dword [ebp + 0x10]
mov edx, 0x3f
imul edi, eax
mov dword [ecx + 0xc], eax
mov dword [ecx + 0x2b8], edi
mov eax, 0x14af
mov ecx, 2
lea ecx, [ecx]
cmp ecx, edx
cmovg ecx, edx
dec eax
jne 0x401f20
xor esi, esi
test edi, edi
mov edi, dword [ebp + 0x10]
je 0x401f7b
mov ebx, dword [ebp + 8]
mov eax, dword [edi + 0x170]
inc esi
mov al, byte [eax]
xor byte [esi + ebx - 1], al
movzx ecx, byte [esi + ebx - 1]
mov eax, dword [edi + 0x170]
mov dl, byte [eax + 1]
xor dl, cl
mov byte [esi + ebx - 1], dl
mov eax, dword [edi + 0x170]
mov cl, byte [eax + 2]
xor cl, dl
mov byte [esi + ebx - 1], cl
mov eax, dword [edi + 0x170]
mov al, byte [eax + 3]
xor al, cl
mov byte [esi + ebx - 1], al
cmp esi, dword [edi + 0x2b8]
jb 0x401f34
mov eax, dword [edi + 4]
xor esi, esi
dec eax
je 0x402085
mov ecx, dword [ebp + 0x10]
xor edi, edi
lea esp, [esp]
mov eax, dword [ecx + 4]
dec eax
push eax
push 1
push ecx
call fcn.00403280
mov edx, dword [ebp + 0x10]
add esp, 0xc
mov bl, al
xor ecx, ecx
cmp bl, byte [edx + ecx + 0x17c]
je 0x401fb7
inc ecx
cmp ecx, esi
jbe 0x401fa7
jmp 0x401fb9
xor bl, bl
mov ecx, dword [ebp - 0x54]
test ecx, ecx
je 0x401fd5
mov eax, 0x43b3d5b
imul ecx
sar edx, 1
mov ecx, edx
shr ecx, 0x1f
add ecx, edx
jne 0x401fc0
mov dword [ebp - 0x54], ecx
mov ecx, dword [ebp - 0x38]
test ecx, ecx
je 0x401ff8
lea esp, [esp]
mov eax, 0x8fb823ef
imul ecx
add edx, ecx
sar edx, 6
mov ecx, edx
shr ecx, 0x1f
add ecx, edx
jne 0x401fe0
mov dword [ebp - 0x38], ecx
cmp edi, 0x2cdb
jge 0x40201a
mov ecx, 0x2cda
sub ecx, edi
mov eax, 0xcccccccd
mul ecx
shr edx, 3
lea eax, [edx + edx*4]
lea edi, [edi + eax*2]
add edi, 0xa
test bl, bl
je 0x402029
mov eax, dword [ebp + 0x10]
inc esi
mov byte [eax + esi + 0x17b], bl
mov ecx, dword [ebp - 0x40]
mov eax, 0x499e
mov edx, 0x35
cmp ecx, edx
cmovg ecx, edx
dec eax
jne 0x402036
mov ebx, dword [ebp - 8]
mov dword [ebp - 0x40], ecx
cmp ebx, 0x8d3
jge 0x402074
mov ecx, 0x8d2
sub ecx, ebx
mov eax, 0x24924925
mul ecx
sub ecx, edx
shr ecx, 1
add ecx, edx
shr ecx, 2
add ebx, 7
lea eax, [ecx*8]
sub eax, ecx
add ebx, eax
mov dword [ebp - 8], ebx
mov ecx, dword [ebp + 0x10]
mov eax, dword [ecx + 4]
dec eax
cmp esi, eax
jb 0x401f90
mov edi, ecx
push 0x7f
lea eax, [ebp - 0xdb]
push 0
push eax
mov byte [ebp - 0xdc], 0
call fcn.00403140
lea eax, [ebp - 0xdc]
push eax
call fcn.00402a10
lea esi, [edi + 0x27c]
mov dword [ebp - 0x24], 0x42a6e008
mov dword [ebp - 0x20], 0x53104db2
movq xmm0, qword [ebp - 0x24]
movq qword [esi], xmm0
mov dword [ebp - 0x1c], 0x960fe55d
mov dword [ebp - 0x18], 0x2e478205
movq xmm0, qword [ebp - 0x1c]
movq qword [esi + 8], xmm0
mov dword [ebp - 0x14], 0xb71df9c6
mov dword [ebp - 0x10], 0
movq xmm0, qword [ebp - 0x14]
add esp, 0x10
mov dword [ebp - 8], esi
movq qword [esi + 0x10], xmm0
xor eax, eax
lea ecx, [ecx]
xor byte [ebp + eax - 0xdc], 6
inc eax
cmp eax, 0x7e
jb 0x402100
mov edi, edi
mov eax, 0x3e0f83e1
imul dword [ebp - 4]
sar edx, 5
mov eax, edx
shr eax, 0x1f
add eax, edx
mov dword [ebp - 4], eax
jne 0x402110
xor ebx, ebx
lea esp, [esp]
inc ebx
mov eax, 0x66666667
imul ebx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
lea ecx, [eax + eax*4]
add ecx, ecx
mov eax, ebx
sub eax, ecx
jne 0x402150
add ebx, 5
cmp ebx, 0x3c9b
jl 0x402130
xor eax, eax
mov dword [ebp - 4], eax
cmp dword [edi + 4], eax
jbe 0x40237b
jmp 0x402170
movzx ebx, byte [edi + eax + 0x17c]
imul ebx, dword [edi + 0xc]
mov esi, dword [ebp - 0x2c]
add ebx, dword [ebp + 8]
cmp esi, 0x3fb
jge 0x4021b6
lea ebx, [ebx]
inc esi
mov eax, 0x38e38e39
imul esi
sar edx, 1
mov eax, edx
shr eax, 0x1f
add eax, edx
mov ecx, esi
lea eax, [eax + eax*8]
sub ecx, eax
jne 0x4021ab
inc esi
cmp esi, 0x3fb
jl 0x402190
mov dword [ebp - 0x2c], esi
push 0x7f
lea eax, [ebp - 0x15b]
push 0
push eax
mov dword [edi + 0x2c4], ebx
mov byte [ebp - 0x15c], 0
call fcn.00403140
mov esi, dword [ebp - 0x50]
add esp, 0xc
cmp esi, 0x536c
jge 0x4021fe
mov ecx, 0x536b
sub ecx, esi
mov eax, 0xcccccccd
mul ecx
shr edx, 3
lea eax, [edx + edx*4]
lea esi, [esi + eax*2]
add esi, 0xa
mov dword [ebp - 0x50], esi
push 0x7f
lea eax, [ebp - 0x15c]
push ebx
push eax
call fcn.00403110
mov ecx, 0x1f
lea esi, [ebp - 0xdc]
mov edi, ebx
rep movsd dword es:[edi], dword [esi]
mov ecx, dword [ebp - 0x30]
add esp, 0xc
movsw word es:[edi], word [esi]
mov eax, 0x45fe
mov edx, 0x4a
mov edi, edi
cmp ecx, edx
cmovl ecx, edx
dec eax
jne 0x402230
mov dword [ebp - 0x30], ecx
mov ecx, dword [ebp - 0x5c]
test ecx, ecx
je 0x40225a
mov eax, 0xf2b9d649
imul ecx
add edx, ecx
sar edx, 7
mov ecx, edx
shr ecx, 0x1f
add ecx, edx
jne 0x402242
mov dword [ebp - 0x5c], ecx
mov edi, dword [ebp + 0x10]
mov ecx, dword [edi + 0x2c4]
call ecx
mov eax, dword [ebp - 0x48]
test eax, eax
je 0x40227a
lea esp, [esp]
cdq
sub eax, edx
sar eax, 1
jne 0x402270
mov dword [ebp - 0x48], eax
push 0x7f
lea eax, [ebp - 0x15c]
push eax
push ebx
call fcn.00403110
mov eax, dword [ebp - 0x58]
add esp, 0xc
nop
inc eax
cmp eax, 0x3a31
jl 0x402290
xor esi, esi
mov dword [ebp - 0x58], eax
cmp dword [edi + 0xc], esi
jbe 0x4022e6
mov eax, dword [edi + 0x170]
inc esi
mov al, byte [eax + 3]
xor byte [esi + ebx - 1], al
movzx ecx, byte [esi + ebx - 1]
mov eax, dword [edi + 0x170]
mov dl, byte [eax + 2]
xor dl, cl
mov byte [esi + ebx - 1], dl
mov eax, dword [edi + 0x170]
mov cl, byte [eax + 1]
xor cl, dl
mov byte [esi + ebx - 1], cl
mov eax, dword [edi + 0x170]
mov al, byte [eax]
xor al, cl
mov byte [esi + ebx - 1], al
cmp esi, dword [edi + 0xc]
jb 0x4022a2
mov ecx, dword [ebp - 0x28]
cmp ecx, 0x2f94
jge 0x40230e
inc ecx
mov eax, ecx
and eax, 0x80000003
jns 0x402300
dec eax
or eax, 0xfffffffc
inc eax
jne 0x402303
inc ecx
cmp ecx, 0x2f94
jl 0x4022f1
mov dword [ebp - 0x28], ecx
mov ebx, dword [ebp - 0xc]
cmp ebx, 0x1ec4
jge 0x402352
lea esp, [esp]
inc ebx
mov eax, 0x38e38e39
imul ebx
sar edx, 1
mov eax, edx
shr eax, 0x1f
add eax, edx
mov ecx, ebx
lea eax, [eax + eax*8]
sub ecx, eax
jne 0x40233e
add ebx, ebx
jmp 0x402347
mov eax, ebx
cdq
sub eax, edx
sar eax, 1
add ebx, eax
cmp ebx, 0x1ec4
jl 0x402320
mov dword [ebp - 0xc], ebx
mov ecx, dword [ebp - 0x34]
mov eax, 0x75d1
mov edx, 0x2f
nop
cmp ecx, edx
cmovg ecx, edx
dec eax
jne 0x402360
mov eax, dword [ebp - 4]
inc eax
mov dword [ebp - 0x34], ecx
mov dword [ebp - 4], eax
cmp eax, dword [edi + 4]
jb 0x402170
xor ecx, ecx
lea ecx, [ecx]
inc ecx
mov eax, ecx
and eax, 0x80000003
jns 0x40238f
dec eax
or eax, 0xfffffffc
inc eax
jne 0x402394
add ecx, 2
cmp ecx, 0x3afc
jl 0x402380
call fcn.004033f0
mov dword [edi + 0x324], eax
add eax, 0xfffffffe
push eax
push dword [edi + 0xc4]
call fcn.00401190
add esp, 8
lea esp, [esp]
mov eax, 0x2aaaaaab
imul dword [ebp - 0x3c]
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
mov dword [ebp - 0x3c], eax
jne 0x4023c0
mov esi, 0x1592
lea esp, [esp]
mov eax, 0x2aaaaaab
imul esi
sar edx, 2
mov esi, edx
shr esi, 0x1f
add esi, edx
jne 0x4023e0
mov esi, dword [ebp - 8]
mov eax, 0xa53
mov edx, 0x20
mov ecx, 0x47
cmp ecx, edx
cmovg ecx, edx
dec eax
jne 0x402405
mov eax, 0x4db
mov edx, 0x26
mov ecx, 0x15
lea esp, [esp]
cmp ecx, edx
cmovl ecx, edx
dec eax
jne 0x402420
push 0x3282ae
push esi
call fcn.00401c50
add esp, 8
xor ecx, ecx
inc ecx
mov eax, ecx
and eax, 0x80000003
jns 0x402447
dec eax
or eax, 0xfffffffc
inc eax
jne 0x40244a
inc ecx
cmp ecx, 0x55e7
jl 0x402438
mov eax, 0x6bca1af3
imul dword [ebp - 0x44]
sar edx, 3
mov eax, edx
shr eax, 0x1f
add eax, edx
mov dword [ebp - 0x44], eax
jne 0x402452
mov eax, dword [ebp + 0xc]
cdq
and edx, 0xff
lea esi, [edx + eax]
sar esi, 8
test esi, esi
je 0x4024a0
mov edi, dword [ebp - 8]
mov ebx, dword [ebp + 8]
push edi
push 0x100
push ebx
call fcn.00403170
add esp, 0xc
add ebx, 0x100
dec esi
jne 0x402483
jmp 0x4024a0
mov eax, 0x4ec4ec4f
imul dword [ebp - 0x4c]
sar edx, 6
mov eax, edx
shr eax, 0x1f
add eax, edx
mov dword [ebp - 0x4c], eax
jne 0x4024a0
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret