diff options
author | mira.bat <97340105+irafire@users.noreply.github.com> | 2023-07-27 17:01:15 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-07-27 17:01:15 +0200 |
commit | f862be2749b4f2d8dee99128d7e3064a69920e11 (patch) | |
tree | 20643166e07cb31ca3e0d05b4490000150b2f1c4 /server/tests/api | |
parent | 787d822cd471d1e4bd5a37c687c78cd5f69d8645 (diff) | |
download | PeerTube-f862be2749b4f2d8dee99128d7e3064a69920e11.tar.gz PeerTube-f862be2749b4f2d8dee99128d7e3064a69920e11.tar.zst PeerTube-f862be2749b4f2d8dee99128d7e3064a69920e11.zip |
Add an option to sign federated fetches for mastodon compatibility (#5898)
* Fix player error modal
Not hidden when we change the video
* Correctly dispose player components
* Sign cross-server fetch requests for mastodon AUTHORIZED_FETCH compatibilty
* Add a remote fetch sign configuration knob
* Federated fetches refactoring
---------
Co-authored-by: Chocobozzz <me@florianbigard.com>
Co-authored-by: ira <ira@foxgirl.space>
Diffstat (limited to 'server/tests/api')
-rw-r--r-- | server/tests/api/activitypub/security.ts | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/server/tests/api/activitypub/security.ts b/server/tests/api/activitypub/security.ts index 31ebc89b4..8e87361a9 100644 --- a/server/tests/api/activitypub/security.ts +++ b/server/tests/api/activitypub/security.ts | |||
@@ -58,7 +58,7 @@ async function makeFollowRequest (to: { url: string }, by: { url: string, privat | |||
58 | authorizationHeaderName: HTTP_SIGNATURE.HEADER_NAME, | 58 | authorizationHeaderName: HTTP_SIGNATURE.HEADER_NAME, |
59 | keyId: by.url, | 59 | keyId: by.url, |
60 | key: by.privateKey, | 60 | key: by.privateKey, |
61 | headers: HTTP_SIGNATURE.HEADERS_TO_SIGN | 61 | headers: HTTP_SIGNATURE.HEADERS_TO_SIGN_WITH_PAYLOAD |
62 | } | 62 | } |
63 | const headers = { | 63 | const headers = { |
64 | 'digest': buildDigest(body), | 64 | 'digest': buildDigest(body), |
@@ -82,7 +82,7 @@ describe('Test ActivityPub security', function () { | |||
82 | authorizationHeaderName: HTTP_SIGNATURE.HEADER_NAME, | 82 | authorizationHeaderName: HTTP_SIGNATURE.HEADER_NAME, |
83 | keyId: 'acct:peertube@' + servers[1].host, | 83 | keyId: 'acct:peertube@' + servers[1].host, |
84 | key: keys.privateKey, | 84 | key: keys.privateKey, |
85 | headers: HTTP_SIGNATURE.HEADERS_TO_SIGN | 85 | headers: HTTP_SIGNATURE.HEADERS_TO_SIGN_WITH_PAYLOAD |
86 | }) | 86 | }) |
87 | 87 | ||
88 | // --------------------------------------------------------------- | 88 | // --------------------------------------------------------------- |