So normally if you do encrypt('a') twice in a row you'll get the same result. But sometimes (as is the case in SSH) this is not desirable. You want encrypt('a') || encrypt('a') == encrypt('aa'). What is this called?
PHP does it with mcrypt:
<?php
$mcrypt = mcrypt_module_open(MCRYPT_DES, '', MCRYPT_MODE_CBC, '');
mcrypt_generic_init($mcrypt, '@@@@@@@@', 'xxxxxxxx');
echo bin2hex(mcrypt_generic($mcrypt, 'dddddddd'));
echo "\r\n";
echo bin2hex(mcrypt_generic($mcrypt, 'dddddddd'));
eg. you're encrypting dddddddd twice but getting a different result each time.
PHP does not do it with OpenSSL:
echo bin2hex(openssl_encrypt('dddddddd', 'des-cbc', '@@@@@@@@', OPENSSL_RAW_DATA | OPENSSL_ZERO_PADDING, 'xxxxxxxx'));
echo "\r\n";
echo bin2hex(openssl_encrypt('dddddddd', 'des-cbc', '@@@@@@@@', OPENSSL_RAW_DATA | OPENSSL_ZERO_PADDING, 'xxxxxxxx'));
Given the API it makes since that OpenSSL wouldn't do it. It can certainly be emulated by changing the IV's but you'd have to do it manually.
Anyway, what is this called? Is it called progressive encryption? Continuous encryption?