mirror of
https://codeberg.org/yeentown/barkey.git
synced 2025-07-07 12:36:57 +00:00
add same-authority check between fetched note and summary url
This commit is contained in:
parent
633718ffe9
commit
1ac9625eea
1 changed files with 1 additions and 1 deletions
|
@ -297,7 +297,7 @@ export class UrlPreviewService {
|
||||||
// Finally, attempt a signed GET in case it's a direct link to an instance with authorized fetch.
|
// Finally, attempt a signed GET in case it's a direct link to an instance with authorized fetch.
|
||||||
const instanceActor = await this.systemAccountService.getInstanceActor();
|
const instanceActor = await this.systemAccountService.getInstanceActor();
|
||||||
const remoteObject = await this.apRequestService.signedGet(summary.url, instanceActor).catch(() => null);
|
const remoteObject = await this.apRequestService.signedGet(summary.url, instanceActor).catch(() => null);
|
||||||
if (remoteObject) {
|
if (remoteObject && this.apUtilityService.haveSameAuthority(remoteObject.id, summary.url)) {
|
||||||
summary.activityPub = remoteObject.id;
|
summary.activityPub = remoteObject.id;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue