Comments (13)
Hiya, you should always log in using the host domain value, not the account domain value, so it's normal that with phanpy you can't log in using the account-domain. I'm afraid I don't know neodb.social, is that a client that works with Mastodon etc?
from gotosocial.
A number of clients have heuristics to detect the split-domain setup themselves and then initiate login and API calls based on the host domain. However, not everyone does, and sometimes the heuristics are a bit wobbly.
It's usually best to initiate login directly from the host domain. That ensures the authentication headers and cookies match the exact domain for the API calls.
from gotosocial.
@daenney @tsmethurst But I can't log in to neodb.social even using host domain
from gotosocial.
Hmm, did you at any point remove any applications from your database? For example, did you create an instance, sign in successfully to neodb.social, and then wipe your database file and start again? Just trying to narrow things down a bit.
from gotosocial.
With the UI being in Simplified Chinese I'm afraid I'm having a rather hard time figuring anything out. The sources for it seem to be https://github.com/neodb-social/neodb which in turn is using https://github.com/jointakahe/takahe for the federation bits.
This makes it a bit of a faff to set up, the compose file has 2 database, a Redis, Typesense and multiple daemons. I don't have the energy to dive into that one right now.
from gotosocial.
Phanpy is a lot easier to deal with, and I have no issue logging in there. Both a local version of it as well as phanpy.social work fine for me, and I have a split domain setup.
When I initiate a login on Phanpy using the account domain, the UI immediately errors. This is expected. When I initiate the login from the host domain, everything works and I login successfully.
from gotosocial.
Best I can tell, there's no issue with Phanpy. It just doesn't have the heuristics to detect the split-account setup that some clients have, but GtS can't do anything about that.
Which leaves NeoDB. Given the oauth error, there's probably two queries worth running using the sqlite3
CLI:
select * from applications where id = '01D5AV31Q3H05XJ2R39WET6B4X';
That should tell you if the application NeoDB is looking for actually exists. If that returns nothing, you could also try:
select * from applications where name like '%neo%';
That may end up matching a different client ID. If that returns nothing, then it seems the signup flow never completed successfully.
In both cases, clearing the cookies for neodb.social (or trying it in a Private Browsing tab) should resolve the issue. Once you've done that, make sure you initiate the login using the host domain, not the account domain.
from gotosocial.
Best I can tell, there's no issue with Phanpy. It just doesn't have the heuristics to detect the split-account setup that some clients have, but GtS can't do anything about that.
Which leaves NeoDB. Given the oauth error, there's probably two queries worth running using the
sqlite3
CLI:select * from applications where id = '01D5AV31Q3H05XJ2R39WET6B4X';That should tell you if the application NeoDB is looking for actually exists. If that returns nothing, you could also try:
select * from applications where name like '%neo%';That may end up matching a different client ID. If that returns nothing, then it seems the signup flow never completed successfully.
In both cases, clearing the cookies for neodb.social (or trying it in a Private Browsing tab) should resolve the issue. Once you've done that, make sure you initiate the login using the host domain, not the account domain.
I tried to do a query based on your tips and there are two data about neodb in the database, do I need to delete them and start over?
sqlite> select * from applications where name like '%neo%'
...> ;
019VV28ZJ90Y59TZ76WCH2HTCT|2024-04-15 05:21:34|2024-04-15 05:21:34|NeoDB|https://neodb.social|https://neodb.social/account/login/oauth|01E09RTY8EGAT5EPQZ9A801SYY|ddde0df2-4b9e-4221-a971-17358a6f1d48|read:accounts read:follows read:search read:blocks read:mutes write:statuses write:media
01WNHFYJ3KAXH903N2BDS1E8DP|2024-04-15 05:21:35|2024-04-15 05:21:35|NeoDB|https://neodb.social|https://neodb.social/account/login/oauth|01N5XBFMEKHJEXGWBGZ4DCD4NC|630fdc13-b30b-4600-805f-2d6dc38b5a23|read:accounts read:follows read:search read:blocks read:mutes write:statuses write:media
Also, if I log in to Phanpy using the host domain it works fine, based on your reply it looks like there's no way to log in using the account domain (I was kinda hoping to be able to log in through the account domain, that way the account would look a bit cleaner)
from gotosocial.
It's odd to see two applications having been created within a second of each other. Would suggest something did go wrong.
You shouldn't need to delete those two applications, but you can since they're probably not working at all.
The usual query for that is
DELETE FROM applications WHERE id = '019VV28ZJ90Y59TZ76WCH2HTCT';
Or alternatively:
DELETE FROM applications WHERE name LIKE '%neo%';
I would suggest to wait for @tsmethurst to chime in with anything else before modifying the database though.
from gotosocial.
You should be wary when deleting applications because there are cases where the remote software stores + reuses the application, rather than creating a new one every login. Elk does this, for example, so that if you delete the application in your GtS database that Elk created, next time you try to log into your instance with Elk, the login will fail because Elk reuses the application it's got stored on its own side.
Before doing any manual tinkering in your database, it would be a good idea to ask the maintainers of NeoDB if they store + reuse applications per instance, and if there's any method of wiping applications from their side so that you can try fresh.
Relevant Elk issues: elk-zone/elk#2562, elk-zone/elk#2422, elk-zone/elk#2279
from gotosocial.
^^ The above is why I was asking if you'd logged in to NeoDB from that domain before and possibly already deleted the app by resetting your database or something.
from gotosocial.
@daenney @tsmethurst Thank you, after redeployment yesterday, I can log in now. It seems that I can only log in using the host domain at the moment。
from gotosocial.
Cool. The host domain thing is expected. Clients need to do a bit of work to detect a split domain setup. We've got all the bits and pieces for that in place the same way that Mastodon does and it works correctly for a number of clients that implement those checks. There's nothing more we can do there, beyond individual clients implementing those checks so they always initiate login from the host domain.
from gotosocial.
Related Issues (20)
- [Frontend HTML Markup] Add specific body classes to different frontend pages HOT 1
- Separate storage configuration for media caching HOT 1
- [feature] Domain names as usernames HOT 4
- [performance/chore] Update local + federated (public) timelines to use `internal/timeline`
- [bug] Delivery goroutines experienced a panic with "not yet initialized" while executing CLI commands HOT 1
- [bug] fedilab shows error after boosting post HOT 7
- [bug] twblue and possibly software based around mastodon.pi doesn't work HOT 6
- [bug] Remote edits of media descriptions are not applied HOT 1
- [bug] Unable to interact with ktistec users HOT 2
- [bug] Duplicate boost notifications HOT 6
- [feature] Remove the `quote-inline` class from statuses HOT 5
- [bug/frontend] Custom emoji shortcode is not changed after addition/changed input file HOT 1
- [feature] Expose Mastodon API compatible version and identify platform as GotoSocial in the version string HOT 7
- [bug] "sql: no rows in result set" when attempting to accept an incoming follow request HOT 4
- [bug] External Users can still see followings/followers of a follow-hiddened account HOT 4
- [bug] Posting undo of a "like" to the inbox may result in 500 internal server error HOT 1
- [chore/frontend] Refactor layout + styling for consistency
- We're on holiday from May 8th up to and including May 26th
- [bug] filters don’t seem to always work HOT 7
- [feature] Search within bookmarks (and possibly own likes/boosts) HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gotosocial.