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

Landing on Dashboard after authorisation, not in Mastodon app #180

Open
lexpostma opened this issue Oct 7, 2024 · 3 comments
Open

Landing on Dashboard after authorisation, not in Mastodon app #180

lexpostma opened this issue Oct 7, 2024 · 3 comments

Comments

@lexpostma
Copy link

Every time I try to authorise my Mastodon app with my ActivityPub enabled WordPress site, I just land on the WordPress Admin Dashboard.

Tried with:

  • Official Mastodon app iOS app
  • Ivory iOS
  • Ivory Mac
  • This plugin’s own Tester

I have (at least) these plugins installed and enabled:

  • ActivityPub
  • Friends
  • Enable Mastodon Apps

Not sure how I can better describe the issue. I just enter the URL and after I log in (often I’m already logged in) it just goes to the Dashboard. It doesn’t redirect to anything.

@akirk
Copy link
Owner

akirk commented Oct 9, 2024

Thanks for reporting and sorry about the trouble. Can you see the URL of your WordPress when on the authorization screen (it should be a wp-login.php URL)? Could you check if the URL contains a redirect_uri parameter?

@lexpostma
Copy link
Author

No need to apologise, I appreciate you helping me out.

I’ve configured my site to use WordPress.com Log In, and require it with add_filter('jetpack_remove_login_form', '__return_true’); which could relevant…

  • When I try to add my account to Ivory, it first goes to https://lexpostma.me/wp-login.php?redirect_to=https%3A%2F%2Flexpostma.me%2Fwp-login.php%3Fclient_id%3D [client_id] %26redirect_uri%3Dcom.tapbots.Ivory.22300%253A%252Frequest_token%25 [token] %26response_type%3Dcode%26scope%3Dread%2520write%2520follow%2520push%26action%3Denable-mastodon-apps-authenticate&reauth=1
  • From there I click the “Log in with WordPress.com” button which goes to https://wordpress.com/log-in?redirect_to=https%3A%2F%2Fwordpress.com%2Fwp-login.php%3Faction%3Djetpack-sso%26site_id%3D [id] %26sso_nonce%3D [sso thingy]
  • After logging in there, it returns to
    https://lexpostma.me/wp-login.php?action=jetpack-sso&redirect_to=https%3A%2F%2Flexpostma.me%2Fwp-login.php%3Fclient_id%3D [client_id] %26redirect_uri%3Dcom.tapbots.Ivory.22300%253A%252Frequest_token%25 [token] %26response_type%3Dcode%26scope%3Dread%2520write%2520follow%2520push%26action%3Denable-mastodon-apps-authenticate
  • There it just lands on the dashboard of my WordPress site

@bchabot
Copy link

bchabot commented Nov 25, 2024

I was running into the same issue.

tl:dr login redirection plugins may break the login for this plugin.

I found the problem in Paid Memberships Pro. I found it by deactivating plugins, one at a time. Since I want to keep using this plugin, I searched for settings. I ended up finding one in the "Pages" configuration. It was using a custom login page and would only return me to that after I authorized. Once I changed the setting to use the WordPress default login, the remote authentication worked.

I suspect the login plugin is the source here. Now, my users will just have to deal with a standard WP login till I figure out how to change that.

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

4 participants
@akirk @lexpostma @bchabot and others