aboutsummaryrefslogtreecommitdiff
path: root/outboxPost.go
diff options
context:
space:
mode:
Diffstat (limited to 'outboxPost.go')
-rw-r--r--outboxPost.go6
1 files changed, 6 insertions, 0 deletions
diff --git a/outboxPost.go b/outboxPost.go
index 774ac62..5772932 100644
--- a/outboxPost.go
+++ b/outboxPost.go
@@ -512,6 +512,12 @@ func CheckCaptcha(db *sql.DB, captcha string) bool {
func ParseInboxRequest(w http.ResponseWriter, r *http.Request, db *sql.DB) {
activity := GetActivityFromJson(r, db)
+
+ if activity.Actor.PublicKey.Id == "" {
+ nActor := FingerActor(activity.Actor.Id)
+ activity.Actor = &nActor
+ }
+
if !VerifyHeaderSignature(r, *activity.Actor) {
response := RejectActivity(activity)
MakeActivityRequest(db, response)