aboutsummaryrefslogtreecommitdiffhomepage
path: root/shared/extra-utils
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2021-03-10 11:17:20 +0100
committerChocobozzz <me@florianbigard.com>2021-03-24 18:18:40 +0100
commite7053b1d9d7f77d0375155b38d3e845f2163ecd8 (patch)
treeb52375913c9b0352f5c765c40122cbbbc54bad13 /shared/extra-utils
parent266131e0ca2f2622bbb15299212f00b1efa36867 (diff)
downloadPeerTube-e7053b1d9d7f77d0375155b38d3e845f2163ecd8.tar.gz
PeerTube-e7053b1d9d7f77d0375155b38d3e845f2163ecd8.tar.zst
PeerTube-e7053b1d9d7f77d0375155b38d3e845f2163ecd8.zip
Fix AP security tests
Diffstat (limited to 'shared/extra-utils')
-rw-r--r--shared/extra-utils/requests/activitypub.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/shared/extra-utils/requests/activitypub.ts b/shared/extra-utils/requests/activitypub.ts
index 2a7f20289..ecd8ce823 100644
--- a/shared/extra-utils/requests/activitypub.ts
+++ b/shared/extra-utils/requests/activitypub.ts
@@ -17,7 +17,7 @@ function makePOSTAPRequest (url: string, body: any, httpSignature: any, headers:
17async function makeFollowRequest (to: { url: string }, by: { url: string, privateKey }) { 17async function makeFollowRequest (to: { url: string }, by: { url: string, privateKey }) {
18 const follow = { 18 const follow = {
19 type: 'Follow', 19 type: 'Follow',
20 id: by.url + '/toto', 20 id: by.url + '/' + new Date().getTime(),
21 actor: by.url, 21 actor: by.url,
22 object: to.url 22 object: to.url
23 } 23 }
@@ -33,7 +33,7 @@ async function makeFollowRequest (to: { url: string }, by: { url: string, privat
33 } 33 }
34 const headers = buildGlobalHeaders(body) 34 const headers = buildGlobalHeaders(body)
35 35
36 return makePOSTAPRequest(to.url, body, httpSignature, headers) 36 return makePOSTAPRequest(to.url + '/inbox', body, httpSignature, headers)
37} 37}
38 38
39export { 39export {