From b8570bb560cfa1c2e74c92753fce85463d521b8c Mon Sep 17 00:00:00 2001 From: Ciarands <74070993+Ciarands@users.noreply.github.com> Date: Wed, 3 Apr 2024 15:47:55 +0100 Subject: [PATCH] Add referrer and origin to vidplay --- src/providers/embeds/vidplay/index.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/providers/embeds/vidplay/index.ts b/src/providers/embeds/vidplay/index.ts index f37054b..a2914ee 100644 --- a/src/providers/embeds/vidplay/index.ts +++ b/src/providers/embeds/vidplay/index.ts @@ -29,6 +29,7 @@ export const vidplayScraper = makeEmbed({ } const url = new URL(ctx.url); + console.log(url); const subtitlesLink = url.searchParams.get('sub.info'); const captions: Caption[] = []; if (subtitlesLink) { @@ -55,6 +56,10 @@ export const vidplayScraper = makeEmbed({ type: 'hls', playlist: source, flags: [flags.IP_LOCKED], + headers: { + Referer: url.origin, + Origin: url.origin, + }, captions, thumbnailTrack, },