export session handle function