session: refactor reader