Fixed bug #10205: DB session record is only created when user is authenticated