I would like to implement basic login and authentication in my Silverlight application. I have a users table with username and password columns and ideally would like to:
- create a login screen (can do)
- validate the login (can do)
- create a "session token" that times out after X hours 开发者_开发百科
- route certain pages based on user authenication
Im not quite sure of the best way of doing this, has anyone had any experience?
In my app so far, Im using the Silverlight navigation framework, if that makes a difference...
You might try setting up a Silverlight WCF/RIA application from the Wizard. The wizard will generate code to do most of the things that you mentioned. Digging into that will probably give you a good idea of how you want to do it, or you can modify the generated code to get what you want.
精彩评论