Split crypt into a package to allow alternative implementations (#189)

7 files changed