add login/logout framework