Hi,
We are trying to authenticate each WCF Service call(server) by passing headers from client (mobile application). For this we have generated a token and passed the same in headers of each client call.
We have stored the tokens in HttpRuntime.Cache. But after few minutes [in idle mode] the cache entry is cleared.
Note: If continuously server and client communicates, it works perfectly.
Below is our WCF service Cache code:
HttpRuntime.Cache.Insert(key, Token, null, DateTime.Now.AddHours(1),Cache.NoSlidingExpiration);
if some other better solution available, kindly suggest how we can save the tokens alone in server and authenticate the same from client for each service call.