session: replace SocketChannel with ReadableByteChannel and WritableByteChannel

code cleanup in preparation for a possible SSL channel implementation