Added some new features for managing login stuff
TBD login/logout refresh
TDB update and save only for registered and granted users