I want to set Role for some users after login. Note, I don’t want to add user to this role permanently and write to db, just set some role after login and then check if this user is in this role. Is it possible ?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
I would create your own AppUser class that has AppRoles.
You can link up your AppRoles to Membership roles (or not).
I do this so I can fake user roles for testing and to contain Membership services code.