Authenticating functionlity added