Function at 0x43f0cc
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
test dword [0x4b63ec], 0xffffff80
jne 0x43f0f4
test dword [0x4b63ec], 0xffffffff
jne 0x43f4f0
call fcn.00490ee4
jmp fcn.0043f0cc
push edi
push esi
push ebp
push ebx
sub esp, 0x46c
mov edi, ecx
mov esi, dword [esp + 0x480]
mov ebp, dword [esp + 0x484]
movzx eax, byte [edi + 0x12]
xor edx, edx
test eax, eax
mov eax, 1
je 0x43f11f
mov eax, edx
movzx ecx, byte [edi + 0x22]
test ecx, ecx
mov ecx, 1
je 0x43f12e
mov ecx, edx
cmp eax, ecx
mov eax, 1
cmove eax, edx
mov dword [esp + 0x43c], eax
movzx eax, word [edi + 0x24]
mov dword [esp + 0x414], eax
movzx eax, word [edi + 0x26]
mov dword [esp + 0x418], eax
movzx eax, word [edi + 0x28]
mov dword [esp + 0x41c], eax
movzx eax, byte [edi + 0x2a]
mov dword [esp + 0x408], eax
movzx eax, byte [edi + 0x2b]
mov dword [esp + 0x40c], eax
movzx eax, byte [edi + 0x2c]
mov dword [esp + 0x410], eax
lea eax, [esp]
push 0x400
push edx
push eax
call fcn.004910c4
add esp, 0xc
test ebp, ebp
jle 0x43f4e9
xor ecx, ecx
xor edx, edx
xor eax, eax
mov dword [esp + 0x440], ecx
mov edi, dword [edi + 0x197c]
mov dword [esp + 0x420], edi
cmp eax, esi
jge 0x43f4dd
mov ecx, ebp
sub ecx, edx
test ecx, ecx
mov dword [esp + 0x424], ecx
jle 0x43f40b
mov dword [esp + 0x404], eax
xor ebx, ebx
mov ecx, esi
mov dword [esp + 0x400], edx
sub ecx, eax
add ecx, 0xfffffff9
mov dword [esp + 0x438], ecx
mov edi, esi
imul edi, edx
add edi, eax
mov dword [esp + 0x42c], edi
mov eax, dword [esp + 0x438]
cmp ebx, eax
jge 0x43f4bc
mov edi, dword [esp + 0x480]
imul edi, ebx
lea eax, [ebx + edi]
mov esi, dword [esp + 0x420]
mov edx, dword [esp + 0x43c]
add eax, dword [esp + 0x42c]
movzx esi, word [esi + eax*2]
test edx, edx
je 0x43f242
mov eax, esi
shl eax, 8
sar esi, 8
or eax, esi
movzx esi, ax
add edi, dword [esp + 0x42c]
mov ebp, dword [esp + 0x414]
mov ecx, dword [esp + 0x408]
mov dword [esp + 0x45c], ecx
mov edx, esi
sar edx, cl
and edx, ebp
mov ecx, dword [esp + 0x40c]
mov dword [esp + 0x434], edx
mov edx, dword [esp + 0x418]
mov eax, esi
mov dword [esp + 0x458], ecx
add edi, ebx
sar eax, cl
and eax, edx
mov ecx, dword [esp + 0x410]
mov dword [esp + 0x430], eax
mov eax, dword [esp + 0x41c]
mov dword [esp + 0x464], ecx
sar esi, cl
and esi, eax
mov ecx, 1
mov dword [esp + 0x460], ecx
mov ecx, dword [esp + 0x420]
lea ecx, [ecx + edi*2 + 2]
mov dword [esp + 0x450], ecx
mov edi, dword [esp + 0x434]
mov dword [esp + 0x454], esi
mov esi, dword [esp + 0x430]
mov dword [esp + 0x444], eax
mov dword [esp + 0x44c], edx
mov dword [esp + 0x448], ebp
mov dword [esp + 0x428], ebx
mov ebp, dword [esp + 0x450]
movzx ebp, word [ebp]
mov edx, dword [esp + 0x43c]
test edx, edx
je 0x43f31a
mov edx, ebp
shl edx, 8
sar ebp, 8
or edx, ebp
movzx ebp, dx
inc dword [esp + 0x440]
mov ecx, dword [esp + 0x45c]
add dword [esp + 0x450], 2
mov edx, ebp
neg edi
sar edx, cl
mov ecx, dword [esp + 0x458]
and edx, dword [esp + 0x448]
add edi, edx
mov eax, edi
mov dword [esp + 0x468], edx
neg esi
cdq
mov ebx, edx
xor edi, ebx
neg ebx
add ebx, edi
mov edi, dword [esp + 0x468]
mov eax, ebp
sar eax, cl
mov ecx, dword [esp + 0x464]
and eax, dword [esp + 0x44c]
add esi, eax
mov dword [esp + 0x468], eax
mov eax, esi
cdq
xor esi, edx
sar ebp, cl
sub esi, edx
add ebx, esi
and ebp, dword [esp + 0x444]
mov esi, dword [esp + 0x468]
mov eax, dword [esp + 0x454]
neg eax
add eax, ebp
mov dword [esp + 0x454], ebp
mov ebp, 0xff
cdq
xor eax, edx
sub eax, edx
add ebx, eax
cmp ebx, 0xff
jle 0x43f3bd
mov ebx, ebp
inc dword [esp + ebx*4]
mov edx, dword [esp + 0x460]
inc edx
mov dword [esp + 0x460], edx
cmp edx, 7
jle 0x43f2f7
mov ebx, dword [esp + 0x428]
inc ebx
mov eax, dword [esp + 0x424]
cmp ebx, eax
jl 0x43f1fc
mov eax, dword [esp + 0x404]
mov edx, dword [esp + 0x400]
mov ebp, dword [esp + 0x484]
mov esi, dword [esp + 0x480]
cmp esi, ebp
jle 0x43f415
add eax, ebp
xor edx, edx
jmp 0x43f419
add edx, esi
xor eax, eax
cmp edx, ebp
jl 0x43f1b5
mov ecx, dword [esp + 0x440]
mov ebp, dword [esp]
mov esi, dword [esp + 4]
add esi, ebp
lea edi, [esi + esi]
add edi, edi
sub edi, esi
lea eax, [esi + edi*8]
add eax, eax
add eax, eax
cdq
idiv ecx
cmp eax, 0x5a
jl 0x43f456
xor eax, eax
add esp, 0x46c
pop ebx
pop ebp
pop esi
pop edi
ret 8
xor eax, eax
mov esi, 1
mov edx, dword [esp + esi*4]
mov edi, esi
imul edi, edx
imul edi, esi
add eax, edi
test edx, edx
je 0x43f4ad
mov edi, dword [esp + esi*4 - 4]
add edi, edi
cmp edx, edi
jg 0x43f4ad
inc esi
cmp esi, 8
jl 0x43f45d
cmp esi, 0x100
jge 0x43f49a
mov edx, dword [esp + esi*4]
imul edx, esi
imul edx, esi
add eax, edx
inc esi
cmp esi, 0x100
jl 0x43f486
sub ecx, ebp
xor edx, edx
div ecx
add esp, 0x46c
pop ebx
pop ebp
pop esi
pop edi
ret 8
xor eax, eax
add esp, 0x46c
pop ebx
pop ebp
pop esi
pop edi
ret 8
mov eax, dword [esp + 0x404]
mov edx, dword [esp + 0x400]
mov ebp, dword [esp + 0x484]
mov esi, dword [esp + 0x480]
jmp 0x43f40b
mov ecx, dword [esp + 0x440]
jmp 0x43f428
xor ecx, ecx
jmp 0x43f428
push edi
push esi
push ebp
push ebx
sub esp, 0x468
mov ebx, ecx
mov ebp, dword [esp + 0x480]
movzx edx, byte [ebx + 0x12]
test edx, edx
mov eax, 0
sete al
movzx edx, byte [ebx + 0x22]
test edx, edx
mov edx, 0
sete dl
cmp eax, edx
mov eax, 0
setne al
mov dword [esp + 0x438], eax
movzx eax, word [ebx + 0x24]
mov dword [esp + 0x414], eax
movzx eax, word [ebx + 0x26]
mov dword [esp + 0x418], eax
movzx eax, word [ebx + 0x28]
mov dword [esp + 0x41c], eax
movzx eax, byte [ebx + 0x2a]
mov dword [esp + 0x408], eax
movzx eax, byte [ebx + 0x2b]
mov dword [esp + 0x40c], eax
movzx eax, byte [ebx + 0x2c]
mov dword [esp + 0x410], eax
lea eax, [esp]
push 0x400
push 0
push eax
call fcn.004910c4
add esp, 0xc
test ebp, ebp
jle 0x43f8d6
xor ecx, ecx
xor edi, edi
xor esi, esi
mov eax, dword [ebx + 0x197c]
mov dword [esp + 0x43c], ecx
mov dword [esp + 0x420], eax
mov eax, dword [esp + 0x47c]
cmp esi, eax
jge 0x43f8ca
mov edx, ebp
sub edx, edi
mov dword [esp + 0x424], edx
test edx, edx
jle 0x43f7f6
xor edx, edx
mov ecx, eax
sub ecx, esi
add ecx, 0xfffffff9
mov ebx, eax
imul ebx, edi
add ebx, esi
mov dword [esp + 0x42c], ebx
mov dword [esp + 0x434], ecx
mov dword [esp + 0x404], esi
mov dword [esp + 0x400], edi
mov eax, dword [esp + 0x434]
cmp edx, eax
jge 0x43f8a9
mov eax, dword [esp + 0x47c]
imul eax, edx
lea ebp, [edx + eax]
add ebp, dword [esp + 0x42c]
mov ebx, dword [esp + 0x420]
movzx ebx, word [ebx + ebp*2]
mov ecx, dword [esp + 0x438]
test ecx, ecx
je 0x43f63b
mov ecx, ebx
shl ecx, 8
sar ebx, 8
or ecx, ebx
movzx ebx, cx
mov edi, dword [esp + 0x414]
mov ecx, dword [esp + 0x408]
mov dword [esp + 0x458], ecx
mov esi, ebx
sar esi, cl
and esi, edi
mov dword [esp + 0x430], esi
mov esi, dword [esp + 0x418]
mov ecx, dword [esp + 0x40c]
mov dword [esp + 0x454], ecx
mov ebp, ebx
sar ebp, cl
and ebp, esi
mov dword [esp + 0x450], ebp
mov ebp, dword [esp + 0x41c]
mov ecx, dword [esp + 0x410]
mov dword [esp + 0x460], ecx
sar ebx, cl
and ebx, ebp
mov ecx, 1
mov dword [esp + 0x45c], ecx
add eax, dword [esp + 0x42c]
add eax, edx
mov ecx, dword [esp + 0x420]
lea ecx, [ecx + eax*2 + 2]
mov dword [esp + 0x44c], ecx
mov dword [esp + 0x440], ebp
mov dword [esp + 0x448], esi
mov dword [esp + 0x444], edi
mov dword [esp + 0x428], edx
mov edi, dword [esp + 0x430]
mov ebp, dword [esp + 0x44c]
movzx esi, word [ebp]
mov edx, dword [esp + 0x438]
test edx, edx
je 0x43f705
mov edx, esi
shl edx, 8
sar esi, 8
or edx, esi
movzx esi, dx
mov ecx, dword [esp + 0x458]
mov ebp, esi
sar ebp, cl
and ebp, dword [esp + 0x444]
mov dword [esp + 0x464], ebp
neg edi
add edi, ebp
mov eax, edi
cdq
mov ebp, edx
xor edi, ebp
neg ebp
add ebp, edi
mov edi, dword [esp + 0x464]
mov ecx, dword [esp + 0x454]
mov edx, esi
sar edx, cl
and edx, dword [esp + 0x448]
mov dword [esp + 0x464], edx
mov eax, dword [esp + 0x450]
neg eax
add eax, edx
cdq
xor eax, edx
sub eax, edx
add ebp, eax
mov ecx, dword [esp + 0x464]
mov dword [esp + 0x450], ecx
mov ecx, dword [esp + 0x460]
sar esi, cl
and esi, dword [esp + 0x440]
neg ebx
add ebx, esi
mov eax, ebx
cdq
xor ebx, edx
sub ebx, edx
add ebp, ebx
mov ebx, esi
cmp ebp, 0xff
jle 0x43f799
mov ebp, 0xff
inc dword [esp + ebp*4]
inc dword [esp + 0x43c]
add dword [esp + 0x44c], 2
mov edx, dword [esp + 0x45c]
inc edx
mov dword [esp + 0x45c], edx
cmp edx, 7
jle 0x43f6e2
mov edx, dword [esp + 0x428]
inc edx
mov eax, dword [esp + 0x424]
cmp edx, eax
jl 0x43f5f5
mov esi, dword [esp + 0x404]
mov edi, dword [esp + 0x400]
mov ebp, dword [esp + 0x480]
mov eax, dword [esp + 0x47c]
cmp eax, ebp
jle 0x43f800
add esi, ebp
xor edi, edi
jmp 0x43f804
add edi, eax
xor esi, esi
cmp edi, ebp
jl 0x43f5ae
mov ecx, dword [esp + 0x43c]
mov ebx, dword [esp]
mov ebp, dword [esp + 4]
add ebp, ebx
lea esi, [ebp + ebp]
add esi, esi
sub esi, ebp
lea eax, [ebp + esi*8]
add eax, eax
add eax, eax
cdq
idiv ecx
cmp eax, 0x5a
jl 0x43f843
xor eax, eax
add esp, 0x468
pop ebx
pop ebp
pop esi
pop edi
ret 8
xor eax, eax
mov edx, 1
mov esi, dword [esp + edx*4]
mov ebp, edx
imul ebp, esi
imul ebp, edx
add eax, ebp
test esi, esi
je 0x43f89a
mov ebp, dword [esp + edx*4 - 4]
add ebp, ebp
cmp esi, ebp
jg 0x43f89a
inc edx
cmp edx, 8
jl 0x43f84a
cmp edx, 0x100
jge 0x43f887
mov ebp, dword [esp + edx*4]
imul ebp, edx
imul ebp, edx
add eax, ebp
inc edx
cmp edx, 0x100
jl 0x43f873
sub ecx, ebx
xor edx, edx
div ecx
add esp, 0x468
pop ebx
pop ebp
pop esi
pop edi
ret 8
xor eax, eax
add esp, 0x468
pop ebx
pop ebp
pop esi
pop edi
ret 8
mov esi, dword [esp + 0x404]
mov edi, dword [esp + 0x400]
mov ebp, dword [esp + 0x480]
mov eax, dword [esp + 0x47c]
jmp 0x43f7f6
mov ecx, dword [esp + 0x43c]
jmp 0x43f813
xor ecx, ecx
jmp 0x43f813