working CBC mode