$ git log --oneline --no-merges d866ba75dd0f.. $
httpsig dependency is a few commits behind.
$ git log --oneline --no-merges c2de3672e5b5.. 5583674 (HEAD -> master, origin/master, origin/HEAD) Add badge for Matrix chat room 83c3d4b Add badges to the README 2a46c50 Add travis.yml dda7895 Propagate error message for verifier when crypto algo not supported aaea07e Have test temporarily pass due to SHA1 inclusion 7240195 Propagate error when crypto algorithm is not supported 38d4006 Match on prefix for certificates 17ff967 Add RSA support to ssh key signing 03551c9 Add initial support for using ssh keys for signing 79a5cc3 Add ed25519 signing support 3123872 Fix a typo in two error messages c6fcdaf Make tests work again d7a8424 (tag: v1.0.0) Ran go fmt 44df666 Ran go mod tidy 338f1ed hide real algorithm 9b1ac95 add checks for created and expires 123cce4 add ecdsa support 1583536 add support for created and expires values 0ef2856 Verify signatures with Host header f4c3604 Fix hashing sum bug for digests
- FederatingDB that uses the underlying DB interface to implement the go-fed pub.Database interface.
- Clock implements the Clock interface of go-fed.
- federator which is used as the first two arguments when calling newFederatingActor and is expected to implement both pub.CommonBehavior and pub.FederatingProtocol.
pub.CommonBehavior implementation is a noop as explain in the following comment:
// IMPLEMENTATION NOTE: For GoToSocial, we serve GETS to outboxes and inboxes through // the CLIENT API, not through the federation API, so we just do nothing here.
pub.FederatingProtocol is implemented.
When the GotToSocial server boots, it creates a FederatingActor which is given to a newly created Processor which gives it to a newly created account processor, providing the account.Processor interface and stores the FederatingActor for later use.
processor method InboxPost is called, it adds the processor.fromFederator channel to the context and delegates the action to FederatingActor which will further delegate it to the go-fed actor InboxPost method.
Messages are added to the fromFederator channel by various methods of the federatingDB instance (which implements pub.Database from go-fed, as shown above). For instance when processing vocab.ActivityStreamsAccept (by overriding the go-fed default) it ultimately creates a message.FromFederator and send it to the fromFederator channel.
Another example is the pub.Database Create method which retrieves information from the Context (receivingAccount and requestingAccount) passed along to (for instance) the activityCreate method which may use it to create a note and ultimately stores it in the database and sends a message.FromFederator to the channel.