implement server/client sessions