func (cr *cipherBlockReader) read(p []byte) (n int, err error) {
	bs := cr.mode.BlockSize()
	l := len(p) - len(p)%bs
	p = p[:l]
	l = len(cr.inbuf)
	if l > 0 {
		copy(p, cr.inbuf)
		cr.inbuf = cr.inbuf[:0]
	}
	n, err = io.ReadAtLeast(cr.r, p[l:], bs-l)
	n += l
	p = p[:n]
	l = n % bs
	if l > 0 {
		n -= l
		cr.inbuf = append(cr.inbuf, p[n:]...)
		p = p[:n]
	}
	if err != nil {
		if err == io.ErrUnexpectedEOF || err == io.ErrShortBuffer {
			err = io.EOF
		}
		return 0, err
	}
	cr.mode.CryptBlocks(p, p)  
	return n, nil
}
read reads and decrypts one or more input blocks into p.
len(p) must be >= cipher block size.
package rardecode
import (
	"crypto/aes"
	"crypto/cipher"
	"io"
)
type cipherBlockReader struct {
	r      io.Reader
	mode   cipher.BlockMode
	inbuf  []byte  
	outbuf []byte  
	n      int     
	err    error
}