this kind of session handler is weird and way to complicated
added HTTP Exception and INI file for status codes