Function at 0x40c470
Capabilities:
Encrypt data using rc4 ksa
Read file on windows

Disassembly:
sub esp, 0x14
mov eax, ecx
lea ecx, [esp + 8]
mov dword [esp + 8], eax
test ecx, ecx
mov dword [eax], 0x42f098
jne 0x40c991
push ebx
push ebp
push esi
xor ebx, ebx
push edi
push ebx
push ebx
push ebx
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_LockFile]
xor eax, eax
movsx edx, ax
lea ecx, [esp + 0x1c]
mov byte [esp + edx + 0x1c], al
xor eax, eax
mov byte [ecx], al
inc eax
inc ecx
cmp ax, 0x100
jl 0x40c4ab
xor eax, eax
lea ecx, [esp + 0x1c]
mov byte [ecx], al
inc eax
inc ecx
cmp ax, 0x100
jl 0x40c4bb
inc eax
cmp ax, 0x100
jl 0x40c49e
xor eax, eax
lea ecx, [esp + 0x1c]
mov byte [ecx], al
inc eax
inc ecx
cmp ax, 0x100
jl 0x40c4d2
mov byte [esp + 0x10], bl
mov byte [esp + 0x20], bl
mov ebp, dword [esp + 0x10]
mov byte [esp + 0x21], bl
mov byte [esp + 0x14], bl
jmp 0x40c4f4
xor ebx, ebx
xor eax, eax
lea ecx, [esp + 0x1c]
mov byte [ecx], al
inc eax
inc ecx
cmp ax, 0x100
jl 0x40c4fa
xor eax, eax
lea ecx, [esp + 0x1c]
mov byte [ecx], al
inc eax
inc ecx
cmp ax, 0x100
jl 0x40c50a
xor ecx, ecx
lea eax, [esp + 0x1c]
mov byte [eax], cl
inc ecx
inc eax
cmp cx, 0x100
jl 0x40c51a
movsx eax, cx
mov dl, byte [esp + eax + 0x1c]
xor ebx, ebx
lea esi, [esp + eax + 0x1c]
mov eax, dword [esp + 0x14]
and eax, 0xff
mov edi, edx
and edi, 0xff
and ebp, 0xff
mov bl, byte [eax + 0x384]
add ebx, edi
add ebx, ebp
and ebx, 0x800000ff
jns 0x40c563
dec ebx
or ebx, 0xffffff00
inc ebx
mov byte [esp + 0x10], bl
mov ebp, dword [esp + 0x10]
mov edi, ebp
and edi, 0xff
inc eax
mov bl, byte [esp + edi + 0x1c]
lea edi, [esp + edi + 0x1c]
mov byte [esi], bl
mov esi, 0x57
mov byte [edi], dl
cdq
idiv esi
inc ecx
cmp cx, 0x100
mov byte [esp + 0x14], dl
jl 0x40c4f2
mov edi, ebp
and edi, 0xff
xor eax, eax
lea ecx, [esp + 0x1c]
mov byte [ecx], al
inc eax
inc ecx
cmp ax, 0x100
jl 0x40c5a6
xor eax, eax
lea ecx, [esp + 0x1c]
mov byte [ecx], al
inc eax
inc ecx
cmp ax, 0x100
jl 0x40c5b6
xor ecx, ecx
lea eax, [esp + 0x1c]
mov byte [eax], cl
inc ecx
inc eax
cmp cx, 0x100
jl 0x40c5c6
mov eax, dword [esp + 0x14]
xor ebx, ebx
movsx edx, cx
and eax, 0xff
lea esi, [esp + edx + 0x1c]
mov bl, byte [eax + 0x384]
mov dl, byte [esi]
add edi, ebx
mov ebp, edx
and ebp, 0xff
add ebp, edi
mov ebx, ebp
and ebx, 0x800000ff
jns 0x40c609
dec ebx
or ebx, 0xffffff00
inc ebx
mov byte [esp + 0x10], bl
mov edi, dword [esp + 0x10]
and edi, 0xff
inc eax
mov bl, byte [esp + edi + 0x1c]
mov byte [esi], bl
mov byte [esp + edi + 0x1c], dl
cdq
mov esi, 0x57
idiv esi
inc ecx
cmp cx, 0x100
mov byte [esp + 0x14], dl
jl 0x40c5a0
xor ebx, ebx
push ebx
push ebx
push ebx
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
xor eax, eax
movsx ecx, ax
mov byte [esp + ecx + 0x1c], al
xor eax, eax
lea ecx, [esp + 0x1c]
mov byte [ecx], al
inc eax
inc ecx
cmp ax, 0x100
jl 0x40c656
xor eax, eax
lea ecx, [esp + 0x1c]
mov byte [ecx], al
inc eax
inc ecx
cmp ax, 0x100
jl 0x40c666
inc eax
cmp ax, 0x100
jl 0x40c649
xor eax, eax
lea ecx, [esp + 0x1c]
mov byte [ecx], al
inc eax
inc ecx
cmp ax, 0x100
jl 0x40c67d
mov byte [esp + 0x10], bl
mov byte [esp + 0x20], bl
mov ebp, dword [esp + 0x10]
mov byte [esp + 0x21], bl
mov byte [esp + 0x14], bl
jmp 0x40c69f
xor ebx, ebx
xor eax, eax
lea ecx, [esp + 0x1c]
mov byte [ecx], al
inc eax
inc ecx
cmp ax, 0x100
jl 0x40c6a5
xor eax, eax
lea ecx, [esp + 0x1c]
mov byte [ecx], al
inc eax
inc ecx
cmp ax, 0x100
jl 0x40c6b5
xor ecx, ecx
lea eax, [esp + 0x1c]
mov byte [eax], cl
inc ecx
inc eax
cmp cx, 0x100
jl 0x40c6c5
mov eax, dword [esp + 0x14]
xor ebx, ebx
movsx edx, cx
and eax, 0xff
and ebp, 0xff
lea esi, [esp + edx + 0x1c]
mov bl, byte [eax + 0x384]
mov dl, byte [esi]
mov edi, edx
and edi, 0xff
add ebx, edi
add ebx, ebp
and ebx, 0x800000ff
jns 0x40c70c
dec ebx
or ebx, 0xffffff00
inc ebx
mov byte [esp + 0x10], bl
mov ebp, dword [esp + 0x10]
mov edi, ebp
and edi, 0xff
inc eax
mov bl, byte [esp + edi + 0x1c]
lea edi, [esp + edi + 0x1c]
mov byte [esi], bl
mov esi, 0x57
mov byte [edi], dl
cdq
idiv esi
inc ecx
cmp cx, 0x100
mov byte [esp + 0x14], dl
jl 0x40c69d
mov edi, ebp
and edi, 0xff
xor eax, eax
lea ecx, [esp + 0x1c]
mov byte [ecx], al
inc eax
inc ecx
cmp ax, 0x100
jl 0x40c74f
xor eax, eax
lea ecx, [esp + 0x1c]
mov byte [ecx], al
inc eax
inc ecx
cmp ax, 0x100
jl 0x40c75f
xor ecx, ecx
lea eax, [esp + 0x1c]
mov byte [eax], cl
inc ecx
inc eax
cmp cx, 0x100
jl 0x40c76f
movsx eax, cx
mov dl, byte [esp + eax + 0x1c]
xor ebx, ebx
lea esi, [esp + eax + 0x1c]
mov eax, dword [esp + 0x14]
and eax, 0xff
mov ebp, edx
and ebp, 0xff
mov bl, byte [eax + 0x384]
add edi, ebx
add ebp, edi
mov ebx, ebp
and ebx, 0x800000ff
jns 0x40c7b4
dec ebx
or ebx, 0xffffff00
inc ebx
mov byte [esp + 0x10], bl
mov edi, dword [esp + 0x10]
and edi, 0xff
inc eax
mov bl, byte [esp + edi + 0x1c]
mov byte [esi], bl
mov byte [esp + edi + 0x1c], dl
cdq
mov esi, 0x57
idiv esi
inc ecx
cmp cx, 0x100
mov byte [esp + 0x14], dl
jl 0x40c749
call dword [sym.imp.KERNEL32.dll_GetLastError]
xor ecx, ecx
xor eax, eax
movsx edx, ax
mov byte [esp + edx + 0x1c], al
xor eax, eax
lea edx, [esp + 0x1c]
mov byte [edx], al
inc eax
inc edx
cmp ax, 0x100
jl 0x40c7fc
xor eax, eax
lea edx, [esp + 0x1c]
mov byte [edx], al
inc eax
inc edx
cmp ax, 0x100
jl 0x40c80c
inc eax
cmp ax, 0x100
jl 0x40c7ef
xor eax, eax
lea edx, [esp + 0x1c]
mov byte [edx], al
inc eax
inc edx
cmp ax, 0x100
jl 0x40c823
mov byte [esp + 0x10], cl
mov byte [esp + 0x20], cl
mov ebp, dword [esp + 0x10]
mov byte [esp + 0x21], cl
mov byte [esp + 0x14], cl
jmp 0x40c845
xor ecx, ecx
xor eax, eax
lea edx, [esp + 0x1c]
mov byte [edx], al
inc eax
inc edx
cmp ax, 0x100
jl 0x40c84b
xor eax, eax
lea edx, [esp + 0x1c]
mov byte [edx], al
inc eax
inc edx
cmp ax, 0x100
jl 0x40c85b
lea eax, [esp + 0x1c]
mov byte [eax], cl
inc ecx
inc eax
cmp cx, 0x100
jl 0x40c869
movsx eax, cx
mov dl, byte [esp + eax + 0x1c]
xor ebx, ebx
lea esi, [esp + eax + 0x1c]
mov eax, dword [esp + 0x14]
and eax, 0xff
mov edi, edx
and edi, 0xff
and ebp, 0xff
mov bl, byte [eax + 0x384]
add ebx, edi
add ebx, ebp
and ebx, 0x800000ff
jns 0x40c8b2
dec ebx
or ebx, 0xffffff00
inc ebx
mov byte [esp + 0x10], bl
mov ebp, dword [esp + 0x10]
mov edi, ebp
and edi, 0xff
inc eax
mov bl, byte [esp + edi + 0x1c]
lea edi, [esp + edi + 0x1c]
mov byte [esi], bl
mov esi, 0x57
mov byte [edi], dl
cdq
idiv esi
inc ecx
cmp cx, 0x100
mov byte [esp + 0x14], dl
jl 0x40c843
mov edi, ebp
and edi, 0xff
xor eax, eax
lea ecx, [esp + 0x1c]
mov byte [ecx], al
inc eax
inc ecx
cmp ax, 0x100
jl 0x40c8f5
xor eax, eax
lea ecx, [esp + 0x1c]
mov byte [ecx], al
inc eax
inc ecx
cmp ax, 0x100
jl 0x40c905
xor ecx, ecx
lea eax, [esp + 0x1c]
mov byte [eax], cl
inc ecx
inc eax
cmp cx, 0x100
jl 0x40c915
mov eax, dword [esp + 0x14]
xor ebx, ebx
movsx edx, cx
and eax, 0xff
lea esi, [esp + edx + 0x1c]
mov bl, byte [eax + 0x384]
mov dl, byte [esi]
add edi, ebx
mov ebp, edx
and ebp, 0xff
add ebp, edi
mov ebx, ebp
and ebx, 0x800000ff
jns 0x40c958
dec ebx
or ebx, 0xffffff00
inc ebx
mov byte [esp + 0x10], bl
mov edi, dword [esp + 0x10]
and edi, 0xff
inc eax
mov bl, byte [esp + edi + 0x1c]
mov byte [esi], bl
mov byte [esp + edi + 0x1c], dl
cdq
mov esi, 0x57
idiv esi
inc ecx
cmp cx, 0x100
mov byte [esp + 0x14], dl
jl 0x40c8ef
mov eax, dword [esp + 0x18]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x14
ret