key and salt are required