Function at 0x10197bc4
Capabilities:
Encrypt data using aes
Reference aes constants

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x14
mov edx, dword [ebp + 0x10]
mov ecx, dword [ebp + 8]
lea edi, [edx + 3]
test edx, edx
cmovns edi, edx
sar edi, 2
lea eax, [edi + 6]
cmp edx, 0x10
mov edx, 0xa
cmovge edx, eax
mov eax, ecx
mov dword [ecx], 4
mov dword [ecx + 4], edx
mov dword [ebp - 0x20], edx
lea esi, [edx*4 + 4]
test esi, esi
jle 0x10197d1e
mov edx, edi
lea eax, [edi*4]
sub ecx, eax
mov eax, dword [ebp + 8]
add ecx, 8
mov dword [ebp - 0x18], ecx
xor ecx, ecx
xor edi, edi
inc edi
mov dword [ebp - 0x1c], edi
mov dword [ebp - 0x14], edx
mov dword [ebp - 0x10], esi
cmp ecx, edx
jge 0x10197c3c
mov edi, dword [ebp + 0xc]
mov edi, dword [edi + ecx*4]
bswap edi
jmp 0x10197d11
mov edi, dword [eax + ecx*4 + 4]
mov eax, ecx
mov esi, edx
cdq
idiv esi
test edx, edx
je 0x10197ca5
cmp dword [ebp + 0x10], 0x1c
jl 0x10197d02
cmp edx, 4
jne 0x10197d02
mov edx, edi
shr edx, 0x18
mov esi, edi
shr esi, 0x10
mov ebx, 0xff
and esi, ebx
mov eax, edi
shr eax, 8
and eax, ebx
and edi, ebx
movzx edx, byte [edx + str.cw]
movzx esi, byte [esi + str.cw]
shl edx, 0x10
shl esi, 8
or esi, edx
movzx eax, byte [eax + str.cw]
or eax, esi
shl eax, 8
movzx edi, byte [edi + str.cw]
or edi, eax
jmp 0x10197d02
mov eax, edi
shr eax, 0x10
mov esi, 0xff
and eax, esi
mov edx, edi
shr edx, 8
and edx, esi
movzx eax, byte [eax + str.cw]
mov ebx, dword [ebp - 0x1c]
xor eax, ebx
movzx edx, byte [edx + str.cw]
shl eax, 0x10
shl edx, 8
or edx, eax
mov eax, edi
and eax, esi
movzx eax, byte [eax + str.cw]
or eax, edx
shr edi, 0x18
shl eax, 8
movzx edi, byte [edi + str.cw]
or edi, eax
lea eax, [ebx + ebx]
and eax, esi
movsx ebx, bl
shr ebx, 7
and ebx, 0x1b
xor ebx, eax
mov dword [ebp - 0x1c], ebx
mov eax, dword [ebp + 8]
mov edx, dword [ebp - 0x14]
mov esi, dword [ebp - 0x10]
mov ebx, dword [ebp - 0x18]
xor edi, dword [ebx + ecx*4]
mov dword [eax + ecx*4 + 8], edi
inc ecx
cmp esi, ecx
jne 0x10197c2b
mov esi, dword [ebp - 0x20]
test esi, esi
js 0x10197dfa
mov edx, 4
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x10], 0
test edx, edx
jle 0x10197de6
xor ebx, ebx
mov esi, dword [ebp - 0x10]
mov edi, dword [eax + 4]
mov ecx, dword [ebp - 0x18]
add ecx, edi
imul ecx, edx
add ecx, ebx
mov ecx, dword [eax + ecx*4 + 8]
test esi, esi
je 0x10197dcc
cmp edi, esi
je 0x10197dcc
mov eax, ecx
shr eax, 0x18
mov dword [ebp - 0x14], eax
mov eax, ecx
shr eax, 0x10
mov edi, 0xff
and eax, edi
mov edi, ecx
shr edi, 8
mov esi, 0xff
and edi, esi
mov esi, dword [ebp - 0x14]
movzx esi, byte [esi + str.cw]
movzx eax, byte [eax + str.cw]
mov eax, dword [eax*4 + 0x103bde30]
xor eax, dword [esi*4 + 0x103bda30]
mov esi, 0xff
and ecx, esi
movzx esi, byte [edi + str.cw]
xor eax, dword [esi*4 + 0x103be230]
mov esi, dword [ebp - 0x10]
movzx ecx, byte [ecx + str.cw]
xor eax, dword [ecx*4 + 0x103be630]
mov ecx, eax
mov eax, dword [ebp + 8]
imul edx, esi
add edx, ebx
mov dword [eax + edx*4 + 0x1e8], ecx
inc ebx
mov edx, dword [eax]
cmp ebx, edx
jl 0x10197d49
mov esi, dword [eax + 4]
mov edi, dword [ebp - 0x10]
lea ecx, [edi + 1]
dec dword [ebp - 0x18]
cmp edi, esi
mov dword [ebp - 0x10], ecx
jl 0x10197d3c
add esp, 0x14
pop esi
pop edi
pop ebx
pop ebp
ret