[TIMOB-14976] Small bug fixes. Added JS encryption.