Function at 0x43c49d
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x33c
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
test edi, edi
mov esi, ecx
je 0x43c4d1
cmp dword [esi + 4], 0
je 0x43c4d1
push 8
pop ebx
cmp word [esi + 0x16], bx
jae 0x43c4da
add esi, 0x40
push str.Bit_depth_must_be_8_or_24
push esi
call sub.MSVCRT.dll_strcpy
pop ecx
pop ecx
xor al, al
pop edi
pop esi
pop ebx
leave
ret 4
and byte [ebp - 0x1c], 0
mov ecx, esi
call fcn.00439e0d
test eax, eax
setne al
mov byte [ebp - 0x1b], al
mov ax, word [esi + 0x16]
cmp ax, bx
setne cl
inc ecx
mov byte [ebp - 0x1a], cl
xor ecx, ecx
cmp ax, bx
mov word [ebp - 0x19], cx
setne dl
dec edx
mov word [ebp - 0x14], cx
and edx, 0xff
cmp ax, bx
movzx dx, dl
mov word [ebp - 0x17], dx
mov word [ebp - 0x12], cx
setne dl
dec edx
and byte [ebp - 0xb], cl
and edx, 0x18
cmp dword [esi + 0x188], ecx
mov byte [ebp - 0x15], dl
mov dx, word [esi + 0xc]
mov word [ebp - 0x10], dx
mov dx, word [esi + 0x10]
mov word [ebp - 0xe], dx
mov dl, al
mov byte [ebp - 0xc], dl
je 0x43c555
cmp ax, 0x18
jne 0x43c555
mov byte [ebp - 0xc], 0x20
mov eax, dword [edi]
push 1
lea ecx, [ebp - 0x1c]
push 0x12
push ecx
mov ecx, edi
call dword [eax + 0xc]
cmp word [esi + 0x16], bx
jne 0x43c5b1
mov ecx, esi
call fcn.00439e0d
lea ecx, [ebp - 0x33b]
add eax, 2
mov dword [ebp - 4], 0x100
mov dl, byte [eax - 2]
mov byte [ecx - 1], dl
mov dl, byte [eax - 1]
mov byte [ecx], dl
mov dl, byte [eax]
mov byte [ecx + 1], dl
add eax, 4
add ecx, 3
dec dword [ebp - 4]
jne 0x43c581
mov eax, dword [edi]
push 1
lea ecx, [ebp - 0x33c]
push 0x300
push ecx
mov ecx, edi
call dword [eax + 0xc]
push esi
lea ecx, [ebp - 0x3c]
call fcn.0043c988
cmp dword [esi + 0x188], 0
je 0x43c679
cmp word [esi + 0x16], bx
je 0x43c679
movzx eax, word [ebp - 0x10]
shl eax, 2
push eax
call dword [sym.imp.MSVCRT.dll_malloc]
and dword [ebp - 8], 0
cmp word [ebp - 0xe], 0
pop ecx
mov dword [ebp - 4], eax
jbe 0x43c66d
xor ebx, ebx
cmp word [ebp - 0x10], bx
jbe 0x43c64d
mov eax, dword [ebp - 4]
lea edi, [eax + 1]
push dword [ebp - 8]
lea eax, [ebp - 0x24]
mov ecx, esi
push ebx
push eax
call fcn.00439f32
mov eax, dword [eax]
push dword [ebp - 8]
mov dword [ebp - 0x20], eax
mov byte [edi - 1], al
mov al, byte [ebp - 0x1e]
mov byte [edi], ah
push ebx
mov ecx, esi
mov byte [edi + 1], al
call fcn.0043a2f3
movzx ecx, byte [esi + 0x178]
movzx eax, al
imul eax, ecx
cdq
mov ecx, 0xff
add edi, 4
idiv ecx
inc ebx
mov byte [edi - 2], al
movzx eax, word [ebp - 0x10]
cmp ebx, eax
jl 0x43c5fc
mov edi, dword [ebp + 8]
movzx ecx, word [ebp - 0x10]
mov eax, dword [edi]
push 1
shl ecx, 2
push ecx
mov ecx, edi
push dword [ebp - 4]
call dword [eax + 0xc]
movzx eax, word [ebp - 0xe]
inc dword [ebp - 8]
cmp dword [ebp - 8], eax
jl 0x43c5ee
push dword [ebp - 4]
call dword [sym.imp.MSVCRT.dll_free]
pop ecx
jmp 0x43c6ae
xor ebx, ebx
cmp word [ebp - 0xe], bx
jbe 0x43c6ae
push ebx
lea ecx, [ebp - 0x3c]
call fcn.0043c9b3
movzx ecx, word [esi + 0x16]
movzx edx, word [ebp - 0x10]
shr ecx, 3
imul ecx, edx
mov eax, dword [edi]
push 1
push ecx
mov ecx, edi
push dword [ebp - 0x2c]
call dword [eax + 0xc]
movzx eax, word [ebp - 0xe]
inc ebx
cmp ebx, eax
jl 0x43c681
mov al, 1
jmp 0x43c4d3