aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnthony Wang2022-06-17 11:56:44 -0500
committerAnthony Wang2022-06-17 11:56:44 -0500
commit1e563ece83c854677407917caecc5d2785f6d7b8 (patch)
treecf075591056ec9d27d927d4c6877ccb05dba2d85
parenta8dea646a06bdfb1585abc156f6727f2729cd876 (diff)
parent7446583a0d760605bb6cfb12a6a5890ea58adec3 (diff)
Merge branch 'feature-activitypub' into feature-go-ap-inbox-outbox
-rw-r--r--go.mod6
-rw-r--r--go.sum12
-rw-r--r--modules/activitypub/client.go1
-rw-r--r--modules/activitypub/send.go2
4 files changed, 9 insertions, 12 deletions
diff --git a/go.mod b/go.mod
index 8e5871cfb..5a133ce7f 100644
--- a/go.mod
+++ b/go.mod
@@ -27,7 +27,7 @@ require (
github.com/emirpasic/gods v1.18.1
github.com/ethantkoenig/rupture v1.0.1
github.com/gliderlabs/ssh v0.3.4
- github.com/go-ap/activitypub v0.0.0-20220606130025-d23c21aea068
+ github.com/go-ap/activitypub v0.0.0-20220615144428-48208c70483b
github.com/go-chi/chi/v5 v5.0.7
github.com/go-chi/cors v1.2.1
github.com/go-enry/go-enry/v2 v2.8.2
@@ -161,8 +161,8 @@ require (
github.com/fsnotify/fsnotify v1.5.4 // indirect
github.com/fullstorydev/grpcurl v1.8.1 // indirect
github.com/fxamacker/cbor/v2 v2.4.0 // indirect
- github.com/go-ap/errors v0.0.0-20220529131844-4c7dbeabb369 // indirect
- github.com/go-ap/jsonld v0.0.0-20200327122108-fafac2de2660 // indirect
+ github.com/go-ap/errors v0.0.0-20220615144307-e8bc4a40ae9f // indirect
+ github.com/go-ap/jsonld v0.0.0-20220615144122-1d862b15410d // indirect
github.com/go-asn1-ber/asn1-ber v1.5.4 // indirect
github.com/go-enry/go-oniguruma v1.2.1 // indirect
github.com/go-git/gcfg v1.5.0 // indirect
diff --git a/go.sum b/go.sum
index db7044c1a..cf311199c 100644
--- a/go.sum
+++ b/go.sum
@@ -460,12 +460,12 @@ github.com/globalsign/mgo v0.0.0-20180905125535-1ca0a4f7cbcb/go.mod h1:xkRDCp4j0
github.com/globalsign/mgo v0.0.0-20181015135952-eeefdecb41b8/go.mod h1:xkRDCp4j0OGD1HRkm4kmhM+pmpv3AKq5SU7GMg4oO/Q=
github.com/glycerine/go-unsnap-stream v0.0.0-20181221182339-f9677308dec2/go.mod h1:/20jfyN9Y5QPEAprSgKAUr+glWDY39ZiUEAYOEv5dsE=
github.com/glycerine/goconvey v0.0.0-20190410193231-58a59202ab31/go.mod h1:Ogl1Tioa0aV7gstGFO7KhffUsb9M4ydbEbbxpcEDc24=
-github.com/go-ap/activitypub v0.0.0-20220606130025-d23c21aea068 h1:Xzxc/HjHFAwJTieEWcC1SjBHVBq+Y1xPgk7WWcG3sjs=
-github.com/go-ap/activitypub v0.0.0-20220606130025-d23c21aea068/go.mod h1:h5U5YGW+z4mVF3XH6bKfBmsJinRVuKpS23uYqJfGSbo=
-github.com/go-ap/errors v0.0.0-20220529131844-4c7dbeabb369 h1:z09Qf9XB5lU3NBZnrsN9VJqrIgwKLrsBVUgrir4zL9A=
-github.com/go-ap/errors v0.0.0-20220529131844-4c7dbeabb369/go.mod h1:yENIaXEY5AiFL/qGTBBcPuk40I5SLyZzwrQj2ID5PHQ=
-github.com/go-ap/jsonld v0.0.0-20200327122108-fafac2de2660 h1:AUG8+r0Q/zbNUAi5CWVBK5oUhOZDX3Kkr+oWURaJIfU=
-github.com/go-ap/jsonld v0.0.0-20200327122108-fafac2de2660/go.mod h1:jyveZeGw5LaADntW+UEsMjl3IlIwk+DxlYNsbofQkGA=
+github.com/go-ap/activitypub v0.0.0-20220615144428-48208c70483b h1:+RjYfEfoZdM3wHFs752dlOpGaoRhwRRyQxjajg08LcQ=
+github.com/go-ap/activitypub v0.0.0-20220615144428-48208c70483b/go.mod h1:DE3vvc6Didgfd3k7M1Mos6qMDFNmMrxJmYVMHG9h9Io=
+github.com/go-ap/errors v0.0.0-20220615144307-e8bc4a40ae9f h1:kJhGo4NApJP0Lt9lkJnfmuTnRWVFbCynY0kiTxpPUR4=
+github.com/go-ap/errors v0.0.0-20220615144307-e8bc4a40ae9f/go.mod h1:KHkKFKZvc05lr79+RGoq/zG8YjWi3+FK60Bxd+mpCew=
+github.com/go-ap/jsonld v0.0.0-20220615144122-1d862b15410d h1:Z/oRXMlZHjvjIqDma1FrIGL3iE5YL7MUI0bwYEZ6qbA=
+github.com/go-ap/jsonld v0.0.0-20220615144122-1d862b15410d/go.mod h1:jyveZeGw5LaADntW+UEsMjl3IlIwk+DxlYNsbofQkGA=
github.com/go-asn1-ber/asn1-ber v1.5.4 h1:vXT6d/FNDiELJnLb6hGNa309LMsrCoYFvpwHDF0+Y1A=
github.com/go-asn1-ber/asn1-ber v1.5.4/go.mod h1:hEBeB/ic+5LoWskz+yKT7vGhhPYkProFKoKdwZRWMe0=
github.com/go-chi/chi/v5 v5.0.1/go.mod h1:DslCQbL2OYiznFReuXYUmQ2hGd1aDpCnlMNITLSKoi8=
diff --git a/modules/activitypub/client.go b/modules/activitypub/client.go
index 46b8c675b..923bc4ea4 100644
--- a/modules/activitypub/client.go
+++ b/modules/activitypub/client.go
@@ -103,7 +103,6 @@ func (c *Client) NewRequest(b []byte, to string) (req *http.Request, err error)
return
}
req.Header.Add("Content-Type", ActivityStreamsContentType)
- req.Header.Add("Accept-Charset", "utf-8")
req.Header.Add("Date", CurrentTime())
signer, _, err := httpsig.NewSigner(c.algs, c.digestAlg, c.postHeaders, httpsig.Signature, httpsigExpirationTime)
if err != nil {
diff --git a/modules/activitypub/send.go b/modules/activitypub/send.go
index 4b8e580bf..70f1c7089 100644
--- a/modules/activitypub/send.go
+++ b/modules/activitypub/send.go
@@ -22,8 +22,6 @@ import (
func Fetch(iri *url.URL) (b []byte, err error) {
req := httplib.NewRequest(iri.String(), http.MethodGet)
req.Header("Accept", ActivityStreamsContentType)
- req.Header("Accept-Charset", "utf-8")
- req.Header("Date", CurrentTime())
resp, err := req.Response()
if err != nil {
return