Tools for ensuring login or log out.