very basic (i.e. weak) symmetric key encryption in javascript