this is why I added the "loggedIn" flag to the SessionImpl class - simply check it at the beginning of each function. If it's false, throw an exception. logout(const Ice::Current&) already sets it, so simply call it from here.