implements sessions controller