Function at 0x406d75
Capabilities:
Encrypt data using rc4 prga

Disassembly:
add byte [eax], al
scasd eax, dword es:[edi]
mov esi, 0xb70f0007
dec esi
add al, 0x33
rol byte [edx - 0x7d], cl
stc
and byte [edi], cl
lea ebx, [eax - 0x2cfff842]
loop 0x406d52
xchg ecx, eax
mov esi, 0x75ff0007
or al, 0xe9
nop
mov esi, 0x8b550007
in al, dx
push ecx
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
mov dword [ebp - 4], edx
mov ebx, ecx
movzx eax, word [ebx]
xor edx, edx
push ebp
mov ebp, esp
mov eax, 0x11c4
call fcn.0042f8a0
mov eax, dword [ebp + 0xc]
or dword [ebp - 0x28], 0xffffffff
or dword [ebp - 0x20], 0xffffffff
push ebx
push esi
mov ebx, edx
push edi
mov edi, ecx
xor ecx, ecx
xor edx, edx
inc edx
mov esi, ecx
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0x10], edi
mov dword [ebp - 0x30], edx
mov dword [ebp - 8], ecx
mov dword [ebp - 4], esi
mov dword [ebp - 0x18], ecx
mov dword [ebp - 0x24], edi
test eax, eax
je 0x40746d
mov dword [eax], ecx
mov eax, dword [ebp + 0x10]
test eax, eax
je 0x407414
mov dword [eax], ecx
mov dword [ebp - 0xd0], 0x4ae7e0
mov dword [ebp - 0xcc], 0x4ae8e0
mov dword [ebp - 0xc8], 0x4ae9e0
mov dword [ebp - 0xc4], 0x4aeb20
test ebx, 0xd8008580
jne 0x40741b
test ebx, 0x10000
jne 0x407427
push 0x28
pop edx
mov dword [ebp - 0x6c], ecx
cmp word [edi], dx
je 0x482c42
test ebx, 0x800
je 0x407436
cmp dword [ebp - 0x18], 0
mov dword [ebp - 4], 1
jne 0x40742f
test ebx, 0x2000
je 0x482f00
mov ecx, 0x1800000
mov eax, ebx
and eax, ecx
cmp eax, ecx
je 0x40743e
mov eax, ebx
push 2
pop edx
and eax, 0x700000
jne 0x482f1c
mov dword [ebp - 0x54], edx
xor ecx, ecx
lea eax, [ebp - 0x11c0]
mov dword [ebp - 0xbc], eax
mov dword [ebp - 0xb0], eax
mov dword [ebp - 0xc0], eax
mov dword [ebp - 0x84], ecx
mov dword [ebp - 0x80], ecx
mov dword [ebp - 0x8c], ecx
mov dword [ebp - 0x90], ecx
mov dword [ebp - 0xa0], ecx
mov dword [ebp - 0x9c], ecx
mov dword [ebp - 0xa4], ecx
mov dword [ebp - 0x58], ecx
mov dword [ebp - 0x7c], ecx
lea eax, [ebp - 0x1c0]
mov ecx, edi
mov dword [ebp - 0x94], 0x800
mov dword [ebp - 0xa8], eax
mov dword [ebp - 0x98], 0x14
mov dword [ebp - 0xb8], edi
call fcn.00408b7e
lea eax, [edi + eax*2]
mov dword [ebp - 0xb4], eax
lea eax, [edi + esi*2]
mov dword [ebp - 0x38], eax
mov dword [ebp - 0x24], eax
lea eax, [ebp - 0x11c0]
mov dword [ebp - 0x18], eax
xor ecx, ecx
mov eax, 0x83
mov word [ebp - 0x11c0], ax
lea eax, [ebp - 0x30]
push eax
lea eax, [ebp - 0xd0]
push eax
push ecx
lea eax, [ebp - 0x2c]
push eax
lea eax, [ebp - 0x1c]
push eax
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 0x3c]
push eax
push ecx
push ecx
push ecx
push ecx
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0x24]
mov dword [ebp - 0x68], ecx
mov dword [ebp - 0x78], ecx
mov dword [ebp - 0x74], ecx
mov dword [ebp - 0x88], ecx
mov dword [ebp - 0xac], ecx
push eax
lea edx, [ebp - 0x18]
mov ecx, ebx
mov dword [ebp - 0x70], ebx
call fcn.00407474
mov esi, dword [ebp - 8]
add esp, 0x34
test esi, esi
jne 0x48314e
mov ecx, dword [ebp - 0x30]
mov dword [ebp - 0x30], ecx
cmp ecx, 0x10000
jg 0x407442
cmp dword [ebp - 0x58], esi
jne 0x482f9c
mov eax, dword [ebp - 0x9c]
imul eax, dword [ebp - 0xa0]
add eax, ecx
lea esi, [eax*2 + 0x38]
add byte [eax], al
push esi
call dword [0x4bbddc]
mov ebx, eax
pop ecx
test ebx, ebx
je 0x40741f
mov dword [ebx + 4], esi
mov dword [ebx], 0x50435245
mov eax, dword [ebp - 0x70]
mov dword [ebx + 8], eax
mov eax, dword [ebp - 0x6c]
mov dword [ebx + 0xc], eax
mov eax, dword [ebp - 0x28]
mov dword [ebx + 0x10], eax
mov eax, dword [ebp - 0x20]
mov dword [ebx + 0x14], eax
xor eax, eax
mov dword [ebx + 0x18], eax
push 0x1c
pop eax
mov word [ebx + 0x22], ax
mov ax, word [ebp - 0x9c]
mov word [ebx + 0x24], ax
mov ax, word [ebp - 0xa0]
mov word [ebx + 0x26], ax
xor esi, esi
mov dword [ebx + 0x30], esi
mov dword [ebx + 0x34], esi
xor eax, eax
mov dword [ebx + 0x28], eax
mov dword [ebx + 0x2c], eax
mov eax, dword [ebp - 0x90]
mov dword [ebp - 0x8c], eax
mov dword [ebp - 0x78], esi
mov dword [ebp - 0x74], esi
mov dword [ebp - 0x90], esi
mov dword [ebp - 0x88], esi
movzx eax, word [ebx + 0x22]
lea edx, [ebx + eax*2]
mov dword [ebp - 0xa4], edx
movzx eax, word [ebx + 0x24]
movzx ecx, word [ebx + 0x26]
imul ecx, eax
mov eax, dword [ebp - 0xc0]
mov dword [ebp - 0xb0], eax
mov eax, dword [ebp - 0xa0]
lea edi, [edx + ecx*2]
mov dword [ebp - 0x20], edi
mov dword [ebp - 0xbc], edi
mov dword [ebp - 0x68], esi
mov dword [ebp - 0x64], esi
mov dword [ebp - 0x60], esi
mov dword [ebp - 0x5c], esi
mov dword [ebp - 0xac], esi
test eax, eax
jg 0x482fb2
mov eax, dword [ebp - 0x38]
mov dword [ebp - 0x24], eax
push esi
mov eax, 0x83
mov word [edi], ax
mov ecx, dword [ebx + 8]
lea eax, [ebp - 0xd0]
push eax
push esi
lea eax, [ebp - 0x2c]
push eax
lea eax, [ebp - 0x1c]
push eax
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 0x3c]
push eax
push esi
push esi
push esi
push esi
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0x24]
push eax
lea edx, [ebp - 0x18]
mov dword [ebp - 0x18], edi
call fcn.00407474
mov ax, word [ebp - 0x90]
mov word [ebx + 0x1e], ax
mov ax, word [ebp - 0x84]
mov word [ebx + 0x20], ax
mov ax, word [ebp - 0x88]
mov word [ebx + 0x1c], ax
mov eax, dword [ebp - 0x6c]
or eax, 2
add esp, 0x34
mov dword [ebx + 0xc], eax
cmp dword [ebp - 0x64], 0
jne 0x483004
xor bh, bh
invalid
mov eax, dword [ebp - 0x2c]
mov dword [ebp - 0x28], eax
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 0x34], eax
mov esi, dword [ebp - 8]
xor edx, edx
mov dword [ebp - 8], esi
test esi, esi
jne 0x40728a
mov eax, dword [ebp - 0x24]
cmp word [eax], dx
jne 0x483014
mov eax, dword [ebp - 0x18]
xor ecx, ecx
mov word [eax], cx
add eax, 2
mov dword [ebp - 0x18], eax
sub eax, edi
sar eax, 1
cmp eax, dword [ebp - 0x30]
jg 0x48301f
mov eax, dword [ebp - 0xb0]
mov ecx, dword [ebp - 0xc0]
cmp eax, ecx
ja 0x48302a
cmp dword [ebp - 0x94], 0x800
jg 0x48309e
xor eax, eax
mov dword [ebp - 0xc0], eax
test esi, esi
jne 0x4072e3
mov ax, word [ebx + 0x20]
cmp ax, word [ebx + 0x1e]
ja 0x4830ab
test dword [ebp - 0x14], 0x20000
mov esi, dword [ebp - 4]
jne 0x407300
lea eax, [ebp - 0xd0]
push eax
mov edx, esi
mov ecx, edi
call fcn.00408b8e
pop ecx
cmp dword [ebp - 0x5c], 0
jne 0x4830b6
mov esi, dword [ebp - 8]
test esi, esi
jne 0x483146
mov eax, dword [ebx + 8]
mov esi, 0x80
mov dword [ebp - 0x38], eax
mov dword [ebp + 0xc], esi
jne 0x40732f
test al, 0x10
jne 0x407380
xor esi, esi
lea eax, [ebp - 0xd0]
push esi
push eax
xor edx, edx
mov ecx, edi
call 0x406d75
pop ecx
pop ecx
test eax, eax
jne 0x48317c
mov eax, dword [ebp - 0xc]
test eax, eax
jns 0x4073bf
push esi
lea edx, [ebp - 0xc]
mov ecx, edi
call fcn.00406bc4
mov edx, eax
mov eax, dword [ebp - 0xc]
pop ecx
test eax, eax
jns 0x4073c2
lea eax, [ebp - 0xd0]
push esi
push eax
xor edx, edx
mov ecx, edi
call fcn.00406c8a
pop ecx
pop ecx
test eax, eax
jne 0x48318a
mov esi, 0x80
mov eax, dword [ebp - 0x28]
test eax, eax
jns 0x4073d9
mov esi, dword [ebp - 0x18]
xor eax, eax
push eax
lea eax, [ebp - 0xd0]
push eax
push dword [ebp - 4]
mov edx, esi
mov ecx, edi
call fcn.00408922
add esp, 0xc
test eax, eax
jne 0x407461
xor bh, bh
invalid
movzx eax, word [edi + 2]
lea edi, [edi + eax*2]
cmp word [edi], 0x77
je 0x40738a
mov eax, ebx
pop edi
pop esi
pop ebx
leave
ret
mov edx, dword [ebp - 0x3c]
mov word [ebx + 0x18], dx
test al, 1
jne 0x483196
mov esi, 0x80
or dword [ebx + 0xc], 0x10
jmp 0x407380
test byte [ebx + 8], 0x10
jne 0x407446
mov edx, dword [ebp - 0x34]
mov word [ebx + 0x1a], dx
test al, 1
je 0x40740b
cmp dword [ebp - 4], 0
je 0x407450
cmp dx, si
jae 0x48320d
mov eax, dword [ebp - 0xcc]
movzx ecx, dx
movzx eax, byte [ecx + eax]
cmp ax, dx
jne 0x40745c
or dword [ebx + 0xc], 0x40
jmp 0x407387
push 0x10
jmp 0x482c3c
push 0x11
jmp 0x407421
push 0x15
pop esi
jmp 0x48314e
mov dword [ebp - 0x18], edx
jmp 0x406f99
push 0x4e
jmp 0x482c3c
mov dword [ebp - 4], ecx
jmp 0x406fd1
push 0x38
jmp 0x407421
push 0x14
jmp 0x407421
test al, 2
je 0x407387
jmp 0x4073df
mov eax, 0xff
cmp dx, ax
ja 0x40740b
jmp 0x4073f9
or dword [ebx + 0xc], esi
jmp 0x40740b
or dword [ebx + 0xc], 0x8000
jmp 0x4073b8
xor eax, eax
jmp 0x4073ba
mov eax, dword [eax]
push esi
mov esi, dword [edx]
push edi
mov edi, dword [ebp + 0x34]
mov dword [esp + 0x20], eax
mov eax, dword [ebp + 0x30]
mov dword [esp + 0x68], eax
push 0xfffffffffffffffe
pop eax
mov dword [esp + 0x40], ecx
xor ecx, ecx
mov dword [esp + 0x50], edx
mov edx, dword [ebp + 0x18]
mov dword [esp + 0x10], eax
mov dword [esp + 0x30], eax
mov dword [esp + 0x44], ecx
mov dword [esp + 0x48], ecx
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x2c], ecx
mov eax, 0x85
mov dword [esp + 0x6c], esi
lea ecx, [edx + 4]
mov dword [esp + 0x14], esi
mov dword [esp + 0x4c], esi
mov dword [esp + 0xc], ecx
cmp word [esi], ax
je 0x407673
movzx ebx, word [esi + 4]
mov eax, dword [edi + 0x24]
mov dword [esp + 0x60], eax
xor eax, eax
ret
je 0x41d8ff
push ecx
invalid
invalid