Function at 0x412f70
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x480c43
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x250
push ebx
mov ebx, ecx
push esi
push edi
lea ecx, [ebp - 0x48]
call fcn.0047d337
xor edi, edi
push 0x1940
mov dword [ebp - 4], edi
call fcn.004785c2
add esp, 4
mov dword [ebp - 0x1c], eax
cmp eax, edi
mov byte [ebp - 4], 1
je 0x412fc6
mov ecx, eax
call fcn.0040a830
mov esi, eax
mov dword [ebp - 0x30], esi
jmp 0x412fcb
mov dword [ebp - 0x30], edi
mov esi, edi
mov eax, dword [ebx + 0x70]
mov ecx, dword [ebx + 0x6c]
push edi
push eax
push ecx
mov ecx, esi
mov byte [ebp - 4], 0
call fcn.0040aa80
test al, al
jne 0x413004
push edi
push edi
push 0x48f59c
call fcn.0047e19f
cmp esi, edi
je 0x413751
mov edx, dword [esi]
push 1
mov ecx, esi
call dword [edx]
jmp 0x413751
mov eax, dword [esi + 0x10]
mov dword [ebp - 0x38], eax
mov eax, dword [ebx + 0x70]
imul eax, dword [ebx + 0x6c]
mov dword [ebp - 0x24], eax
lea edi, [eax + eax*2]
push edi
push 0
call dword [0x4832e0]
push edi
push 0
mov dword [ebp - 0x2c], eax
call dword [0x4832e0]
mov ecx, dword [ebp - 0x2c]
mov edi, eax
xor eax, eax
mov dword [ebp - 0x34], edi
cmp ecx, eax
je 0x413722
cmp edi, eax
je 0x413722
mov ecx, dword [ebx + 0x40]
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x1c], eax
lea edi, [ebx + 0x4c]
mov edx, dword [ebx + ecx*4 + 0x80]
push eax
push edi
lea eax, [ebp - 0x20]
push edx
push eax
mov ecx, esi
call fcn.0040af00
mov ecx, dword [ebx + 0x284]
test ecx, ecx
je 0x41307c
lea edx, [ebp - 0x20]
push edi
push edx
push esi
call fcn.00420660
cld
mov esi, dword [ebp - 0x38]
mov edi, dword [ebp - 0x2c]
mov ecx, dword [ebp - 0x24]
movsb byte es:[edi], byte [esi]
movsb byte es:[edi], byte [esi]
movsb byte es:[edi], byte [esi]
inc esi
loop 0x413086
mov edx, dword [ebx + 0x6c]
mov eax, dword [ebx + 0x5c]
mov esi, dword [ebx + 0x70]
mov ecx, dword [ebx + 0x60]
mov dword [ebp - 0x5c], eax
add edx, eax
xor edi, edi
lea eax, [ebp - 0x5c]
mov dword [ebp - 0x58], ecx
add esi, ecx
push edi
push eax
mov ecx, ebx
mov dword [ebp - 0x54], edx
mov dword [ebp - 0x50], esi
mov dword [ebp - 0x20], edi
mov dword [ebp - 0x1c], edi
call fcn.00415d70
mov esi, dword [ebp - 0x30]
lea ecx, [ebp - 0x20]
push eax
push ecx
mov ecx, esi
call fcn.0040af00
mov ecx, dword [ebx + 0x284]
cmp ecx, edi
je 0x4130e3
lea eax, [ebx + 0x4c]
lea edx, [ebp - 0x20]
push eax
push edx
push esi
call fcn.00420660
cld
mov esi, dword [ebp - 0x38]
mov edi, dword [ebp - 0x34]
mov ecx, dword [ebp - 0x24]
movsb byte es:[edi], byte [esi]
movsb byte es:[edi], byte [esi]
movsb byte es:[edi], byte [esi]
inc esi
loop 0x4130ed
push 0
call dword [0x483064]
push eax
lea ecx, [ebp - 0x48]
call fcn.0047d3ee
mov esi, dword [ebp - 0x30]
mov edx, dword [ebp - 0x44]
lea eax, [ebp - 0x48]
mov ecx, dword [esi + 8]
neg eax
sbb eax, eax
push ecx
and eax, edx
push eax
call dword [0x483060]
mov edi, dword [0x48359c]
mov dword [ebp - 0x1c], eax
call edi
mov ecx, dword [ebx + 0x38]
mov edx, dword [ebx + 0x6c]
mov dword [ebp - 0x4c], eax
mov eax, dword [ebx + 0x5c]
sub eax, ecx
mov ecx, dword [ebx + 0x60]
mov dword [ebx + 0x344], esi
mov esi, dword [ebx + 0x3c]
mov dword [ebx + 0x334], eax
add eax, edx
sub ecx, esi
mov dword [ebx + 0x33c], eax
mov eax, dword [ebx + 0x70]
mov dword [ebx + 0x338], ecx
add ecx, eax
mov byte [ebp - 0x15], 0
mov dword [ebp - 0x24], 0
mov dword [ebx + 0x340], ecx
jmp 0x413177
mov edi, dword [0x48359c]
call edi
sub eax, 0x21
mov dword [ebp - 0x10], eax
call edi
mov edx, dword [ebp - 0x4c]
mov esi, eax
mov eax, dword [ebp + 0xc]
mov ecx, esi
sub ecx, edx
cmp ecx, eax
ja 0x4131cf
mov eax, ecx
xor edx, edx
shl eax, 8
sub eax, ecx
mov byte [ebp - 0x28], 0xff
div dword [ebp + 0xc]
cmp eax, 0xff
ja 0x4131ab
mov byte [ebp - 0x28], al
mov al, byte [ebp - 0x28]
mov cl, byte [ebp - 0x15]
cmp cl, al
je 0x4131bd
sub esi, dword [ebp - 0x10]
cmp esi, 0x21
jae 0x4131d3
call edi
mov edx, dword [ebp - 0x4c]
mov esi, eax
mov eax, dword [ebp + 0xc]
mov ecx, esi
sub ecx, edx
cmp ecx, eax
jbe 0x413191
mov byte [ebp - 0x28], 0xff
mov cl, byte [ebp - 0x28]
mov edi, dword [ebp - 0x28]
mov byte [ebp - 0x15], cl
xor ecx, ecx
xor esi, esi
and edi, 0xff
mov eax, 0x80808081
imul esi
add edx, esi
add esi, edi
sar edx, 7
mov eax, edx
shr eax, 0x1f
add edx, eax
mov al, cl
sub al, dl
mov byte [ebp + ecx - 0x25c], dl
mov byte [ebp + ecx - 0x15c], al
inc ecx
cmp ecx, 0x100
jl 0x4131e6
mov eax, dword [ebp - 0x24]
test eax, eax
je 0x413418
mov eax, dword [ebx + 0x70]
mov edi, dword [ebp - 0x2c]
mov esi, dword [ebp - 0x34]
mov ecx, dword [ebp - 0x38]
cdq
sub eax, edx
mov dword [ebp - 0x10], 0
sar eax, 1
test eax, eax
jle 0x413374
mov eax, dword [ebx + 0x6c]
mov dword [ebp - 0x14], 0
inc eax
cdq
sub eax, edx
sar eax, 1
test eax, eax
jle 0x4132c5
xor edx, edx
xor eax, eax
mov dl, byte [esi]
mov al, byte [edi]
mov dl, byte [ebp + edx - 0x15c]
add dl, byte [ebp + eax - 0x25c]
inc ecx
inc esi
xor eax, eax
mov byte [ecx - 1], dl
inc edi
mov al, byte [esi]
xor edx, edx
mov dl, byte [edi]
mov al, byte [ebp + eax - 0x15c]
add al, byte [ebp + edx - 0x25c]
inc ecx
inc esi
xor edx, edx
mov byte [ecx - 1], al
inc edi
mov dl, byte [esi]
xor eax, eax
mov al, byte [edi]
add edi, 4
mov dl, byte [ebp + edx - 0x15c]
add esi, 4
add dl, byte [ebp + eax - 0x25c]
mov eax, dword [ebp - 0x14]
mov byte [ecx], dl
add ecx, 6
inc eax
mov dword [ebp - 0x14], eax
mov eax, dword [ebx + 0x6c]
inc eax
cdq
sub eax, edx
mov edx, dword [ebp - 0x14]
sar eax, 1
cmp edx, eax
jl 0x413255
mov eax, dword [ebx + 0x6c]
add edi, 3
cdq
sub eax, edx
add esi, 3
sar eax, 1
add ecx, 4
mov dword [ebp - 0x14], 0
test eax, eax
jle 0x413351
xor eax, eax
xor edx, edx
mov al, byte [esi]
mov dl, byte [edi]
mov al, byte [ebp + eax - 0x15c]
add al, byte [ebp + edx - 0x25c]
inc ecx
inc esi
xor edx, edx
mov byte [ecx - 1], al
inc edi
mov dl, byte [esi]
xor eax, eax
mov al, byte [edi]
mov dl, byte [ebp + edx - 0x15c]
add dl, byte [ebp + eax - 0x25c]
inc ecx
inc esi
xor eax, eax
mov byte [ecx - 1], dl
inc edi
mov al, byte [esi]
xor edx, edx
mov dl, byte [edi]
add edi, 4
mov al, byte [ebp + eax - 0x15c]
add esi, 4
add al, byte [ebp + edx - 0x25c]
add ecx, 6
mov byte [ecx - 6], al
mov eax, dword [ebp - 0x14]
inc eax
mov dword [ebp - 0x14], eax
mov eax, dword [ebx + 0x6c]
cdq
sub eax, edx
mov edx, dword [ebp - 0x14]
sar eax, 1
cmp edx, eax
jl 0x4132e1
mov eax, dword [ebp - 0x10]
sub edi, 3
sub esi, 3
sub ecx, 4
inc eax
mov dword [ebp - 0x10], eax
mov eax, dword [ebx + 0x70]
cdq
sub eax, edx
mov edx, dword [ebp - 0x10]
sar eax, 1
cmp edx, eax
jl 0x413241
mov edx, dword [ebx + 0x70]
and edx, 0x80000001
jns 0x413384
dec edx
or edx, 0xfffffffe
inc edx
je 0x41360d
mov eax, dword [ebx + 0x6c]
mov dword [ebp - 0x10], 0
inc eax
cdq
sub eax, edx
sar eax, 1
test eax, eax
jle 0x41360d
xor eax, eax
xor edx, edx
mov al, byte [esi]
mov dl, byte [edi]
mov al, byte [ebp + eax - 0x15c]
add al, byte [ebp + edx - 0x25c]
inc ecx
inc esi
xor edx, edx
mov byte [ecx - 1], al
inc edi
mov dl, byte [esi]
xor eax, eax
mov al, byte [edi]
mov dl, byte [ebp + edx - 0x15c]
add dl, byte [ebp + eax - 0x25c]
inc ecx
inc esi
xor eax, eax
mov byte [ecx - 1], dl
inc edi
mov al, byte [esi]
xor edx, edx
mov dl, byte [edi]
add edi, 4
mov al, byte [ebp + eax - 0x15c]
add esi, 4
add al, byte [ebp + edx - 0x25c]
add ecx, 6
mov byte [ecx - 6], al
mov eax, dword [ebp - 0x10]
inc eax
mov dword [ebp - 0x10], eax
mov eax, dword [ebx + 0x6c]
inc eax
cdq
sub eax, edx
mov edx, dword [ebp - 0x10]
sar eax, 1
cmp edx, eax
jl 0x4133a2
jmp 0x41360d
mov ecx, dword [ebp - 0x2c]
mov eax, dword [ebp - 0x38]
mov edx, dword [ebp - 0x34]
mov dword [ebp - 0x10], 0
lea edi, [ecx + 3]
lea ecx, [eax + 4]
mov eax, dword [ebx + 0x70]
lea esi, [edx + 3]
cdq
sub eax, edx
sar eax, 1
test eax, eax
jle 0x413574
mov eax, dword [ebx + 0x6c]
mov dword [ebp - 0x14], 0
cdq
sub eax, edx
sar eax, 1
test eax, eax
jle 0x4134c3
xor edx, edx
xor eax, eax
mov dl, byte [esi]
mov al, byte [edi]
mov dl, byte [ebp + edx - 0x15c]
add dl, byte [ebp + eax - 0x25c]
inc ecx
inc esi
xor eax, eax
mov byte [ecx - 1], dl
inc edi
mov al, byte [esi]
xor edx, edx
mov dl, byte [edi]
mov al, byte [ebp + eax - 0x15c]
add al, byte [ebp + edx - 0x25c]
inc ecx
inc esi
xor edx, edx
mov byte [ecx - 1], al
inc edi
mov dl, byte [esi]
xor eax, eax
mov al, byte [edi]
add edi, 4
mov dl, byte [ebp + edx - 0x15c]
add esi, 4
add dl, byte [ebp + eax - 0x25c]
mov eax, dword [ebp - 0x14]
mov byte [ecx], dl
add ecx, 6
inc eax
mov dword [ebp - 0x14], eax
mov eax, dword [ebx + 0x6c]
cdq
sub eax, edx
mov edx, dword [ebp - 0x14]
sar eax, 1
cmp edx, eax
jl 0x413454
mov eax, dword [ebx + 0x6c]
sub edi, 3
sub esi, 3
sub ecx, 4
inc eax
mov dword [ebp - 0x14], 0
cdq
sub eax, edx
sar eax, 1
test eax, eax
jle 0x413551
xor eax, eax
xor edx, edx
mov al, byte [esi]
mov dl, byte [edi]
mov al, byte [ebp + eax - 0x15c]
add al, byte [ebp + edx - 0x25c]
inc ecx
inc esi
xor edx, edx
mov byte [ecx - 1], al
inc edi
mov dl, byte [esi]
xor eax, eax
mov al, byte [edi]
mov dl, byte [ebp + edx - 0x15c]
add dl, byte [ebp + eax - 0x25c]
inc ecx
inc esi
xor eax, eax
mov byte [ecx - 1], dl
inc edi
mov al, byte [esi]
xor edx, edx
mov dl, byte [edi]
add edi, 4
mov al, byte [ebp + eax - 0x15c]
add esi, 4
add al, byte [ebp + edx - 0x25c]
add ecx, 6
mov byte [ecx - 6], al
mov eax, dword [ebp - 0x14]
inc eax
mov dword [ebp - 0x14], eax
mov eax, dword [ebx + 0x6c]
inc eax
cdq
sub eax, edx
mov edx, dword [ebp - 0x14]
sar eax, 1
cmp edx, eax
jl 0x4134e0
mov eax, dword [ebp - 0x10]
add edi, 3
add esi, 3
add ecx, 4
inc eax
mov dword [ebp - 0x10], eax
mov eax, dword [ebx + 0x70]
cdq
sub eax, edx
mov edx, dword [ebp - 0x10]
sar eax, 1
cmp edx, eax
jl 0x413441
mov edx, dword [ebx + 0x70]
and edx, 0x80000001
jns 0x413584
dec edx
or edx, 0xfffffffe
inc edx
je 0x41360d
mov eax, dword [ebx + 0x6c]
mov dword [ebp - 0x10], 0
cdq
sub eax, edx
sar eax, 1
test eax, eax
jle 0x41360d
xor eax, eax
xor edx, edx
mov al, byte [esi]
mov dl, byte [edi]
mov al, byte [ebp + eax - 0x15c]
add al, byte [ebp + edx - 0x25c]
inc ecx
inc esi
xor edx, edx
mov byte [ecx - 1], al
inc edi
mov dl, byte [esi]
xor eax, eax
mov al, byte [edi]
mov dl, byte [ebp + edx - 0x15c]
add dl, byte [ebp + eax - 0x25c]
inc ecx
inc esi
xor eax, eax
mov byte [ecx - 1], dl
inc edi
mov al, byte [esi]
xor edx, edx
mov dl, byte [edi]
add edi, 4
mov al, byte [ebp + eax - 0x15c]
add esi, 4
add al, byte [ebp + edx - 0x25c]
add ecx, 6
mov byte [ecx - 6], al
mov eax, dword [ebp - 0x10]
inc eax
mov dword [ebp - 0x10], eax
mov eax, dword [ebx + 0x6c]
cdq
sub eax, edx
mov edx, dword [ebp - 0x10]
sar eax, 1
cmp edx, eax
jl 0x41359d
mov ecx, dword [ebx + 0x60]
mov edx, dword [ebx + 0x3c]
mov eax, dword [ebx + 0x38]
sub ecx, edx
mov edx, dword [ebx + 0x5c]
mov esi, dword [ebx + 0x70]
sub edx, eax
lea eax, [ebp - 0x48]
mov edi, dword [ebx + 0x6c]
push 0xcc0020
neg eax
sbb eax, eax
push 0
and eax, dword [ebp - 0x44]
push 0
push eax
push esi
push edi
push ecx
mov ecx, dword [ebp + 8]
push edx
mov edx, dword [ecx + 4]
push edx
call dword [0x48305c]
mov edx, dword [ebp - 0x24]
mov ecx, dword [0x4cc9f8]
xor eax, eax
test edx, edx
sete al
mov dword [ebp - 0x24], eax
call fcn.0044cd40
test al, al
jne 0x41366e
cmp byte [ebp - 0x28], 0xff
jne 0x413171
mov ecx, dword [ebx + 0x40]
mov dword [ebx + 0x344], 0
mov byte [ebx + 0x39c], 0
lea eax, [ebx + 0x4c]
mov edx, dword [ebx + ecx*4 + 0x80]
push 0
push eax
lea esi, [ebx + 0x5c]
push edx
push esi
mov ecx, ebx
call fcn.00415d70
mov ecx, eax
call fcn.0040af00
mov ecx, dword [0x4ccd64]
mov al, byte [ecx + 0x7ca]
test al, al
jne 0x4136e2
mov eax, dword [esi]
mov edi, dword [ebx + 0x38]
mov edx, dword [ebx + 0x60]
mov esi, dword [ebx + 0x3c]
sub eax, edi
mov edi, dword [ebx + 0x6c]
mov dword [ebp - 0x5c], eax
add eax, edi
mov dword [ebp - 0x54], eax
mov eax, dword [ebx + 0x70]
sub edx, esi
push 0
mov dword [ebp - 0x58], edx
add eax, edx
lea edx, [ebp - 0x5c]
mov dword [ebp - 0x50], eax
push edx
call fcn.00448090
mov esi, dword [ebp - 0x44]
mov ecx, dword [ebp - 0x1c]
lea eax, [ebp - 0x48]
push ecx
neg eax
sbb eax, eax
and eax, esi
push eax
call dword [0x483060]
mov ecx, dword [ebp - 0x30]
test ecx, ecx
je 0x413706
mov edx, dword [ecx]
push 1
call dword [edx]
mov eax, dword [ebp - 0x2c]
mov esi, dword [0x4832e8]
push eax
call esi
mov ecx, dword [ebp - 0x34]
push ecx
call esi
lea ecx, [ebp - 0x48]
call fcn.0047d456
jmp 0x413751
push eax
push eax
push 0x48f568
call fcn.0047e19f
test esi, esi
je 0x41373a
mov edx, dword [esi]
push 1
mov ecx, esi
call dword [edx]
mov eax, dword [ebp - 0x2c]
mov esi, dword [0x4832e8]
test eax, eax
je 0x41374a
push eax
call esi
test edi, edi
je 0x413751
push edi
call esi
lea ecx, [ebp - 0x48]
mov dword [ebp - 4], 0xffffffff
call fcn.0047d46c
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret 8