Keeping Chrome Tab active to not be logged out

My workplace recently implemented an Okta SSO sign-on to Access tools we are using.

However, my biggest annoyance is if I take a 35-minute lunch and i come back the Okta tab has logged out to due inactivity and it's a pain to log back in with 2 different forums of 2FA.

How is everybody attacking keeping the browser tab active to avoid this?

I threw together a pretty clunky macro that only runs if the computer has been inactive for more than 10 minutes and Slack is open. But it's fairly manual and subject to errand clicks since it just tabs thru the page and then returns the cursor to the top.

I am sure there is a better way to do this so i wanted to check in with the homies here,

Chrome Activate When Away (PM).kmmacros (36.2 KB)

It really depends on what counts as "activity". Can you just rotate through open Chrome tabs/windows? Open a new window then close it again? Just page-up/down in the current window?

Good point, I think the tab itself logged into the Okta page needs to be active itself which is why I went with the tabbing method.

If you just need to have the Okta tab at the front (and either you've only one Chrome window or the window with the Okta tab is frontmost) then something like this action will probably do the job -- set the "title does not contain" field to the title of your Okta tab:

Luckily for us, this "wraps around" -- if you're on the last tab, "Next" takes you to the first. That does mean, however, that you'll be in an endless loop if you get the Title text wrong or the Okta tab isn't in the frontmost Chrome window! So be ready with the "Cancel" action from KM's menu bar icon while you are testing...

If you think that might be a problem, changes can be made -- eg counting the number of loops and exiting if that number is ever greater than the number of tabs in the front Chrome window.

That might work, Iā€™d throw in also a 2 min. Pause in the inner part of the loop as an action to avoid running the action thousands of times.

Also, tried if just moving the mouse avoids the Lock Screen?

The screen does not lock it just seems to be that Chrome tab with Okta that does inactive.

With AppleScript you can recall a specific GC tab even if it is buried amongst other tabs. After having done that, you could possibly use a select a menu item action to refresh the page which works on the pages I need to keep something logged in.

Here is a macro that is designed to do that... just add the tab's name in the variable at the top of the actions. Try it out and see if it works for you.

Keep Google Chrome webpage session active.kmmacros (6.6 KB)

Macro screenshot (click to expand/collapse)

1 Like

Awesome I'll set this up in the AM!

Thank you!

1 Like