-
Notifications
You must be signed in to change notification settings - Fork 127
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #124 from movie-web/dev
2.2.5 Primewire, updated providers
- Loading branch information
Showing
32 changed files
with
690 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,7 @@ | ||
import { inspect } from 'node:util'; | ||
|
||
export function logDeepObject(object: Record<any, any>) { | ||
// This is the dev cli, so we can use console.log | ||
// eslint-disable-next-line no-console | ||
console.log(inspect(object, { showHidden: false, depth: null, colors: true })); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
import { flags } from '@/entrypoint/utils/targets'; | ||
import { makeEmbed } from '@/providers/base'; | ||
|
||
export const streamtapeScraper = makeEmbed({ | ||
id: 'streamtape', | ||
name: 'Streamtape', | ||
rank: 160, | ||
async scrape(ctx) { | ||
const embed = await ctx.proxiedFetcher<string>(ctx.url); | ||
|
||
const match = embed.match(/robotlink'\).innerHTML = (.*)'/); | ||
if (!match) throw new Error('No match found'); | ||
|
||
const [fh, sh] = match?.[1]?.split("+ ('") ?? []; | ||
if (!fh || !sh) throw new Error('No match found'); | ||
|
||
const url = `https:${fh?.replace(/'/g, '').trim()}${sh?.substring(3).trim()}`; | ||
|
||
return { | ||
stream: [ | ||
{ | ||
id: 'primary', | ||
type: 'file', | ||
flags: [flags.CORS_ALLOWED, flags.IP_LOCKED], | ||
captions: [], | ||
qualities: { | ||
unknown: { | ||
type: 'mp4', | ||
url, | ||
}, | ||
}, | ||
headers: { | ||
Referer: 'https://streamtape.com', | ||
}, | ||
}, | ||
], | ||
}; | ||
}, | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
import * as unpacker from 'unpacker'; | ||
|
||
import { flags } from '@/entrypoint/utils/targets'; | ||
import { makeEmbed } from '@/providers/base'; | ||
|
||
const packedRegex = /(eval\(function\(p,a,c,k,e,d\).*\)\)\))/; | ||
const linkRegex = /src:"(https:\/\/[^"]+)"/; | ||
|
||
export const streamvidScraper = makeEmbed({ | ||
id: 'streamvid', | ||
name: 'Streamvid', | ||
rank: 215, | ||
async scrape(ctx) { | ||
// Example url: https://streamvid.net/fu1jaf96vofx | ||
const streamRes = await ctx.proxiedFetcher<string>(ctx.url); | ||
const packed = streamRes.match(packedRegex); | ||
|
||
if (!packed) throw new Error('streamvid packed not found'); | ||
|
||
const unpacked = unpacker.unpack(packed[1]); | ||
const link = unpacked.match(linkRegex); | ||
|
||
if (!link) throw new Error('streamvid link not found'); | ||
return { | ||
stream: [ | ||
{ | ||
type: 'hls', | ||
id: 'primary', | ||
playlist: link[1], | ||
flags: [flags.CORS_ALLOWED], | ||
captions: [], | ||
}, | ||
], | ||
}; | ||
}, | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
import { flags } from '@/entrypoint/utils/targets'; | ||
import { makeEmbed } from '@/providers/base'; | ||
|
||
const linkRegex = /'hls': ?'(http.*?)',/; | ||
|
||
export const voeScraper = makeEmbed({ | ||
id: 'voe', | ||
name: 'voe.sx', | ||
rank: 180, | ||
async scrape(ctx) { | ||
const embed = await ctx.proxiedFetcher<string>(ctx.url); | ||
|
||
const playerSrc = embed.match(linkRegex) ?? []; | ||
|
||
const streamUrl = playerSrc[1]; | ||
if (!streamUrl) throw new Error('Stream url not found in embed code'); | ||
|
||
return { | ||
stream: [ | ||
{ | ||
type: 'hls', | ||
id: 'primary', | ||
playlist: streamUrl, | ||
flags: [flags.CORS_ALLOWED], | ||
captions: [], | ||
headers: { | ||
Referer: 'https://voe.sx', | ||
}, | ||
}, | ||
], | ||
}; | ||
}, | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
export const primewireBase = 'https://www.primewire.tf'; | ||
export const primewireApiKey = atob('bHpRUHNYU0tjRw=='); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
# Maintaining decryption | ||
|
||
This folder contains the decryption logic for the primewire provider | ||
|
||
The code in `blowfish.ts` is a de-obfuscated version of the original code that is used to decrypt the video links. You can find original the code [in this JavaScript file](https://www.primewire.tf/js/app-21205005105979fb964d17bf03570023.js?vsn=d]) by searching for the keyword "sBox0". | ||
|
||
The code is minified, so use prettier to deobfuscate it. In the case that the URL changes, you can find it used in the [primewire homepage](https://www.primewire.tf/). |
Oops, something went wrong.