I am doing the sample Login screen.so i create the 2 local variable(Text)  for username & password then assign that 2 variable to textbox control.In the Login button click i use the Acton Login it works only for the "admin" user.Then i tryed to used the "LoginPassword".But in this case it need "UserIdentifier" variable to userid.we cant assign the useridentifier varaiblae to textbox control.
so i checked with the table(sql query) on passing the textbox value and check Table.List.Empty.If not empty i assign the session.Username and move to home page.In this case i Click the Logout it goes to Login screen but click back in IE it move to existing page.Can you Please tell how to avoid on going back to existing page Or If any Tutorial exist please send the path.
I haven't been through this material yet - will soon - so I don't know if it helps, but,
have you been through this material?


Developer Course 2 - Authentication and Security.
Devaraj -

To make this work, you need to look up the User ID first. Do *not* assign Session.Username, that will occur as part of the LoginPassword action. Your general workflow should be:

1. Use the input (username or email address) that the user has identified themselves with to lookup the user in the User entity.
2. Use that user ID, combined with the entered password, as parameters to LoginPassword.

Remember, LoginPassword does NOT automatically encrypt the passwords, and there is no guarantee that the passwords in the DB are encrypted. If the passwords in the DB are encrypted, you need to encrypt what the user gives you before giving it to LoginPassword.


From Your Reply i understood that i have to set like
LoginPassword Action
UserId=UserLogin name[user name in Login Screen]
Table : UserDetails
But i can't set the value to UserId because it is user Identifier type.When i try to set the Login control variable it is Text data type.And also i tried to get from table it will be UserDetails Identifier.
So please give the flow of using the LoginPassword Actions


Hi Devaraj,

Since you asked similar questions in two different topics, I'm placing the answer here as well.

For you to correctly see how a Login process works, I would suggest creating a new eSpace > From Styleguide, and looking at the normal Login flow, as well as the Change Password web block.

You can try to use the LoginPassword action instead, but that's just adding complexity.

I hope this helps.


Paulo Tavares
Devaraj -

If you want to use LoginPassword, you need to do the following:

1. Look up the UserId in the User table, using the username or email address that the user provides.
2. Pass that UserId and the password (after putting it through Encrypt() if the underlying password is encrypted) to LoginPassword.