views:

191

answers:

2

I want to add a "Remember Me" check box to the login form of my WPF App. What's the best way to do this?

Currently the app logs in via a websevice call that returns an authenticated token that it uses for subsequent calls. Should I simply two-way encrypt and store this token somewhere in the files system?

+3  A: 

You could also store it in Isolated Storage or create a User setting in your application's Settings.

Edit: Oren's suggestion of using DPAPI to protect information is well and good, but it doesn't store anything:

An important point to remember is that DPAPI merely applies cryptographic protection to the data. It does not store any of the protected data; therefore applications calling DPAPI must implement their own storage of the protected data.

Joel B Fant
I use this, works a treat
TWith2Sugars