Fix for error 500 when visiting the site for the first time: session key not
  available yet; we use that one for database keys.