Function at 0x4210e0
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 eax, dword [ebx + 0x2c]
push edi
test eax, eax
mov dword [esp + 0x10], ebx
je 0x421118
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 eax, dword [ebx + 0x30]
cmp eax, 2
je 0x421141
mov ecx, dword [ebx + 0x34]
test ecx, ecx
jne 0x421141
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 0x421430
mov esi, dword [esp + 0x3c]
test esi, esi
jbe 0x421430
shr esi, 7
sub eax, 0
mov dword [esp + 0x38], esi
je 0x421401
dec eax
je 0x421361
dec eax
je 0x42119f
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 + 0x30]
mov ecx, esi
push eax
push str.mode
call fcn.0041e0a0
pop edi
pop esi
pop ebp
xor al, al
pop ebx
add esp, 0x24
ret 0x14
mov ecx, dword [ebx + 0x38]
mov edx, dword [ebx + 0x3c]
mov eax, dword [ebx + 0x40]
mov dword [esp + 0x14], ecx
mov ecx, dword [ebx + 0x44]
mov dword [esp + 0x18], edx
test esi, esi
mov dword [esp + 0x1c], eax
mov dword [esp + 0x20], ecx
jbe 0x421427
mov ebp, dword [esp + 0x40]
mov dword [esp + 0x48], esi
mov bl, byte [esp + 0x15]
xor esi, esi
jmp 0x4211d7
mov bl, byte [esp + 0x15]
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x1c]
mov edx, dword [esp + 0x14]
mov dword [esp + 0x28], eax
mov dword [esp + 0x2c], ecx
lea eax, [esp + 0x24]
lea ecx, [esp + 0x24]
mov dword [esp + 0x24], edx
mov edx, dword [esp + 0x20]
push eax
push ecx
mov ecx, dword [esp + 0x18]
mov dword [esp + 0x38], edx
call fcn.00421950
mov al, byte [esp + 0x14]
mov dl, bl
shr dl, 7
shl al, 1
or dl, al
mov al, byte [esp + 0x16]
mov cl, al
mov byte [esp + 0x14], dl
shr cl, 7
shl bl, 1
or cl, bl
mov byte [esp + 0x15], cl
mov cl, byte [esp + 0x17]
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 0x4211d3
mov eax, dword [esp + 0x48]
dec eax
mov dword [esp + 0x48], eax
jne 0x4211cb
mov esi, dword [esp + 0x38]
jmp 0x421427
mov edx, dword [ebx + 0x3c]
mov eax, dword [ebx + 0x40]
mov ecx, dword [ebx + 0x44]
mov ebp, dword [ebx + 0x38]
test esi, esi
mov dword [esp + 0x18], edx
mov dword [esp + 0x1c], eax
mov dword [esp + 0x20], ecx
jbe 0x421427
mov dword [esp + 0x48], esi
mov esi, dword [esp + 0x40]
lea edx, [esp + 0x24]
mov ecx, ebx
push edx
push edi
call fcn.00421e00
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 0x421389
mov esi, dword [esp + 0x38]
jmp 0x421427
test esi, esi
jbe 0x421427
mov ebp, dword [esp + 0x40]
mov dword [esp + 0x48], esi
push ebp
push edi
mov ecx, ebx
call fcn.00421e00
mov eax, dword [esp + 0x48]
add edi, 0x10
add ebp, 0x10
dec eax
mov dword [esp + 0x48], eax
jne 0x42140d
mov ecx, dword [esp + 0x44]
shl esi, 4
mov dword [ecx], esi
pop edi
pop esi
pop ebp
mov al, 1
pop ebx
add esp, 0x24
ret 0x14