Refactored some of the client-side code.  Beginning of lazy crypto.