Session setup, controllers refactoring