Implementing login/registration features.

Incomplete.