Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6848531
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T00:52:46+00:00 2026-05-27T00:52:46+00:00

How do I detect in devise when the user’s access tokens are stale and

  • 0

How do I detect in devise when the user’s access tokens are stale and thus logging the user out?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T00:52:47+00:00Added an answer on May 27, 2026 at 12:52 am

    Why do you need this? There is timeoutable option exist that allows to track session timeout. I might be wrong, but tokens are cookies keys that have time to live and they are tracked by browser. From Devise (hooks):

    Each time a record is set we check whether its session has already timed out
    or not, based on last request time. If so, the record is logged out and
    redirected to the sign in page. Also, each time the request comes and the
    record is set, we set the last request time inside it’s scoped session to
    verify timeout in the following request.

    —- UPDATE (to not put in commets as its large)—

    In the most cases, when you use is logged in, there is no requirements to get authentication from external servises. So in the cases when user is logged in (i.e. session cookie present and session is valid), and in the same time she logs out from external servise that means that she can use your site until your session is expires. Again, the external service is used once user requires authentication. So when session is expired on your site and user trying to log in using external service she will be redirected to external site where she will log in (or not if already). Then external service redirects back to your site provided callback (in the most cases path is /auth/:provider/callback) where your controller (or default provided by devise) will create if required an user and a session for him.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is this the proper way to detect which device a user is running? NSString
Java Servlets - How do I detect if a user is from a mobile
I am trying to detect when a user has finished scrolling a web page
In my android app, I want to detect the user's device if the device
Hey guys my question is i want to detect if my user is using
If I use the following to detect iPad Safari user, will it work if
I have 3 short questions, very related: How do i detect if the user
So I wanted to detect the user current location when my main activity starts.
I want to use Modernizr to detect whether a user is view a site
I want to be able to detect if the current user is using a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.