Add session controller and cookie mechanism