Function at 0x40a8e0
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push ebx
mov ebx, esp
push 0xffffffffffffffff
push 0x42f7c8
mov eax, dword fs:[0]
push eax
sub esp, 0x18
push ebp
push esi
push edi
mov eax, dword [0x43dfc0]
xor eax, ebx
push eax
lea eax, [ebx - 0xc]
mov dword fs:[0], eax
mov dword [ebx - 0x10], esp
mov esi, dword [ebx + 8]
mov edx, dword [ebx + 0xc]
mov ecx, dword [edx + 0x10]
mov edi, dword [esi]
mov eax, dword [edi + 4]
mov edi, dword [eax + esi + 0x20]
mov edx, dword [eax + esi + 0x24]
mov dword [ebx - 0x18], 0
mov dword [ebx - 0x1c], ecx
or edx, edx
jl 0x40a949
jg 0x40a935
test edi, edi
je 0x40a949
cmp edi, ecx
mov dword [ebx - 0x24], edi
mov dword [ebx - 0x20], edx
jbe 0x40a949
sub edi, ecx
mov dword [ebx - 0x20], edx
mov dword [ebx - 0x14], edi
jmp 0x40a950
mov dword [ebx - 0x14], 0
xor edi, edi
mov eax, dword [eax + esi + 0x38]
cmp eax, edi
mov dword [ebx - 0x24], esi
je 0x40a966
mov ecx, eax
mov edx, dword [eax]
mov eax, dword [edx + 4]
call eax
mov ecx, dword [esi]
mov eax, dword [ecx + 4]
mov dword [ebx - 4], edi
cmp dword [eax + esi + 0xc], edi
jne 0x40a983
mov eax, dword [eax + esi + 0x3c]
cmp eax, edi
je 0x40a983
mov ecx, eax
call fcn.00403560
mov eax, dword [esi]
mov eax, dword [eax + 4]
cmp dword [eax + esi + 0xc], edi
sete cl
mov byte [ebx - 0x20], cl
test cl, cl
mov dword [ebx - 4], 1
jne 0x40a9a7
mov ebp, 4
jmp 0x40aaa9
mov eax, dword [eax + esi + 0x14]
and eax, 0x1c0
cmp eax, 0x40
mov byte [ebx - 4], 2
je 0x40aa62
lea ecx, [ecx]
cmp dword [ebx - 0x14], edi
jbe 0x40aa19
mov edx, dword [esi]
mov eax, dword [edx + 4]
mov ecx, dword [eax + esi + 0x38]
movzx edx, word [eax + esi + 0x40]
mov eax, dword [ecx + 0x24]
cmp dword [eax], edi
je 0x40a9f4
mov eax, dword [ecx + 0x34]
cmp dword [eax], edi
jle 0x40a9f4
dec dword [eax]
mov ecx, dword [ecx + 0x24]
mov eax, dword [ecx]
lea ebp, [eax + 2]
mov dword [ecx], ebp
mov word [eax], dx
mov eax, edx
jmp 0x40a9ff
mov eax, dword [ecx]
push edx
mov edx, dword [eax + 0xc]
call edx
movzx eax, ax
mov ecx, 0xffff
cmp cx, ax
jne 0x40aa14
mov ebp, dword [ebx - 0x18]
or ebp, 4
mov dword [ebx - 0x18], ebp
jmp 0x40aa1c
dec dword [ebx - 0x14]
jmp 0x40a9c0
mov ebp, dword [ebx - 0x18]
cmp ebp, edi
je 0x40aa65
cmp dword [ebx - 0x14], 0
jbe 0x40aa93
mov edx, dword [esi]
mov eax, dword [edx + 4]
movzx edx, word [eax + esi + 0x40]
mov ecx, dword [eax + esi + 0x38]
mov eax, dword [ecx + 0x24]
cmp dword [eax], 0
je 0x40ab13
mov edi, dword [ecx + 0x34]
cmp dword [edi], 0
jle 0x40ab13
dec dword [edi]
mov ecx, dword [ecx + 0x24]
mov edi, dword [ecx]
lea eax, [edi + 2]
mov dword [ecx], eax
mov eax, edx
mov word [edi], dx
jmp 0x40ab1e
mov ebp, dword [ebx - 0x18]
mov eax, dword [ebx + 0xc]
cmp dword [eax + 0x14], 8
jb 0x40aa70
mov eax, dword [eax]
mov edx, dword [esi]
mov ecx, dword [edx + 4]
mov ecx, dword [ecx + esi + 0x38]
mov edx, dword [ecx]
push edi
push dword [ebx - 0x1c]
push eax
mov eax, dword [edx + 0x24]
call eax
cmp eax, dword [ebx - 0x1c]
jne 0x40aa8e
cmp edx, edi
je 0x40aa20
mov ebp, 4
mov eax, dword [esi]
xor edi, edi
mov eax, dword [eax + 4]
mov dword [eax + esi + 0x20], edi
mov dword [eax + esi + 0x24], edi
mov dword [ebx - 4], 1
mov ecx, dword [esi]
mov ecx, dword [ecx + 4]
add ecx, esi
test ebp, ebp
je 0x40aaca
mov eax, dword [ecx + 0xc]
or eax, ebp
cmp dword [ecx + 0x38], 0
jne 0x40aac2
or eax, 4
push 0
push eax
call fcn.00401850
mov dword [ebx - 4], 4
call fcn.0041af82
or al, al
mov edi, dword [ebx - 0x24]
jne 0x40aae4
mov ecx, edi
call fcn.00407930
mov edx, dword [edi]
mov eax, dword [edx + 4]
mov ecx, dword [eax + edi + 0x38]
test ecx, ecx
mov dword [ebx - 4], 0xffffffff
je 0x40aaff
mov edx, dword [ecx]
mov eax, dword [edx + 8]
call eax
mov edi, dword [ebx - 0xc]
mov eax, esi
mov dword fs:[0], edi
pop ecx
pop edi
pop esi
pop ebp
mov esp, ebx
pop ebx
ret
mov eax, dword [ecx]
push edx
mov edx, dword [eax + 0xc]
call edx
movzx eax, ax
mov ecx, 0xffff
cmp cx, ax
jne 0x40ab30
or ebp, 4
jmp 0x40aa93
dec dword [ebx - 0x14]
jmp 0x40aa20