Reimplementing session tracking.