removed encrypt function