first version of login script