Cannot logout of a shinyapps.io app

382 views
Skip to first unread message

Ambarish J

unread,
Jan 22, 2015, 4:55:41 PM1/22/15
to shinyap...@googlegroups.com

I have deployed a Shiny app using shinyapps.io and have made the application private. I can logon to the app using my credentials and use the app, but I am not able to logout of the app.

When I try to out logout of the app I am redirected to the following link:

https://userName.shinyapps.io/appName/__logout__

And the result of this redirect is: Not Found.


Tareef Kawaf

unread,
Jan 22, 2015, 5:00:14 PM1/22/15
to Ambarish J, shinyap...@googlegroups.com
This is a known issue that we need to resolve. 

--
You received this message because you are subscribed to the Google Groups "ShinyApps Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to shinyapps-use...@googlegroups.com.
To post to this group, send email to shinyap...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/shinyapps-users/7ac097d8-1ffd-4931-8a21-cfcd33bde7b6%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

CaroAnametrix

unread,
Jan 25, 2016, 9:04:45 PM1/25/16
to ShinyApps Users, ajosh...@gmail.com
Has this issue been solved? I am not able to log out either, and I suspect it is making my app crash sometimes. Thanks!

Fereshteh Karimeddini

unread,
Jan 26, 2016, 1:51:27 PM1/26/16
to ShinyApps Users, ajosh...@gmail.com
Are you using this format for the logout link:

CaroAnametrix

unread,
Jan 26, 2016, 2:03:10 PM1/26/16
to ShinyApps Users, ajosh...@gmail.com
This link does not work. I just don't know how to log out of my app, or how the people I send login access to can log out when they are on the app and could not find the info.

Andy Kipp

unread,
Jan 26, 2016, 2:04:18 PM1/26/16
to CaroAnametrix, ShinyApps Users, ajosh...@gmail.com
What is the URL for your application?

CaroAnametrix

unread,
Jan 26, 2016, 2:09:48 PM1/26/16
to ShinyApps Users, cesc...@anametrix.com, ajosh...@gmail.com
well I can't really disclose it publicly. But it is something like https://mycompany.shinyapps.io/myclientname/. When I send the URL to my client, he is asked to log in the first time he tires on a computer, but after that everyone using this computer can access just by clicking on the URL. (I am using the standard formula for apps at 99$ a month because I need password protection). Is there any standard procedure to log out of the app?

Andy Kipp

unread,
Jan 26, 2016, 2:47:51 PM1/26/16
to CaroAnametrix, ShinyApps Users, ajosh...@gmail.com
We've recently changed the way logging into an application hosted on shinyapps.io works. This was necessary to improve security. It is now a two step process (Both steps are completed in the popup window, when you click 'Login' for a private app):

1) You must first authenticate to the shinyapps.io service (login.shinyapps.io). When you do this, we create a session cookie for login.shinyapps.io (called shinyapps_auth).

2) Once you've authenticated to the shinyapps.io service you can then authenticate to the application itself using your existing session for login.shinyapps.io. This sets another cookie called (therealshinyapps) for the specific application you are logging into.

As I said, both these steps happen automatically when you click "Login" for a private application. The two login steps are necessary, because these cookies must be distinct between shinyapps.io itself, and between applications hosted on shinyapps.io.

As Fereshteh mentioned, you can logout of an application by visiting the URL: https://userName.shinyapps.io/appName/__logout__/. When you visit this URL you are in fact logged out the application, but you're still got a session cookie for login.shinyapps.io, so clicking "Login" will simply authenticate you the application using your existing login.shinyapps.io session without requiring you to re-enter your password. 

Currently the login.shinyapps.io uses a session cookie so if you close your window it *should* require you to re-authenticate with login.shinyapps.io the next time you attempt to authenticate to an application. That said, it turns out both Chrome and Firefox keep these session cookies around for longer then they should unless you disable the "feature". See this thread for more info. Regardless you can always logout of the shinyapps.io service itself by going to https://login.shinyapps.io/logout after you logout of your application. I have some ideas on how to address this, so its something we can likely fix.

I apologize if this is all bit confusing. We've recently done a lot work to improve the security of private applications, and as is typically the case with additional security, it can create more complexity. 

-Andy

CaroAnametrix

unread,
Jan 26, 2016, 4:39:30 PM1/26/16
to ShinyApps Users, cesc...@anametrix.com, ajosh...@gmail.com
Thank you very much, it is very helpful. And I could log out. Thanks for answering so quickly.

Angel de la Llama

unread,
Feb 12, 2016, 2:13:16 PM2/12/16
to ShinyApps Users, cesc...@anametrix.com, ajosh...@gmail.com
Are there any plans to automatically log out from an app when the session is closed? Although Andy's answer works nicely it has to be done manually and if the browser is closed and the user forgets to log out the app is still available in that computer without logging in the next time.

Thank you,
Angel

Joe Erickson

unread,
Apr 14, 2016, 2:48:05 PM4/14/16
to ShinyApps Users, cesc...@anametrix.com, ajosh...@gmail.com
  • Is the proper way to logout of a shinyapps.io application documented anywhere beyond this thread?
  • Is this process likely to change in the future (and break what is described in this thread)?
  • How will changes to the logout process be communicated in the future?
Reply all
Reply to author
Forward
Message has been deleted
0 new messages