configure cookie with key