Port CBC mode of operation (fixes #4)