I have the authentication process working great with TweetSharp to log my users into my app. I then fetch and save the oauth_token and oauth_token_verifier on my system.
I have tried to use that same token/verifier combo to log the user back in which does prevent the necessity to have the user authorize the app again...however, I've noticed when I log in to twitter on the web, that token/verifier combination no longer is valid and so trying to log them in again doesn't work.
I dont' mind requesting a new token/verifier combo every time, but I dont' want to force my users to have to authorize the app every time. Is there a way around this?
here is the relevant code from my twitterloginhelper class:
LocalUser lsuser = new LocalUser();
TwitterService service = new TwitterService(consumer_key, consumer_secret);
OAuthAccessToken accessToken = service.GetAccessToken(requestToken, oauth_verifier);
service.AuthenticateWith(accessToken.Token, accessToken.TokenSecret);
TwitterUser user = service.VerifyCredentials(new VerifyCredentialsOptions());
lsuser.oauth_token = oauth_token;
lsuser.oauth_token_secret = oauth_verifier;
lsuser.profile_pic = user.ProfileImageUrl;
lsuser.login_type = "Twitter";
lsuser.username = user.Name;
lsuser.oauth_uid = user.Id.ToString();
lsuser.email = "";
return lsuser;
}