Add login and register functionality