Move couchdb and crypto modules into util.