login, logout, adduser and fixes