aboutsummaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
authorAnthony Wang2023-01-18 06:23:36 +0000
committerAnthony Wang2023-01-18 06:23:36 +0000
commita2e773ebd1a64ac67479ceb05ee3836957ac0e7b (patch)
treed332f5a166ec4064b6245914bc1a9cdd83d2a41f /README.md
parentf4631349520ae823843ae5f5f3adda42ad047fae (diff)
Add latest working code
Diffstat (limited to 'README.md')
-rw-r--r--README.md16
1 files changed, 8 insertions, 8 deletions
diff --git a/README.md b/README.md
index b70d965..cee60f6 100644
--- a/README.md
+++ b/README.md
@@ -2,11 +2,9 @@
Fuwuqi (fúwùqì or 服务器 means "server" in Chinese) is a useless C2S ActivityPub server for "extremely hardcore" ActivityPub enthusiasts. Craft your own exquisite WebFinger response! Customize your actor object exactly like you want! Hack and extend the 100-line Python server code!
-If that sounds like a world of pain, close this webpage now... OK, got that out of the way. Time for some fun!
-
## Configuration
-First, clone this repo on your server.
+First, clone this repo on your server and your client device.
Now, generate an RSA keypair on your client device:
```bash
@@ -14,22 +12,24 @@ openssl genrsa -out private.pem 2048
openssl rsa -in private.pem -outform PEM -pubout -out public.pem
```
-Rename `users/test.jsonld` to your username and pop it open in your favorite text editor. You should change `0.exozy.me` to match your server's domain name, `test` to your username, and the `publicKeyPem` field to the public key you just generated.
+On the server, rename `users/test.jsonld` to your username and pop it open in your favorite text editor. You should change `0.exozy.me` to match your server's domain name, `test` to your username, and the `publicKeyPem` field to the public key you just generated.
-Onward! Now open `.well-known/webfinger` in your editor, and modify it similarly.
+Onward! Now open `.well-known/webfinger` in your editor, and modify it similarly. Finally, open `server.py` and update the domain, obviously.
That wasn't so bad, was it? (sobbing sounds)
## Usage
-Alright, time for the real deal. Start up `python main.py` on your server. If you want to customize the port or whatever, just change the source code.
+Alright, time for the real deal. Start up `python server.py` on your server. If you want to customize the port or whatever, just change the source code.
-Now on your client device, open up your favorite C2S ActivityPub client... oh wait... there aren't any! Welp, you'll just have to settle for reading the [AP spec](https://www.w3.org/TR/activitypub/), writing some homemade JSON, and figuring out how `python client.py` works.
+Now on your client device, open up your favorite C2S ActivityPub client... oh wait... there aren't any! Welp, you'll just have to settle for reading the [AP spec](https://www.w3.org/TR/activitypub/), writing some homemade JSON, and figuring out how `python client.py` works. That's rough, buddy. You'll have to learn how to manually write `Note`s, manually accept follow requests, and more! You can find some examples in this repo. HTTP signatures are generated client-side, for no good reason other than it works. If you want to view your unread messages, just `curl` your inbox. Easy as that.
-Like and subscribe and enjoy your new "extremely hardcore" ActivityPub server!!! 🎉😎🚀🙃🥳
+Enjoy your new "extremely hardcore" ActivityPub server!!! 🎉😎🚀🙃🥳
## Resources
- https://www.w3.org/TR/activitypub/
- https://blog.joinmastodon.org/2018/06/how-to-implement-a-basic-activitypub-server/
- https://blog.joinmastodon.org/2018/07/how-to-make-friends-and-verify-requests/
+- https://docs.joinmastodon.org/spec/
+- https://socialhub.activitypub.rocks/t/python-mastodon-server-post-with-http-signature/2757