Function at 0x4026c0
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
sub esp, 0x30
push ebx
push ebp
push esi
push edi
mov edi, dword [esp + 0x44]
mov eax, 1
push edi
mov dword [esp + 0x30], eax
mov dword [esp + 0x2c], eax
mov dword [esp + 0x28], eax
call dword [sym.imp.KERNEL32.DLL_GlobalLock]
mov esi, eax
xor eax, eax
test esi, esi
je 0x402aa0
mov ax, word [esi + 0xe]
mov ecx, dword [esp + 0x48]
cmp eax, ecx
mov dword [esp + 0x38], esi
je 0x402710
push edi
call dword [sym.imp.KERNEL32.DLL_GlobalUnlock]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x30
ret
lea eax, [esi + 4]
mov ebp, dword [esi + 8]
mov dword [esp + 0x14], eax
lea ebx, [esi + 8]
mov eax, dword [eax]
mov edi, ebp
mov dword [esp + 0x20], ebx
lea ecx, [eax + eax*2]
lea ecx, [ecx*8 + 0x1f]
shr ecx, 5
shl ecx, 2
imul edi, ecx
test edi, edi
mov dword [esp + 0x18], ecx
je 0x402a93
cmp eax, 0xf3e58
jg 0x402a93
cmp ebp, 0xf3e58
jg 0x402a93
mov eax, edi
xor edx, edx
div ebp
cmp eax, ecx
jb 0x402a93
cmp edi, 0xfffffbd7
ja 0x402a93
add edi, 0x28
push edi
push 0x40
call dword [sym.imp.KERNEL32.DLL_GlobalAlloc]
xor edi, edi
mov dword [esp + 0x3c], eax
cmp eax, edi
jne 0x4027a0
mov edx, dword [esp + 0x44]
push edx
call dword [sym.imp.KERNEL32.DLL_GlobalUnlock]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x30
ret
push eax
call dword [sym.imp.KERNEL32.DLL_GlobalLock]
mov ecx, dword [esp + 0x14]
mov dword [eax], 0x28
mov edx, dword [ecx]
mov dword [eax + 4], edx
mov edx, dword [ebx]
mov dword [eax + 8], edx
mov dword [eax + 0x20], edi
mov word [eax + 0xe], 0x18
mov word [eax + 0xc], 1
mov dword [eax + 0x10], edi
mov dword [eax + 0x14], edi
mov dword [eax + 0x24], edi
mov edx, dword [esi + 0x18]
mov dword [eax + 0x18], edx
mov edx, dword [esi + 0x1c]
mov dword [eax + 0x1c], edx
mov edx, dword [esi + 0x20]
mov edi, dword [esi]
lea edx, [edi + edx*4]
add esi, edx
mov edx, dword [esp + 0x38]
mov edx, dword [edx + 0x10]
cmp edx, 3
jne 0x40280c
mov edi, dword [esi]
add esi, 0xc
mov dword [esp + 0x2c], edi
mov edi, dword [esi - 8]
mov dword [esp + 0x28], edi
mov edi, dword [esi - 4]
mov dword [esp + 0x24], edi
mov ecx, dword [ecx]
lea ebp, [eax + 0x28]
mov eax, dword [esp + 0x48]
mov edi, ecx
imul edi, eax
add edi, 0x1f
shr edi, 5
shl edi, 2
cmp edx, 3
mov dword [esp + 0x1c], edi
jne 0x4028f3
cdq
and edx, 7
mov dword [esp + 0x10], 0
add eax, edx
sar eax, 3
mov dword [esp + 0x30], eax
mov eax, dword [ebx]
test eax, eax
jbe 0x402a75
mov edx, ebp
mov dword [esp + 0x38], esi
mov dword [esp + 0x34], edx
xor ebp, ebp
test ecx, ecx
jbe 0x4028c3
mov ebx, esi
mov ecx, dword [esp + 0x30]
mov esi, ebx
mov eax, ecx
lea edi, [esp + 0x48]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x24]
mov esi, dword [esp + 0x48]
push ecx
push esi
call fcn.004026a0
mov byte [edx], al
mov eax, dword [esp + 0x30]
push eax
push esi
inc edx
call fcn.004026a0
mov ecx, dword [esp + 0x3c]
mov byte [edx], al
push ecx
push esi
inc edx
call fcn.004026a0
mov ecx, dword [esp + 0x48]
mov byte [edx], al
mov eax, dword [esp + 0x2c]
add esp, 0x18
inc edx
add ebx, ecx
mov ecx, dword [eax]
inc ebp
cmp ebp, ecx
jb 0x402861
mov edi, dword [esp + 0x1c]
mov ebx, dword [esp + 0x20]
mov edx, dword [esp + 0x34]
mov esi, dword [esp + 0x18]
mov eax, dword [esp + 0x10]
mov ebp, dword [ebx]
add edx, esi
mov esi, dword [esp + 0x38]
inc eax
add esi, edi
cmp eax, ebp
mov dword [esp + 0x10], eax
mov dword [esp + 0x34], edx
mov dword [esp + 0x38], esi
jb 0x402859
jmp 0x402a75
cmp eax, 0x20
mov eax, dword [ebx]
jne 0x40297f
xor edx, edx
cmp eax, edx
mov dword [esp + 0x10], edx
jbe 0x402a75
mov eax, ebp
mov dword [esp + 0x38], edx
mov dword [esp + 0x48], eax
xor ebp, ebp
test ecx, ecx
jbe 0x402955
lea ecx, [esi + 1]
mov ebx, esi
mov edi, esi
sub ebx, ecx
add edx, ecx
sub edi, ecx
add ebx, 2
mov cl, byte [edi + edx]
add edx, 4
mov byte [eax], cl
mov cl, byte [edx - 4]
inc eax
mov byte [eax], cl
mov cl, byte [ebx + edx - 4]
inc eax
mov byte [eax], cl
mov ecx, dword [esp + 0x14]
inc eax
inc ebp
mov ecx, dword [ecx]
cmp ebp, ecx
jb 0x40292c
mov ebx, dword [esp + 0x20]
mov edi, dword [esp + 0x1c]
mov eax, dword [esp + 0x48]
mov edx, dword [esp + 0x18]
mov ebp, dword [esp + 0x10]
add eax, edx
mov edx, dword [esp + 0x38]
inc ebp
add edx, edi
cmp ebp, dword [ebx]
mov dword [esp + 0x10], ebp
mov dword [esp + 0x48], eax
mov dword [esp + 0x38], edx
jb 0x402916
jmp 0x402a75
test eax, eax
mov dword [esp + 0x10], 0
jbe 0x402a75
mov ebx, esi
mov esi, ebp
lea eax, [ecx + ecx]
mov dword [esp + 0x38], esi
xor edi, edi
test eax, eax
jbe 0x402a4e
mov dx, word [ebx + edi]
mov al, dl
mov word [esp + 0x48], dx
shl al, 3
and eax, 0xff
mov dword [esp + 0x34], eax
fild dword [esp + 0x34]
fmul dword [0x43f2ec]
fadd dword [0x43f2e8]
call fcn.0040f5d8
mov byte [esi], al
mov eax, dword [esp + 0x48]
shr eax, 5
mov cl, al
inc esi
shl cl, 3
and ecx, 0xff
mov dword [esp + 0x48], eax
mov dword [esp + 0x34], ecx
fild dword [esp + 0x34]
fmul dword [0x43f2ec]
fadd dword [0x43f2e8]
call fcn.0040f5d8
mov byte [esi], al
mov eax, dword [esp + 0x48]
shr eax, 5
mov dl, al
inc esi
shl dl, 3
and edx, 0xff
mov dword [esp + 0x48], eax
mov dword [esp + 0x34], edx
fild dword [esp + 0x34]
fmul dword [0x43f2ec]
fadd dword [0x43f2e8]
call fcn.0040f5d8
mov byte [esi], al
mov eax, dword [esp + 0x14]
add edi, 2
inc esi
mov eax, dword [eax]
add eax, eax
cmp edi, eax
jb 0x4029a4
mov esi, dword [esp + 0x38]
mov edx, dword [esp + 0x18]
mov ecx, dword [esp + 0x10]
mov ebp, dword [esp + 0x1c]
add esi, edx
mov edx, dword [esp + 0x20]
inc ecx
add ebx, ebp
mov dword [esp + 0x10], ecx
mov edi, dword [edx]
mov dword [esp + 0x38], esi
cmp ecx, edi
jb 0x40299a
mov eax, dword [esp + 0x44]
mov esi, dword [sym.imp.KERNEL32.DLL_GlobalUnlock]
push eax
call esi
mov edi, dword [esp + 0x3c]
push edi
call esi
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x30
ret
mov ecx, dword [esp + 0x44]
push ecx
call dword [sym.imp.KERNEL32.DLL_GlobalUnlock]
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x30
ret