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

Can't follow blog on Federation after reinstalling #152

Closed
ghost opened this issue Aug 4, 2019 · 4 comments
Closed

Can't follow blog on Federation after reinstalling #152

ghost opened this issue Aug 4, 2019 · 4 comments

Comments

@ghost
Copy link

ghost commented Aug 4, 2019

Describe the bug

After reinstalling my WF blog, I am unable to follow it via Mastodon. The profile does appear, although it appears as the old profile before I reinstalled, and only says 'Follow Requested' when trying to follow. Blog is lexserv.xyz, and the profile is located at @alex@lexserv.xyz.

Did try to change the address of the blog from lexserv.xyz to lexserv.xyz/, but it then didn't appear.

Steps to reproduce (if necessary)

Steps to reproduce the behavior:
Find blog on Mastodon, click 'Follow'

Expected behavior

What should've happened?
I should be able to follow the blog.

Application configuration

  • Single mode or Multi-user mode?
    Single
  • Database? [mysql/sqlite]
    SQLite
  • Open registration? [yes/no]
    No
  • Federation enabled? [yes/no]
    Yes

Version or last commit:
0.10.0

@thebaer
Copy link
Member

thebaer commented Aug 4, 2019

To help debug, can you do the following?

  • run the server with the --debug flag
  • from Mastodon, unfollow and follow the blog
  • include the full server logs around those requests here

@ghost
Copy link
Author

ghost commented Aug 4, 2019

Here's the full text from starting the server, cancelling my follow request then attempting to follow again.

