Hi all,

I've been able to give custom authentication to sync_gateway. It all works 
fine. But I'm currently trying to stop two devices to use the same 
username/password. The scenario is at any time, only one login per user. 
For a single user, the new login will de-activate the previous login, and 
force quit the previous login. 

But I can't seem to get it work. What I'm trying is:

   -  Each time a user logs in, I first clear all current sessions for the 
   user using the sync_gateway admin rest api DELETE 
   /cookbook/_user/chef123/_session.
   - After that, I use the sync_gateway admin rest api POST 
   /cookbook/_session HTTP/1.1 to get a fresh session id.

Then what I'm expecting is all devices using previous session id will fail 
to sync since the previous sessions are de-activated.

But it seems both the new and previous device can access sync_gateway? It 
seem the previous session is cached some where in sync_gateway, how could I 
kick away the previous session ids? 

-Sean

-- 
You received this message because you are subscribed to the Google Groups 
"Couchbase Mobile" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/mobile-couchbase/be33e16f-7b81-4b97-9470-b801b50d1404%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to