Function at 0x41fa10
Capabilities:
Encode data using xor

Disassembly:
sub esp, 0x24
mov eax, dword [esp + 0x34]
push ebx
mov ebx, ecx
push ebp
mov dword [eax], 0
push esi
mov al, byte [ebx + 0x130]
push edi
test al, al
mov dword [esp + 0x10], ebx
jne 0x41fa4b
mov ecx, dword [esp + 0x48]
push str.AES_not_initialized.
mov edx, dword [ecx]
call dword [edx + 0x14]
pop edi
pop esi
pop ebp
xor al, al
pop ebx
add esp, 0x24
ret 0x14
mov ecx, dword [ebx + 0x134]
cmp ecx, 2
je 0x41fa7a
mov al, byte [ebx + 0x131]
test al, al
je 0x41fa7a
mov ecx, dword [esp + 0x48]
push str.AES_direction_should_be_for_encryption.
mov eax, dword [ecx]
call dword [eax + 0x14]
pop edi
pop esi
pop ebp
xor al, al
pop ebx
add esp, 0x24
ret 0x14
mov edi, dword [esp + 0x38]
test edi, edi
je 0x41fd61
mov eax, dword [esp + 0x3c]
test eax, eax
jbe 0x41fd61
shr eax, 7
sub ecx, 0
mov dword [esp + 0x38], eax
je 0x41fcbe
dec ecx
je 0x41fc99
dec ecx
je 0x41fadb
mov esi, dword [esp + 0x48]
push str.AES_invalid_mode
mov ecx, esi
mov edx, dword [esi]
call dword [edx + 0x14]
mov eax, dword [ebx + 0x134]
mov ecx, esi
push eax
push str.mode
call fcn.0041d000
pop edi
pop esi
pop ebp
xor al, al
pop ebx
add esp, 0x24
ret 0x14
mov ecx, dword [ebx + 4]
mov edx, dword [ebx + 8]
mov dword [esp + 0x14], ecx
mov ecx, dword [ebx + 0xc]
mov dword [esp + 0x18], edx
mov edx, dword [ebx + 0x10]
test eax, eax
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x20], edx
jbe 0x41fd58
mov ebp, dword [esp + 0x40]
mov dword [esp + 0x48], eax
mov bl, byte [esp + 0x15]
xor esi, esi
jmp 0x41fb13
mov bl, byte [esp + 0x15]
mov ecx, dword [esp + 0x18]
mov edx, dword [esp + 0x1c]
mov eax, dword [esp + 0x14]
mov dword [esp + 0x28], ecx
mov dword [esp + 0x2c], edx
lea ecx, [esp + 0x24]
mov dword [esp + 0x24], eax
mov eax, dword [esp + 0x20]
lea edx, [esp + 0x24]
push ecx
mov ecx, dword [esp + 0x14]
push edx
mov dword [esp + 0x38], eax
call fcn.004200b0
mov cl, byte [esp + 0x14]
mov al, bl
shr al, 7
shl cl, 1
or al, cl
mov cl, byte [esp + 0x17]
mov byte [esp + 0x14], al
mov al, byte [esp + 0x16]
mov dl, al
shr dl, 7
shl bl, 1
or dl, bl
mov byte [esp + 0x15], dl
mov dl, cl
shr dl, 7
shl al, 1
or dl, al
mov al, byte [esp + 0x18]
mov byte [esp + 0x16], dl
mov dl, al
shr dl, 7
shl cl, 1
or dl, cl
mov cl, byte [esp + 0x19]
mov byte [esp + 0x17], dl
mov dl, cl
shr dl, 7
shl al, 1
or dl, al
mov al, byte [esp + 0x1a]
mov byte [esp + 0x18], dl
mov dl, al
shr dl, 7
shl cl, 1
or dl, cl
mov cl, byte [esp + 0x1b]
mov byte [esp + 0x19], dl
mov dl, cl
shr dl, 7
shl al, 1
or dl, al
mov al, byte [esp + 0x1c]
mov byte [esp + 0x1a], dl
mov dl, al
shr dl, 7
shl cl, 1
or dl, cl
mov cl, byte [esp + 0x1d]
mov byte [esp + 0x1b], dl
mov dl, cl
shr dl, 7
shl al, 1
or dl, al
mov al, byte [esp + 0x1e]
mov byte [esp + 0x1c], dl
mov dl, al
shr dl, 7
shl cl, 1
or dl, cl
mov cl, byte [esp + 0x1f]
mov byte [esp + 0x1d], dl
mov dl, cl
shr dl, 7
shl al, 1
or dl, al
mov al, byte [esp + 0x20]
mov byte [esp + 0x1e], dl
mov dl, al
shr dl, 7
shl cl, 1
or dl, cl
mov cl, byte [esp + 0x21]
mov byte [esp + 0x1f], dl
mov dl, cl
shr dl, 7
shl al, 1
or dl, al
mov al, byte [esp + 0x22]
mov byte [esp + 0x20], dl
mov dl, al
shr dl, 7
shl cl, 1
or dl, cl
mov cl, byte [esp + 0x23]
shr cl, 7
shl al, 1
or cl, al
mov byte [esp + 0x21], dl
mov eax, esi
mov edx, esi
mov byte [esp + 0x22], cl
and edx, 7
shr eax, 3
mov cl, 7
mov bl, byte [eax + edi]
sub cl, dl
shr bl, cl
mov cl, byte [esp + 0x23]
shl cl, 1
and bl, 1
or bl, cl
mov cl, dl
mov byte [esp + 0x23], bl
mov bl, byte [esp + 0x24]
mov dl, byte [eax + ebp]
and bl, 0x80
shr bl, cl
xor dl, bl
inc esi
cmp esi, 0x80
mov byte [eax + ebp], dl
jb 0x41fb0f
mov eax, dword [esp + 0x48]
dec eax
mov dword [esp + 0x48], eax
jne 0x41fb07
jmp 0x41fd54
test eax, eax
jbe 0x41fd58
mov esi, dword [esp + 0x40]
mov ebp, eax
push esi
push edi
mov ecx, ebx
call fcn.00420560
add edi, 0x10
add esi, 0x10
dec ebp
jne 0x41fca7
jmp 0x41fd54
mov edx, dword [ebx + 8]
mov ecx, dword [ebx + 0xc]
mov ebp, dword [ebx + 4]
mov dword [esp + 0x18], edx
mov edx, dword [ebx + 0x10]
mov dword [esp + 0x1c], ecx
test eax, eax
mov dword [esp + 0x20], edx
jbe 0x41fd58
mov esi, dword [esp + 0x40]
mov dword [esp + 0x48], eax
lea eax, [esp + 0x24]
mov ecx, ebx
push eax
push edi
call fcn.00420560
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x28]
mov edx, dword [esp + 0x18]
xor eax, ebp
mov ebp, dword [esp + 0x1c]
xor ecx, edx
mov edx, dword [esp + 0x2c]
mov dword [esp + 0x24], eax
xor edx, ebp
mov ebp, dword [esp + 0x20]
xor dword [esp + 0x30], ebp
mov ebp, dword [edi]
mov dword [esi], eax
mov eax, dword [edi + 4]
mov dword [esp + 0x28], ecx
mov dword [esi + 4], ecx
mov ecx, dword [edi + 8]
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x30]
mov dword [esp + 0x2c], edx
mov dword [esi + 8], edx
mov edx, dword [edi + 0xc]
mov dword [esi + 0xc], eax
mov eax, dword [esp + 0x48]
add edi, 0x10
add esi, 0x10
dec eax
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x20], edx
mov dword [esp + 0x48], eax
jne 0x41fce2
mov eax, dword [esp + 0x38]
mov ecx, dword [esp + 0x44]
shl eax, 4
mov dword [ecx], eax
pop edi
pop esi
pop ebp
mov al, 1
pop ebx
add esp, 0x24
ret 0x14