Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature: Option to redirect back to iframed version after SSO/... login #462

Open
jonathanmmm opened this issue Mar 29, 2022 · 1 comment

Comments

@jonathanmmm
Copy link
Contributor

Hi,

I saw the following pull request
#235
right now this makes it possible to login via e.g. OpenID Connect, but the thing is the users are after login still on the non iframed version. This could make users unaware that they are still logged into nextcloud and even when logging out from Element they are still logged into nextcloud, as synapse does not right now support to send the log out command to an OpenID Connect server.

If users are logging out via nextcloud their session is locally deleted.

I tried that with redirects via nginx, but it seems the # makes it so it is locally (can't see server accesses via this path) and if I say /apps/riotchat/riot/ redirect to /apps/riotchat/., like this:

location ~ /apps/riotchat/riot/ {
        return  302  /apps/riotchat/$1$is_args$args;
    }

it does not work either (getting double nextcloud bar and blank white page below).

I also tried and removed /riot from main.js and main.js.map, didn't work.

My proposal would be an option:

  • To make it possible via a setting, so that when the user reaches /apps/riotchat/riot/#/home it redirects back to /apps/riotchat/#/home, that way the iframed version can be used and the user sees the nextcloud bar at the top and can log out that way.
  • This could be done via maybe a config (config.php) or via the Web UI
@jonathanmmm
Copy link
Contributor Author

I changed in js/main.js and js/main.js.map the following string /apps/riotchat/riot/#/login to /apps/riotchat/#/login (before I removed all /riot parts.

Now it works, I can log in via OpenID Connect in an iFrame.

Still propose to make this possible via UI/config parameter to not have to change the source code (possibly after every update)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant