Function at 0x4c90d0
Capabilities:
Encrypt data using rc4 ksa
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0xbac
mov dword [ebp - 0xb4c], eax
mov dword [ebp - 0xb50], edx
cmp dword [ebp + 0x10], 3
jg 0x4c9607
xor edx, edx
mov dword [ebp + edx*4 - 0x428], 0
inc edx
cmp edx, 0x100
jle 0x4c90f4
xor edx, edx
jmp 0x4c9127
mov ecx, dword [ebp - 0xb50]
xor eax, eax
mov al, byte [ecx + edx]
inc edx
mov ecx, dword [ebp + eax*4 - 0x428]
inc ecx
mov dword [ebp + eax*4 - 0x428], ecx
cmp edx, dword [ebp + 0xc]
jl 0x4c910c
xor edx, edx
mov eax, dword [ebp + edx*4 - 0x428]
mov dword [ebp + edx*4 - 0x828], eax
inc edx
cmp edx, 0xff
jle 0x4c912e
mov edx, 1
mov edi, dword [ebp + edx*4 - 0x428]
mov eax, dword [ebp + edx*4 - 0x42c]
add edi, eax
mov dword [ebp + edx*4 - 0x428], edi
inc edx
cmp edx, 0x100
jle 0x4c914a
xor edx, edx
jmp 0x4c9198
mov edi, dword [ebp - 0xb50]
mov eax, dword [ebp - 0xb4c]
mov bl, byte [edi + edx]
and ebx, 0xff
mov esi, ebx
mov ebx, dword [ebp + ebx*4 - 0x428]
dec ebx
mov dword [ebp + esi*4 - 0x428], ebx
mov dword [eax + ebx*4], edx
inc edx
cmp edx, dword [ebp + 0xc]
jl 0x4c916e
mov eax, dword [ebp + 0xc]
test eax, eax
jns 0x4c91a7
add eax, 0x1f
sar eax, 5
xor edx, edx
add eax, 2
jmp 0x4c91bc
mov ecx, dword [ebp + 8]
mov dword [ecx + edx*4], 0
inc edx
cmp edx, eax
jl 0x4c91b1
xor edx, edx
mov ebx, 1
mov ecx, dword [ebp + edx*4 - 0x428]
mov edi, dword [ebp + 8]
mov eax, ecx
mov esi, ebx
sar eax, 5
and ecx, 0x1f
shl esi, cl
mov ecx, esi
mov esi, dword [edi + eax*4]
or esi, ecx
inc edx
mov dword [edi + eax*4], esi
cmp edx, 0xff
jle 0x4c91c7
mov esi, 1
mov ebx, dword [ebp + 0xc]
mov edx, 0x1f
mov ecx, ebx
mov edi, esi
and ecx, 0x1f
mov eax, ebx
shl edi, cl
sar eax, 5
mov ecx, edi
mov edi, dword [ebp + 8]
or dword [edi + eax*4], ecx
lea ecx, [ebx + 1]
mov eax, ecx
mov edi, esi
and ecx, 0x1f
add ebx, 2
shl edi, cl
sar eax, 5
mov ecx, edi
mov edi, dword [ebp + 8]
xor ecx, 0xffffffff
and dword [edi + eax*4], ecx
dec edx
jns 0x4c91fd
mov dword [ebp - 0xb54], 1
cmp dword [ebp + 0x10], 3
jg 0x4c9a83
xor esi, esi
xor edx, edx
cmp esi, dword [ebp + 0xc]
jge 0x4c92a7
mov edi, 1
jmp 0x4c9266
mov eax, dword [ebp - 0xb50]
inc edx
mov dword [eax + ebx*4], esi
cmp edx, dword [ebp + 0xc]
jge 0x4c92a7
mov ecx, edx
mov ebx, edi
and ecx, 0x1f
mov eax, edx
shl ebx, cl
sar eax, 5
mov ecx, ebx
mov ebx, dword [ebp + 8]
test dword [ebx + eax*4], ecx
je 0x4c9280
mov esi, edx
mov ecx, dword [ebp - 0xb4c]
mov eax, dword [ecx + edx*4]
mov ebx, eax
sub ebx, dword [ebp - 0xb54]
jns 0x4c9257
mov eax, dword [ebp + 0xc]
inc edx
add ebx, eax
mov eax, dword [ebp - 0xb50]
mov dword [eax + ebx*4], esi
cmp edx, dword [ebp + 0xc]
jl 0x4c9266
mov dword [ebp - 0xb60], 0
mov dword [ebp - 0xb5c], 0xffffffff
mov ebx, dword [ebp - 0xb5c]
mov eax, 1
inc ebx
mov esi, dword [ebp + 8]
mov edx, ebx
mov ecx, ebx
sar edx, 5
and ecx, 0x1f
shl eax, cl
test dword [esi + edx*4], eax
je 0x4c92ff
test ecx, ecx
je 0x4c92ff
mov esi, 1
inc ebx
mov eax, esi
mov edx, ebx
mov ecx, ebx
and ecx, 0x1f
mov edi, dword [ebp + 8]
sar edx, 5
shl eax, cl
test dword [edi + edx*4], eax
je 0x4c92ff
test ecx, ecx
jne 0x4c92e4
mov eax, ebx
mov ecx, ebx
sar eax, 5
mov esi, dword [ebp + 8]
and ecx, 0x1f
mov edx, 1
shl edx, cl
mov eax, dword [esi + eax*4]
test edx, eax
je 0x4c9365
cmp eax, 0xffffffff
jne 0x4c9330
add ebx, 0x20
mov edi, dword [ebp + 8]
mov eax, ebx
sar eax, 5
cmp dword [edi + eax*4], 0xffffffff
je 0x4c931f
mov eax, ebx
mov ecx, ebx
and ecx, 0x1f
mov edx, 1
sar eax, 5
mov esi, dword [ebp + 8]
shl edx, cl
test dword [esi + eax*4], edx
je 0x4c9365
mov edx, 1
inc ebx
mov edi, edx
mov eax, ebx
mov ecx, ebx
and ecx, 0x1f
mov esi, dword [ebp + 8]
sar eax, 5
shl edi, cl
test dword [esi + eax*4], edi
jne 0x4c934e
lea edi, [ebx - 1]
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0xb58], edi
cmp edi, eax
jge 0x4c99a8
mov edx, ebx
mov ecx, ebx
and ecx, 0x1f
mov eax, 1
sar edx, 5
mov esi, dword [ebp + 8]
shl eax, cl
test dword [esi + edx*4], eax
jne 0x4c93b6
test ecx, ecx
je 0x4c93b6
mov esi, 1
inc ebx
mov eax, esi
mov edx, ebx
mov ecx, ebx
and ecx, 0x1f
mov edi, dword [ebp + 8]
sar edx, 5
shl eax, cl
test dword [edi + edx*4], eax
jne 0x4c93b6
test ecx, ecx
jne 0x4c939b
mov eax, ebx
mov ecx, ebx
sar eax, 5
mov esi, dword [ebp + 8]
and ecx, 0x1f
mov edx, 1
shl edx, cl
mov eax, dword [esi + eax*4]
test edx, eax
jne 0x4c941c
test eax, eax
jmp 0x4c93e5
add ebx, 0x20
mov edi, dword [ebp + 8]
mov eax, ebx
sar eax, 5
mov ecx, dword [edi + eax*4]
test ecx, ecx
je 0x4c93d5
mov eax, ebx
mov ecx, ebx
and ecx, 0x1f
mov edx, 1
sar eax, 5
mov esi, dword [ebp + 8]
shl edx, cl
test dword [esi + eax*4], edx
jne 0x4c941c
mov edx, 1
inc ebx
mov edi, edx
mov eax, ebx
mov ecx, ebx
and ecx, 0x1f
mov esi, dword [ebp + 8]
sar eax, 5
shl edi, cl
test dword [esi + eax*4], edi
je 0x4c9405
dec ebx
mov edi, dword [ebp + 0xc]
mov dword [ebp - 0xb5c], ebx
cmp ebx, edi
jge 0x4c99a8
mov eax, dword [ebp - 0xb58]
cmp ebx, eax
jle 0x4c92bb
mov edx, dword [ebp - 0xb58]
mov eax, ebx
sub eax, edx
mov edx, dword [ebp - 0xb60]
mov ecx, dword [ebp - 0xb58]
mov dword [ebp - 0xb80], 0
lea edx, [eax + edx + 1]
mov dword [ebp - 0x9b8], ecx
mov dword [ebp - 0xb60], edx
mov dword [ebp - 0xb48], ebx
mov dword [ebp - 0xb74], 1
lea esi, [esi]
cmp dword [ebp - 0xb74], 0x62
jg 0x4c98f9
mov eax, dword [ebp - 0xb74]
dec eax
mov dword [ebp - 0xb74], eax
mov esi, dword [ebp - 0xb74]
mov ebx, dword [ebp - 0xb74]
mov esi, dword [ebp + esi*4 - 0xb48]
mov ebx, dword [ebp + ebx*4 - 0x9b8]
mov eax, esi
mov dword [ebp - 0xb78], ebx
sub eax, ebx
mov dword [ebp - 0xb7c], esi
cmp eax, 9
jg 0x4c9626
cmp ebx, esi
je 0x4c95a3
cmp eax, 3
jle 0x4c9536
mov ecx, esi
sub ecx, 4
cmp ecx, ebx
jl 0x4c9536
mov edi, dword [ebp - 0xb4c]
mov eax, dword [ebp - 0xb50]
mov esi, dword [edi + ecx*4]
mov ebx, dword [eax + esi*4]
lea eax, [ecx + 4]
cmp eax, dword [ebp - 0xb7c]
jg 0x4c9523
mov edx, dword [edi + eax*4]
mov edi, dword [ebp - 0xb50]
cmp dword [edi + edx*4], ebx
jae 0x4c9523
mov edi, dword [ebp - 0xb4c]
mov dword [edi + eax*4 - 0x10], edx
add eax, 4
cmp eax, dword [ebp - 0xb7c]
jle 0x4c9500
mov edx, dword [ebp - 0xb4c]
dec ecx
cmp ecx, dword [ebp - 0xb78]
mov dword [edx + eax*4 - 0x10], esi
jge 0x4c94e3
mov ecx, dword [ebp - 0xb7c]
dec ecx
cmp ecx, dword [ebp - 0xb78]
jl 0x4c95a3
mov ebx, dword [ebp - 0xb4c]
mov edi, dword [ebp - 0xb50]
lea eax, [ecx + 1]
mov esi, dword [ebx + ecx*4]
cmp eax, dword [ebp - 0xb7c]
mov ebx, dword [edi + esi*4]
jg 0x4c9590
mov edi, dword [ebp - 0xb4c]
mov edx, dword [edi + eax*4]
mov edi, dword [ebp - 0xb50]
cmp dword [edi + edx*4], ebx
jae 0x4c9590
mov edi, dword [ebp - 0xb4c]
mov dword [edi + eax*4 - 4], edx
inc eax
cmp eax, dword [ebp - 0xb7c]
jle 0x4c9568
lea esi, [esi]
mov edx, dword [ebp - 0xb4c]
mov dword [edx + eax*4 - 4], esi
dec ecx
cmp ecx, dword [ebp - 0xb78]
jge 0x4c9545
mov eax, dword [ebp - 0xb74]
test eax, eax
jg 0x4c9480
mov edx, dword [ebp - 0xb58]
or ecx, 0xffffffff
cmp edx, dword [ebp - 0xb5c]
jg 0x4c92bb
mov esi, 1
mov edi, dword [ebp - 0xb4c]
mov eax, dword [edi + edx*4]
mov edi, dword [ebp - 0xb50]
mov ebx, dword [edi + eax*4]
cmp ecx, ebx
je 0x4c95f9
mov ecx, edx
mov edi, esi
and ecx, 0x1f
mov eax, edx
shl edi, cl
sar eax, 5
mov ecx, edi
mov edi, dword [ebp + 8]
or dword [edi + eax*4], ecx
mov ecx, ebx
inc edx
cmp edx, dword [ebp - 0xb5c]
jle 0x4c95cb
jmp 0x4c92bb
mov eax, dword [sym.imp.msvcrt.dll__iob]
add eax, 0x40
push eax
push 0x1b
push 1
push str.________bucket_sorting_..._n
call sub.msvcrt.dll_fwrite
add esp, 0x10
jmp 0x4c90f2
mov edx, dword [ebp - 0xb80]
mov eax, dword [ebp - 0xb80]
shl edx, 4
mov ecx, dword [ebp - 0xb80]
sub edx, eax
mov eax, edx
shl eax, 7
sub eax, edx
mov edx, 3
mov ebx, edx
xor edx, edx
lea eax, [ecx + eax*4 + 1]
and eax, 0x7fff
mov dword [ebp - 0xb80], eax
div ebx
test edx, edx
jne 0x4c990e
mov esi, dword [ebp - 0xb78]
mov edi, dword [ebp - 0xb4c]
mov edx, dword [ebp - 0xb50]
mov eax, dword [edi + esi*4]
mov ebx, dword [edx + eax*4]
mov esi, dword [ebp - 0xb78]
mov edi, dword [ebp - 0xb7c]
mov dword [ebp - 0xb68], esi
mov dword [ebp - 0xb64], esi
mov dword [ebp - 0xb6c], edi
mov ecx, edi
cmp dword [ebp - 0xb64], ecx
jg 0x4c96fa
mov eax, dword [ebp - 0xb64]
mov esi, dword [ebp - 0xb4c]
mov edi, dword [ebp - 0xb50]
mov edx, dword [esi + eax*4]
mov eax, dword [edi + edx*4]
sub eax, ebx
cmp eax, 0
jne 0x4c9874
mov edi, dword [ebp - 0xb68]
mov eax, dword [esi + edi*4]
mov edi, dword [ebp - 0xb64]
mov dword [esi + edi*4], eax
mov eax, dword [ebp - 0xb68]
inc edi
mov dword [esi + eax*4], edx
mov dword [ebp - 0xb64], edi
inc eax
cmp dword [ebp - 0xb64], ecx
mov dword [ebp - 0xb68], eax
jle 0x4c96a6
mov eax, dword [ebp - 0xb68]
cmp dword [ebp - 0xb6c], eax
jl 0x4c95a3
mov edx, dword [ebp - 0xb64]
mov ebx, dword [ebp - 0xb78]
sub edx, eax
sub eax, ebx
mov dword [ebp - 0xb70], edx
cmp edx, eax
jle 0x4c972c
mov dword [ebp - 0xb70], eax
mov edi, dword [ebp - 0xb70]
mov ebx, dword [ebp - 0xb64]
sub ebx, edi
mov esi, dword [ebp - 0xb78]
mov edi, dword [ebp - 0xb70]
jmp 0x4c9775
mov eax, dword [ebp - 0xb4c]
mov edx, dword [ebp - 0xb4c]
dec edi
mov eax, dword [eax + esi*4]
mov edx, dword [edx + ebx*4]
mov dword [ebp - 0xbac], eax
mov eax, dword [ebp - 0xb4c]
mov dword [eax + esi*4], edx
mov edx, dword [ebp - 0xbac]
mov dword [eax + ebx*4], edx
inc esi
inc ebx
test edi, edi
jg 0x4c9748
mov edi, dword [ebp - 0xb6c]
mov eax, dword [ebp - 0xb7c]
mov ebx, dword [ebp - 0xb6c]
sub edi, ecx
sub eax, ebx
cmp edi, eax
jle 0x4c9795
mov edi, eax
mov eax, dword [ebp - 0xb7c]
mov esi, dword [ebp - 0xb64]
sub eax, edi
lea ebx, [eax + 1]
jmp 0x4c97d5
mov eax, dword [ebp - 0xb4c]
mov edx, dword [ebp - 0xb4c]
dec edi
mov eax, dword [eax + esi*4]
mov edx, dword [edx + ebx*4]
mov dword [ebp - 0xbac], eax
mov eax, dword [ebp - 0xb4c]
mov dword [eax + esi*4], edx
mov edx, dword [ebp - 0xbac]
mov dword [eax + ebx*4], edx
inc esi
inc ebx
test edi, edi
jg 0x4c97a8
mov edx, dword [ebp - 0xb64]
mov eax, dword [ebp - 0xb78]
add eax, edx
mov edi, dword [ebp - 0xb68]
mov esi, dword [ebp - 0xb6c]
sub eax, edi
sub esi, ecx
dec eax
mov dword [ebp - 0xb6c], esi
mov dword [ebp - 0xb70], eax
mov ebx, dword [ebp - 0xb6c]
mov eax, dword [ebp - 0xb7c]
sub eax, ebx
mov edx, dword [ebp - 0xb70]
mov ecx, dword [ebp - 0xb78]
lea edi, [eax + 1]
mov eax, dword [ebp - 0xb7c]
sub edx, ecx
sub eax, edi
cmp edx, eax
jle 0x4c9940
mov ecx, dword [ebp - 0xb74]
mov ebx, dword [ebp - 0xb78]
mov esi, dword [ebp - 0xb70]
mov dword [ebp + ecx*4 - 0x9b8], ebx
mov dword [ebp + ecx*4 - 0xb48], esi
inc ecx
mov dword [ebp + ecx*4 - 0x9b8], edi
mov edi, dword [ebp - 0xb7c]
mov dword [ebp + ecx*4 - 0xb48], edi
inc ecx
mov dword [ebp - 0xb74], ecx
jmp 0x4c95a3
jle 0x4c992e
lea esi, [esi]
cmp dword [ebp - 0xb64], ecx
jg 0x4c96fa
mov esi, dword [ebp - 0xb4c]
mov edi, dword [ebp - 0xb50]
mov edx, dword [esi + ecx*4]
mov eax, dword [edi + edx*4]
sub eax, ebx
cmp eax, 0
jne 0x4c98c0
mov edi, dword [ebp - 0xb6c]
mov eax, dword [esi + edi*4]
mov dword [esi + ecx*4], eax
mov dword [esi + edi*4], edx
dec edi
mov dword [ebp - 0xb6c], edi
dec ecx
jmp 0x4c9880
jge 0x4c98bb
cmp dword [ebp - 0xb64], ecx
jg 0x4c96fa
mov esi, dword [ebp - 0xb4c]
mov eax, dword [ebp - 0xb64]
mov edi, dword [ebp - 0xb64]
mov edx, dword [esi + eax*4]
mov eax, dword [esi + ecx*4]
mov dword [esi + edi*4], eax
mov dword [esi + ecx*4], edx
inc edi
dec ecx
mov dword [ebp - 0xb64], edi
jmp 0x4c969e
sub esp, 0xc
push 0x3ec
call fcn.004be4f0
add esp, 0x10
jmp 0x4c948d
dec edx
je 0x4c9981
mov edi, dword [ebp - 0xb7c]
mov edx, dword [ebp - 0xb4c]
mov ecx, dword [ebp - 0xb50]
mov eax, dword [edx + edi*4]
mov ebx, dword [ecx + eax*4]
jmp 0x4c967e
mov esi, dword [ebp - 0xb64]
inc esi
mov dword [ebp - 0xb64], esi
jmp 0x4c969e
mov eax, dword [ebp - 0xb74]
mov edx, dword [ebp - 0xb7c]
mov ecx, dword [ebp - 0xb78]
mov ebx, dword [ebp - 0xb70]
mov dword [ebp + eax*4 - 0x9b8], edi
mov dword [ebp + eax*4 - 0xb48], edx
inc eax
mov dword [ebp + eax*4 - 0x9b8], ecx
mov dword [ebp + eax*4 - 0xb48], ebx
inc eax
mov dword [ebp - 0xb74], eax
jmp 0x4c95a3
mov eax, dword [ebp - 0xb78]
mov edi, dword [ebp - 0xb7c]
add eax, edi
mov ecx, dword [ebp - 0xb4c]
sar eax, 1
mov esi, dword [ebp - 0xb50]
mov eax, dword [ecx + eax*4]
mov ebx, dword [esi + eax*4]
jmp 0x4c967e
cmp dword [ebp + 0x10], 3
jg 0x4c9a60
mov eax, dword [ebp - 0xb54]
mov edx, dword [ebp + 0xc]
add eax, eax
cmp eax, edx
mov dword [ebp - 0xb54], eax
mov eax, dword [ebp - 0xb60]
setg dl
test eax, eax
sete al
or eax, edx
test al, 1
je 0x4c923d
cmp dword [ebp + 0x10], 3
jle 0x4c99fd
mov eax, dword [sym.imp.msvcrt.dll__iob]
add eax, 0x40
push eax
push 0x21
push 1
push str.________reconstructing_block_..._n
call sub.msvcrt.dll_fwrite
add esp, 0x10
xor esi, esi
xor edx, edx
cmp esi, dword [ebp + 0xc]
jge 0x4c9a58
mov ecx, dword [ebp - 0x828]
jmp 0x4c9a16
inc esi
mov ecx, dword [ebp + esi*4 - 0x828]
test ecx, ecx
je 0x4c9a0e
lea eax, [ecx - 1]
mov ebx, dword [ebp - 0xb4c]
mov dword [ebp + esi*4 - 0x828], eax
mov ecx, eax
mov edi, dword [ebp - 0xb50]
mov eax, dword [ebx + edx*4]
mov ebx, esi
inc edx
mov byte [eax + edi], bl
cmp edx, dword [ebp + 0xc]
jl 0x4c9a16
cmp esi, 0xff
jle 0x4c9a58
sub esp, 0xc
push 0x3ed
call fcn.004be4f0
add esp, 0x10
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
mov eax, dword [sym.imp.msvcrt.dll__iob]
mov edx, dword [ebp - 0xb60]
add eax, 0x40
push ecx
push edx
push str._6d_unresolved_strings_n
push eax
call sub.msvcrt.dll_fprintf
add esp, 0x10
jmp 0x4c99b2
push eax
mov eax, dword [ebp - 0xb54]
push eax
mov eax, dword [sym.imp.msvcrt.dll__iob]
add eax, 0x40
push str.________depth__6d_has
push eax
call sub.msvcrt.dll_fprintf
add esp, 0x10
jmp 0x4c9247