2019/08/04 13:01:41 Loading config.ini configuration...
2019/08/04 13:01:41 Loading templates...
2019/08/04 13:01:41   templates/base.tmpl
2019/08/04 13:01:41   templates/collection-post.tmpl
2019/08/04 13:01:41   templates/collection-tags.tmpl
2019/08/04 13:01:41   templates/collection.tmpl
2019/08/04 13:01:41   templates/edit-meta.tmpl
2019/08/04 13:01:41   templates/pad.tmpl
2019/08/04 13:01:41   templates/password-collection.tmpl
2019/08/04 13:01:41   templates/post.tmpl
2019/08/04 13:01:41   templates/read.tmpl
2019/08/04 13:01:41 Loading pages...
2019/08/04 13:01:41   [404-general.tmpl] pages/404-general.tmpl
2019/08/04 13:01:41   [404.tmpl] pages/404.tmpl
2019/08/04 13:01:41   [410.tmpl] pages/410.tmpl
2019/08/04 13:01:41   [500.tmpl] pages/500.tmpl
2019/08/04 13:01:41   [about.tmpl] pages/about.tmpl
2019/08/04 13:01:41   [blank.tmpl] pages/blank.tmpl
2019/08/04 13:01:41   [landing.tmpl] pages/landing.tmpl
2019/08/04 13:01:41   [login.tmpl] pages/login.tmpl
2019/08/04 13:01:41   [privacy.tmpl] pages/privacy.tmpl
2019/08/04 13:01:41   [signup.tmpl] pages/signup.tmpl
2019/08/04 13:01:41 Loading user pages...
2019/08/04 13:01:41   [user/pages.tmpl] templates/user/admin/pages.tmpl
2019/08/04 13:01:41   [user/users.tmpl] templates/user/admin/users.tmpl
2019/08/04 13:01:41   [user/view-page.tmpl] templates/user/admin/view-page.tmpl
2019/08/04 13:01:41   [user/view-user.tmpl] templates/user/admin/view-user.tmpl
2019/08/04 13:01:41   [user/admin.tmpl] templates/user/admin.tmpl
2019/08/04 13:01:41   [user/articles.tmpl] templates/user/articles.tmpl
2019/08/04 13:01:41   [user/collection.tmpl] templates/user/collection.tmpl
2019/08/04 13:01:41   [user/collections.tmpl] templates/user/collections.tmpl
2019/08/04 13:01:41   [user/export.tmpl] templates/user/export.tmpl
2019/08/04 13:01:41   [user/footer.tmpl] templates/user/include/footer.tmpl
2019/08/04 13:01:41   [user/header.tmpl] templates/user/include/header.tmpl
2019/08/04 13:01:41   [user/invite.tmpl] templates/user/invite.tmpl
2019/08/04 13:01:41   [user/settings.tmpl] templates/user/settings.tmpl
2019/08/04 13:01:41   [user/stats.tmpl] templates/user/stats.tmpl
2019/08/04 13:01:41 Loading encryption keys...
2019/08/04 13:01:41   keys/email.aes256
2019/08/04 13:01:41   keys/cookies_auth.aes256
2019/08/04 13:01:41   keys/cookies_enc.aes256
2019/08/04 13:01:41 Connecting to sqlite3 database...
2019/08/04 13:01:41 Adding {domain} routes (single user)...
2019/08/04 13:01:41 Going to serve...
2019/08/04 13:01:41 Serving on http://localhost:8080
2019/08/04 13:01:41 ---
2019/08/04 13:01:52 Rec'd! "POST /api/collections/alex/inbox HTTP/1.1\r\nHost: lexserv.xyz\r\nAccept-Encoding: gzip\r\nConnection: Keep-Alive\r\nContent-Length: 374\r\nContent-Type: application/activity+json\r\nDate: Sun, 04 Aug 2019 13:01:51 GMT\r\nDigest: SHA-256=jGHXvb985NMge4TCrtvv5ZqOrrQFFA61YPpAnnss8PI=\r\nSignature: keyId=\"https://fosstodon.org/users/lexservxyz#main-key\",algorithm=\"rsa-sha256\",headers=\"(request-target) host date digest content-type\",signature=\"YxsG4S/sEG1n1Ffx2GhYwJd06J8Xmbf7gtsPTIkxzjIUk9jIU43mrx3awQHvILqYsVQddOdzVKkQFd2OMN0s5I5Tkyhb/VbwZnlTXecdX0PLloVAHV30Ub05z8NoBzbkkjvfWMCd3KIs6UuUWwCo3q1aiXn+sUOo1K7DuJXhI8oxN5aN0NP5OsmDv/Fg1V01xoEf2orpCVSBZx4yhRXbRXjslL5zbRws1bQRkB1i3htGkcyzeYhtudNZ8osHn2KhTcV/0CF8pKteu5CEb3hcHkUOxtY1gl/K1OipdXaXUDWJ+07bLip8EGWGcL501imXHN17dlVG62Mn2ylfh23D/g==\"\r\nUser-Agent: http.rb/3.3.0 (Mastodon/2.9.2; +https://fosstodon.org/)\r\nX-Forwarded-For: 51.38.62.175\r\nX-Forwarded-Host: lexserv.xyz\r\nX-Forwarded-Server: lexserv.xyz\r\n\r\n{\"@context\":\"https://www.w3.org/ns/activitystreams\",\"id\":\"https://fosstodon.org/users/lexservxyz#follows/96059/undo\",\"type\":\"Undo\",\"actor\":\"https://fosstodon.org/users/lexservxyz\",\"object\":{\"id\":\"https://fosstodon.org/386eca0d-87aa-41be-9ffa-ac15dd30fd0d\",\"type\":\"Follow\",\"actor\":\"https://fosstodon.org/users/lexservxyz\",\"object\":\"https://lexserv.xyz/api/collections/alex\"}}"
2019/08/04 13:01:52 Undo: {"@context":["https://www.w3.org/ns/activitystreams"],"actor":"https://fosstodon.org/users/lexservxyz","id":"https://fosstodon.org/users/lexservxyz#follows/96059/undo","object":{"actor":"https://fosstodon.org/users/lexservxyz","id":"https://fosstodon.org/386eca0d-87aa-41be-9ffa-ac15dd30fd0d","object":"https://lexserv.xyz/api/collections/alex","type":"Follow"},"type":"Undo"}
2019/08/04 13:01:52 "POST /api/collections/alex/inbox" 200 663.991µs "http.rb/3.3.0 (Mastodon/2.9.2; +https://fosstodon.org/)"
2019/08/04 13:01:54 POST https://fosstodon.org/users/lexservxyz/inbox
2019/08/04 13:01:54 POST /users/lexservxyz/inbox HTTP/1.1
Host: fosstodon.org
User-Agent: Go (WriteFreely/0.10.0; +https://lexserv.xyz)
Content-Length: 416
Content-Type: application/activity+json
Date: Sun, 04 Aug 2019 13:01:54 GMT
Digest: SHA-256=xn6HM52TR7/uSAFdOqaXAiYfqwWcQViKiy0OFJRwxCU=
Signature: keyId="https://lexserv.xyz/api/collections/alex#main-key",algorithm="rsa-sha256",headers="(request-target) date host digest",signature="IuT8iP44NSHW8r6L0iOrbqW6MdIdPW3KTm/g2fM5FzPOztWsywiTkQgZeShc4/tqFqFwEOYDg4RJPYp2nl2mstUu0mSnLk4mM2ltvNT9KiMO/buxNcFVDjTRR/is64F+3+ltFzt5cmeprwmXnoL4j3q8LO0G7fRcKwhC8eXKiT1dFXaNnNCyuKU0x5NQRqBFu+EGQXYug3aUGUz3MwaFDDc4TGxwwxKzMwolfGcr8tyeG4PvEzeDCNee3Bjv7uAiZU4MmTe7XJmmvO53KiFB0zKrIAwRlTfGonnMg+bUfJurUxA/CEGQ90C+63vKFR54jO3tUSj2ifgNxSSSGWBgoQ=="
Accept-Encoding: gzip

{"@context":["https://www.w3.org/ns/activitystreams"],"actor":null,"object":{"actor":"https://fosstodon.org/users/lexservxyz","id":"https://fosstodon.org/users/lexservxyz#follows/96059/undo","object":{"actor":"https://fosstodon.org/users/lexservxyz","id":"https://fosstodon.org/386eca0d-87aa-41be-9ffa-ac15dd30fd0d","object":"https://lexserv.xyz/api/collections/alex","type":"Follow"},"type":"Undo"},"type":"Accept"}
2019/08/04 13:01:54 "GET /.well-known/webfinger?resource=acct:alex@lexserv.xyz" 401 7.352µs "http.rb/3.3.0 (Mastodon/2.9.2; +https://fosstodon.org/)"
2019/08/04 13:01:54 "GET /login?to=/.well-known/webfinger%3Fresource%3Dacct%3Aalex%40lexserv.xyz" 200 598.278µs "http.rb/3.3.0 (Mastodon/2.9.2; +https://fosstodon.org/)"
2019/08/04 13:01:54 Status  : 401 Unauthorized
2019/08/04 13:01:54 Response: Public key not found for key https://lexserv.xyz/api/collections/alex#main-key
2019/08/04 13:02:03 Rec'd! "POST /api/collections/alex/inbox HTTP/1.1\r\nHost: lexserv.xyz\r\nAccept-Encoding: gzip\r\nConnection: Keep-Alive\r\nContent-Length: 235\r\nContent-Type: application/activity+json\r\nDate: Sun, 04 Aug 2019 13:02:02 GMT\r\nDigest: SHA-256=skgXlSqEvQdaH5griwfJRvrTX7A7gUNgYT5m0OJnzTA=\r\nSignature: keyId=\"https://fosstodon.org/users/lexservxyz#main-key\",algorithm=\"rsa-sha256\",headers=\"(request-target) host date digest content-type\",signature=\"RUzimO3y4C49JYMxp7AdFyepx0KK/LNMO8aPN7a36Xzmcm9YARH3I2CR6ZQnLGS+ZAD2xmOqOP3PN0cKLk8bXP9U2y6moU9uP2upMUgbPDvRGatRea3KkuStZ3qun8OGgCpGHjZH7BTtalTyDOivfRSth/mkbGLWEQASSJf9sRcYPpH+cApT3n/52gfjGLVIybb6sDiHWsXZyEm0opzkKMiK+uKKg7GKPIq/eS9jycNYMflDJ10elH7WDXDsMd2HAKrD0ClGqVJZRxyNn2T+VGVUMuagq8so2cLeji6k/VSobUh7UnEp1Mdbg/QcM3B9kwnhBq8Q6B6RL0d9v09WVw==\"\r\nUser-Agent: http.rb/3.3.0 (Mastodon/2.9.2; +https://fosstodon.org/)\r\nX-Forwarded-For: 51.38.62.175\r\nX-Forwarded-Host: lexserv.xyz\r\nX-Forwarded-Server: lexserv.xyz\r\n\r\n{\"@context\":\"https://www.w3.org/ns/activitystreams\",\"id\":\"https://fosstodon.org/d42820b0-d20a-4b7b-a6e3-b1a9d3a6b32b\",\"type\":\"Follow\",\"actor\":\"https://fosstodon.org/users/lexservxyz\",\"object\":\"https://lexserv.xyz/api/collections/alex\"}"
2019/08/04 13:02:03 Follow: {"@context":["https://www.w3.org/ns/activitystreams"],"actor":"https://fosstodon.org/users/lexservxyz","id":"https://fosstodon.org/d42820b0-d20a-4b7b-a6e3-b1a9d3a6b32b","object":"https://lexserv.xyz/api/collections/alex","type":"Follow"}
2019/08/04 13:02:03 Fetching actor https://fosstodon.org/users/lexservxyz locally
2019/08/04 13:02:03 "POST /api/collections/alex/inbox" 200 873.177µs "http.rb/3.3.0 (Mastodon/2.9.2; +https://fosstodon.org/)"
2019/08/04 13:02:05 POST https://fosstodon.org/users/lexservxyz/inbox
2019/08/04 13:02:05 POST /users/lexservxyz/inbox HTTP/1.1
Host: fosstodon.org
User-Agent: Go (WriteFreely/0.10.0; +https://lexserv.xyz)
Content-Length: 391
Content-Type: application/activity+json
Date: Sun, 04 Aug 2019 13:02:05 GMT
Digest: SHA-256=/01WLgM50dwFliSw1t7jLZwysVCVWuZVvcKUcILz/5M=
Signature: keyId="https://lexserv.xyz/api/collections/alex#main-key",algorithm="rsa-sha256",headers="(request-target) date host digest",signature="tRFnQDIo+DijZ+czurZfcKql+bG1XJ2G2hJFAb24BAmOI7XJ7T1s+DYwiqL1H5PSl84WFHYnTEVjwev1Z7+0HQSCOiz+8Jua+ZdwlJHymTpCq2hyfAyDoSl/RcInRpTt61GaIA2S/X0mskf+gW0h1GuR5XsgDBPM6yVX86fvpwXxhaOlHGIGGDmjw03n/uIMzZNHc0nlcTlTQtIXVRwSXMcwPhHb6Y2wiiYaticEfp3FpoKmcLeT1sWUgy1kJlwWzPScJULPK+jwKHIpmtW2hzjIS8KpJ4QY5JbIWuR5DDF7HTeA7Cs1PuSwiCUfPj7ycXgW9pCAUbPaMLQsNkznQg=="
Accept-Encoding: gzip

{"@context":["https://www.w3.org/ns/activitystreams"],"actor":"https://lexserv.xyz/api/collections/alex","id":"https://lexserv.xyz/api/collections/alex#accept-tjp8moa1pggq8f4fkegm","object":{"actor":"https://fosstodon.org/users/lexservxyz","id":"https://fosstodon.org/d42820b0-d20a-4b7b-a6e3-b1a9d3a6b32b","object":"https://lexserv.xyz/api/collections/alex","type":"Follow"},"type":"Accept"}
2019/08/04 13:02:05 "GET /.well-known/webfinger?resource=acct:alex@lexserv.xyz" 401 21.635µs "http.rb/3.3.0 (Mastodon/2.9.2; +https://fosstodon.org/)"
2019/08/04 13:02:05 "GET /login?to=/.well-known/webfinger%3Fresource%3Dacct%3Aalex%40lexserv.xyz" 200 219.618µs "http.rb/3.3.0 (Mastodon/2.9.2; +https://fosstodon.org/)"
2019/08/04 13:02:05 Status  : 401 Unauthorized
2019/08/04 13:02:05 Response: Public key not found for key https://lexserv.xyz/api/collections/alex#main-key

These two bottom lines seem to indicate some sort of authorization issue. What is needing authorised, and how do I go about allowing it?

@thebaer
Copy link
Member

thebaer commented Aug 4, 2019

The 401 is from Mastodon -- it isn't accepting the request because the keypair for your @alex@lexserv.xyz account doesn't match the one that fosstodon.org first encountered.

If you still have data from the first time you installed WF, I can help you migrate your keys to your current install. Otherwise the way to solve this would be to have your Mastodon instance admin delete the @alex@lexserv.xyz account, and then searching for the current account and following it should work.

I'll close this since it isn't a bug, but feel free to continue the conversation.

@thebaer thebaer closed this as completed Aug 4, 2019
@ghost
Copy link
Author

ghost commented Aug 4, 2019

Thanks for that @thebaer ! No data saved from the old installation, so have contacted the admins of Fosstodon to delete the account.

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

No branches or pull requests

1 participant