I am using a login form which allows the user to use yii’s ‘remember me’ option.
During the first login I am setting some user->state values which of course will be lost after the session ended.
Now what is the best way to set these states again if the user gets automatically logged in again through the ‘remember me’ cookie.
So far I have been setting some user states within the UserIdentity class (in the components folder) after the user has successfully logged in:
Yii::app()->user->setState('someKey', $someValue);
What would be best to restore these states once auto login gets used?
I do not want to store the set user states in a cookie since they might contain too security sensitive data.
Sorry for the quick answer, but these are a few possibilities: