Basically implement RNCryptor v3.
Fix bugs and make more tests.