[WIP]

These are the necessary fixes before I could continue with login-box.