Improved session handling - CODE NOT TESTED
Configuration draft