sora: fix bilibili

This commit is contained in:
hexated 2023-05-09 13:54:20 +07:00
parent 6cd8128eba
commit 78c4b58edf
4 changed files with 13 additions and 98 deletions

View file

@ -1,7 +1,7 @@
import org.jetbrains.kotlin.konan.properties.Properties import org.jetbrains.kotlin.konan.properties.Properties
// use an integer for version numbers // use an integer for version numbers
version = 127 version = 128
android { android {
defaultConfig { defaultConfig {

View file

@ -889,9 +889,9 @@ object SoraExtractor : SoraStream() {
{ {
invokeBiliBili(aniId, episode, subtitleCallback, callback) invokeBiliBili(aniId, episode, subtitleCallback, callback)
}, },
{ // {
if (season != null) invokeAllanime(aniId, title, jpTitle, episode, callback) // if (season != null) invokeAllanime(aniId, title, jpTitle, episode, callback)
} // }
) )
} }
@ -976,25 +976,25 @@ object SoraExtractor : SoraStream() {
subtitleCallback: (SubtitleFile) -> Unit, subtitleCallback: (SubtitleFile) -> Unit,
callback: (ExtractorLink) -> Unit callback: (ExtractorLink) -> Unit
) { ) {
val res = app.get("$biliBiliAPI/anime/episodes?id=$aniId&source_id=bilibili") val res = app.get("$biliBiliAPI/anime/episodes?id=$aniId&source_id=bilibili", referer = kaguyaBaseUrl)
.parsedSafe<BiliBiliDetails>()?.episodes?.find { .parsedSafe<BiliBiliDetails>()?.episodes?.find {
it.episodeNumber == episode it.episodeNumber == episode
} ?: return } ?: return
val sources = val sources =
app.get("$biliBiliAPI/source?episode_id=${res.sourceEpisodeId}&source_media_id=${res.sourceMediaId}&source_id=${res.sourceId}") app.get("$biliBiliAPI/source?episode_id=${res.sourceEpisodeId}&source_media_id=${res.sourceMediaId}&source_id=${res.sourceId}", referer = kaguyaBaseUrl)
.parsedSafe<BiliBiliSourcesResponse>() .parsedSafe<BiliBiliSourcesResponse>()
sources?.sources?.apmap { source -> sources?.sources?.apmap { source ->
val quality = val quality =
app.get(source.file ?: return@apmap null).document.selectFirst("Representation") app.get(source.file ?: return@apmap null, referer = kaguyaBaseUrl).document.selectFirst("Representation")
?.attr("height") ?.attr("height")
callback.invoke( callback.invoke(
ExtractorLink( ExtractorLink(
"BiliBili", "BiliBili",
"BiliBili", "BiliBili",
source.file, source.file,
"", kaguyaBaseUrl,
quality?.toIntOrNull() ?: Qualities.Unknown.value, quality?.toIntOrNull() ?: Qualities.Unknown.value,
isDash = true isDash = true
) )

View file

@ -109,8 +109,8 @@ open class SoraStream : TmdbProvider() {
const val fdMoviesAPI = "https://freedrivemovie.lol" const val fdMoviesAPI = "https://freedrivemovie.lol"
const val m4uhdAPI = "https://m4uhd.tv" const val m4uhdAPI = "https://m4uhd.tv"
const val tvMoviesAPI = "https://www.tvseriesnmovies.com" const val tvMoviesAPI = "https://www.tvseriesnmovies.com"
const val moviezAddAPI = "https://45.143.223.244" const val moviezAddAPI = "https://ww1.moviezaddiction.click"
const val bollyMazaAPI = "https://b.bloginguru.info" const val bollyMazaAPI = "https://ww1.bollymaza.click"
const val moviesbayAPI = "https://moviesbay.live" const val moviesbayAPI = "https://moviesbay.live"
const val rStreamAPI = "https://remotestre.am" const val rStreamAPI = "https://remotestre.am"
const val flixonAPI = "https://flixon.ru" const val flixonAPI = "https://flixon.ru"
@ -131,8 +131,6 @@ open class SoraStream : TmdbProvider() {
const val rinzryMoviesAPI = "https://rinzry.stream/0:" const val rinzryMoviesAPI = "https://rinzry.stream/0:"
const val codexMoviesAPI = "https://packs.codexcloudx.tech/0:" const val codexMoviesAPI = "https://packs.codexcloudx.tech/0:"
const val edithxMoviesAPI = "https://index.edithx.ga/0:" const val edithxMoviesAPI = "https://index.edithx.ga/0:"
const val papaonMovies1API = "https://m.papaonwork.workers.dev/0:"
const val papaonMovies2API = "https://m.papaonwork.workers.dev/1:"
const val dahmerMoviesAPI = "https://edytjedhgmdhm.abfhaqrhbnf.workers.dev" const val dahmerMoviesAPI = "https://edytjedhgmdhm.abfhaqrhbnf.workers.dev"
const val jmdkhMovieAPI = "https://tg.jmdkh.eu.org/0:" const val jmdkhMovieAPI = "https://tg.jmdkh.eu.org/0:"
const val rubyMovieAPI = "https://upload.rubyshare111.workers.dev/0:" const val rubyMovieAPI = "https://upload.rubyshare111.workers.dev/0:"
@ -150,6 +148,8 @@ open class SoraStream : TmdbProvider() {
const val xtremeMoviesAPI = "https://kartik19.xtrememirror0.workers.dev/0:" // dead const val xtremeMoviesAPI = "https://kartik19.xtrememirror0.workers.dev/0:" // dead
const val tgarMovieAPI = "https://tgarchive.eu.org" // dead const val tgarMovieAPI = "https://tgarchive.eu.org" // dead
const val baymoviesAPI = "https://opengatewayindex.pages.dev" // dead const val baymoviesAPI = "https://opengatewayindex.pages.dev" // dead
const val papaonMovies1API = "https://m.papaonwork.workers.dev/0:" // dead
const val papaonMovies2API = "https://m.papaonwork.workers.dev/1:" // dead
fun getType(t: String?): TvType { fun getType(t: String?): TvType {
return when (t) { return when (t) {
@ -600,48 +600,6 @@ open class SoraStream : TmdbProvider() {
{ {
invokeSmashyStream(res.imdbId, res.season, res.episode, callback) invokeSmashyStream(res.imdbId, res.season, res.episode, callback)
}, },
// {
// if (!res.isAnime) invokeBaymovies(
// res.title,
// res.year,
// res.season,
// res.episode,
// callback
// )
// },
// {
// invokeChillmovies0(
// chillmovies0API,
// "Chillmovies0",
// res.title,
// res.year,
// res.season,
// res.episode,
// callback
// )
// },
// {
// invokeChillmovies1(
// chillmovies1API,
// "Chillmovies1",
// res.title,
// res.year,
// res.season,
// res.episode,
// callback
// )
// },
// {
// if (!res.isAnime) invokeGammovies(
// gamMoviesAPI,
// "GamMovies",
// res.title,
// res.year,
// res.season,
// res.episode,
// callback
// )
// },
{ {
invokeWatchsomuch( invokeWatchsomuch(
res.imdbId, res.imdbId,
@ -670,17 +628,6 @@ open class SoraStream : TmdbProvider() {
callback callback
) )
}, },
// {
// if (!res.isAnime) invokeJsmovies(
// jsMoviesAPI,
// "JSMovies",
// res.title,
// res.year,
// res.season,
// res.episode,
// callback
// )
// },
{ {
invokeRinzrymovies( invokeRinzrymovies(
rinzryMoviesAPI, rinzryMoviesAPI,
@ -716,39 +663,6 @@ open class SoraStream : TmdbProvider() {
"Basic ZWRpdGg6amFydmlz" "Basic ZWRpdGg6amFydmlz"
) )
}, },
// {
// if (!res.isAnime) invokeXtrememovies(
// xtremeMoviesAPI,
// "XtremeMovies",
// res.title,
// res.year,
// res.season,
// res.episode,
// callback
// )
// },
{
if (!res.isAnime) invokePapaonMovies1(
papaonMovies1API,
"PapaonMovies[1]",
res.title,
res.year,
res.season,
res.episode,
callback
)
},
{
if (!res.isAnime) invokePapaonMovies2(
papaonMovies2API,
"PapaonMovies[2]",
res.title,
res.year,
res.season,
res.episode,
callback
)
},
{ {
invokeDahmerMovies( invokeDahmerMovies(
res.title, res.title,

View file

@ -46,6 +46,7 @@ import kotlin.math.min
val soraAPI = base64DecodeAPI("cA==YXA=cy8=Y20=di8=LnQ=b2s=a2w=bG8=aS4=YXA=ZS0=aWw=b2I=LW0=Z2E=Ly8=czo=dHA=aHQ=") val soraAPI = base64DecodeAPI("cA==YXA=cy8=Y20=di8=LnQ=b2s=a2w=bG8=aS4=YXA=ZS0=aWw=b2I=LW0=Z2E=Ly8=czo=dHA=aHQ=")
val bflixChipperKey = base64DecodeAPI("Yjc=ejM=TzA=YTk=WHE=WnU=bXU=RFo=") val bflixChipperKey = base64DecodeAPI("Yjc=ejM=TzA=YTk=WHE=WnU=bXU=RFo=")
val bflixKey = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/" val bflixKey = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"
val kaguyaBaseUrl = "https://kaguya.app/"
val soraHeaders = mapOf( val soraHeaders = mapOf(
"lang" to "en", "lang" to "en",
"versioncode" to "33", "versioncode" to "33",