Im trying to create an admin functionality to impersonate a user, but im having problems deciding if I should avoid using the user_hash, creating a impersonate_hash.
I tried that but when the user loges in pops out the administrator and vice versa, that causes to generate a new user_hash there fore close other user session.
Either overload the force_login() method, or create a second method that allows you to do what you want. All you need to do is not generate a new login hash, but fetch the existing login hash, and store that in the session instead.
Only downside with that method is that if the original user logs out, and logs in again, a new login hash will be generated, which will cause your administrator to be thrown out. If you want to deal with that too, a more drastic change is needed.