Imported various code from PCLContrib for encryption making necessary changes for Mvx, should work but no tests