KekikStream 2.2.3__py3-none-any.whl → 2.2.5__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- KekikStream/Extractors/CloseLoad.py +7 -8
- KekikStream/Extractors/Filemoon.py +7 -6
- KekikStream/Extractors/MolyStream.py +6 -5
- KekikStream/Extractors/VidHide.py +0 -1
- KekikStream/Extractors/VidMoly.py +17 -9
- KekikStream/Plugins/BelgeselX.py +39 -20
- KekikStream/Plugins/DiziBox.py +115 -59
- KekikStream/Plugins/DiziPal.py +87 -40
- KekikStream/Plugins/DiziYou.py +105 -64
- KekikStream/Plugins/Dizilla.py +57 -28
- KekikStream/Plugins/FilmBip.py +60 -31
- KekikStream/Plugins/FilmMakinesi.py +75 -51
- KekikStream/Plugins/FilmModu.py +73 -36
- KekikStream/Plugins/FullHDFilm.py +82 -48
- KekikStream/Plugins/FullHDFilmizlesene.py +94 -39
- KekikStream/Plugins/HDFilmCehennemi.py +78 -53
- KekikStream/Plugins/JetFilmizle.py +78 -50
- KekikStream/Plugins/KultFilmler.py +64 -34
- KekikStream/Plugins/RoketDizi.py +43 -26
- KekikStream/Plugins/SelcukFlix.py +27 -14
- KekikStream/Plugins/SetFilmIzle.py +69 -43
- KekikStream/Plugins/SezonlukDizi.py +102 -46
- KekikStream/Plugins/Sinefy.py +130 -101
- KekikStream/Plugins/SinemaCX.py +82 -37
- KekikStream/Plugins/Sinezy.py +61 -47
- KekikStream/Plugins/SuperFilmGeldi.py +72 -36
- KekikStream/Plugins/UgurFilm.py +72 -34
- KekikStream/requirements.txt +1 -1
- {kekikstream-2.2.3.dist-info → kekikstream-2.2.5.dist-info}/METADATA +2 -2
- {kekikstream-2.2.3.dist-info → kekikstream-2.2.5.dist-info}/RECORD +34 -34
- {kekikstream-2.2.3.dist-info → kekikstream-2.2.5.dist-info}/WHEEL +0 -0
- {kekikstream-2.2.3.dist-info → kekikstream-2.2.5.dist-info}/entry_points.txt +0 -0
- {kekikstream-2.2.3.dist-info → kekikstream-2.2.5.dist-info}/licenses/LICENSE +0 -0
- {kekikstream-2.2.3.dist-info → kekikstream-2.2.5.dist-info}/top_level.txt +0 -0
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
# Bu araç @keyiflerolsun tarafından | @KekikAkademi için yazılmıştır.
|
|
2
2
|
|
|
3
|
-
from KekikStream.Core
|
|
4
|
-
from Kekik.Sifreleme
|
|
5
|
-
from
|
|
3
|
+
from KekikStream.Core import ExtractorBase, ExtractResult, Subtitle
|
|
4
|
+
from Kekik.Sifreleme import Packer, StreamDecoder
|
|
5
|
+
from selectolax.parser import HTMLParser
|
|
6
6
|
import re
|
|
7
7
|
|
|
8
8
|
class CloseLoadExtractor(ExtractorBase):
|
|
@@ -17,16 +17,16 @@ class CloseLoadExtractor(ExtractorBase):
|
|
|
17
17
|
istek.raise_for_status()
|
|
18
18
|
|
|
19
19
|
# Video URL'sini çıkar
|
|
20
|
-
eval_func = re.compile(r'\s*(eval\(function[\s\S].*)
|
|
20
|
+
eval_func = re.compile(r'\s*(eval\(function[\s\S].*)').findall(istek.text)[0]
|
|
21
21
|
m3u_link = StreamDecoder.extract_stream_url(Packer.unpack(eval_func))
|
|
22
22
|
|
|
23
23
|
# Subtitle'ları parse et (Kotlin referansı: track elementleri)
|
|
24
24
|
subtitles = []
|
|
25
|
-
secici =
|
|
25
|
+
secici = HTMLParser(istek.text)
|
|
26
26
|
for track in secici.css("track"):
|
|
27
|
-
raw_src = track.
|
|
27
|
+
raw_src = track.attrs.get("src") or ""
|
|
28
28
|
raw_src = raw_src.strip()
|
|
29
|
-
label = track.
|
|
29
|
+
label = track.attrs.get("label") or track.attrs.get("srclang") or "Altyazı"
|
|
30
30
|
|
|
31
31
|
if raw_src:
|
|
32
32
|
full_url = raw_src if raw_src.startswith("http") else f"{self.main_url}{raw_src}"
|
|
@@ -38,4 +38,3 @@ class CloseLoadExtractor(ExtractorBase):
|
|
|
38
38
|
referer = self.main_url,
|
|
39
39
|
subtitles = subtitles
|
|
40
40
|
)
|
|
41
|
-
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
# Bu araç @keyiflerolsun tarafından | @KekikAkademi için yazılmıştır.
|
|
2
2
|
|
|
3
|
-
from KekikStream.Core
|
|
4
|
-
from Kekik.Sifreleme
|
|
5
|
-
from
|
|
3
|
+
from KekikStream.Core import ExtractorBase, ExtractResult
|
|
4
|
+
from Kekik.Sifreleme import Packer
|
|
5
|
+
from selectolax.parser import HTMLParser
|
|
6
6
|
import re
|
|
7
7
|
|
|
8
8
|
class Filemoon(ExtractorBase):
|
|
@@ -33,10 +33,11 @@ class Filemoon(ExtractorBase):
|
|
|
33
33
|
# İlk sayfayı al
|
|
34
34
|
istek = await self.httpx.get(url)
|
|
35
35
|
response = istek.text
|
|
36
|
-
secici =
|
|
36
|
+
secici = HTMLParser(response)
|
|
37
37
|
|
|
38
38
|
# Eğer iframe varsa, iframe'e git
|
|
39
|
-
|
|
39
|
+
iframe_el = secici.css_first("iframe")
|
|
40
|
+
iframe_src = iframe_el.attrs.get("src") if iframe_el else None
|
|
40
41
|
if iframe_src:
|
|
41
42
|
iframe_url = self.fix_url(iframe_src)
|
|
42
43
|
self.httpx.headers.update({
|
|
@@ -52,7 +53,7 @@ class Filemoon(ExtractorBase):
|
|
|
52
53
|
if Packer.detect_packed(response):
|
|
53
54
|
try:
|
|
54
55
|
unpacked = Packer.unpack(response)
|
|
55
|
-
# sources:[{file:"
|
|
56
|
+
# sources:[{file:"...» pattern'ını ara
|
|
56
57
|
if match := re.search(r'sources:\s*\[\s*\{\s*file:\s*"([^"]+)"', unpacked):
|
|
57
58
|
m3u8_url = match.group(1)
|
|
58
59
|
elif match := re.search(r'file:\s*"([^"]*?\.m3u8[^"]*)"', unpacked):
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# Bu araç @keyiflerolsun tarafından | @KekikAkademi için yazılmıştır.
|
|
2
2
|
|
|
3
|
-
from KekikStream.Core
|
|
4
|
-
from
|
|
3
|
+
from KekikStream.Core import ExtractorBase, ExtractResult, Subtitle
|
|
4
|
+
from selectolax.parser import HTMLParser
|
|
5
5
|
import re
|
|
6
6
|
|
|
7
7
|
class MolyStream(ExtractorBase):
|
|
@@ -10,8 +10,9 @@ class MolyStream(ExtractorBase):
|
|
|
10
10
|
|
|
11
11
|
async def extract(self, url, referer=None) -> ExtractResult:
|
|
12
12
|
if "doctype html" in url:
|
|
13
|
-
secici
|
|
14
|
-
|
|
13
|
+
secici = HTMLParser(url)
|
|
14
|
+
video_el = secici.css_first("video#sheplayer source")
|
|
15
|
+
video = video_el.attrs.get("src") if video_el else None
|
|
15
16
|
else:
|
|
16
17
|
video = url
|
|
17
18
|
|
|
@@ -28,7 +29,7 @@ class MolyStream(ExtractorBase):
|
|
|
28
29
|
return ExtractResult(
|
|
29
30
|
name = self.name,
|
|
30
31
|
url = video,
|
|
31
|
-
referer = video.replace("/sheila", ""),
|
|
32
|
+
referer = video.replace("/sheila", "") if video else None,
|
|
32
33
|
user_agent = "Mozilla/5.0 (X11; Linux x86_64; rv:101.0) Gecko/20100101 Firefox/101.0",
|
|
33
34
|
subtitles = subtitles
|
|
34
35
|
)
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
# Bu araç @keyiflerolsun tarafından | @KekikAkademi için yazılmıştır.
|
|
2
2
|
# ! https://github.com/recloudstream/cloudstream/blob/master/library/src/commonMain/kotlin/com/lagradost/cloudstream3/extractors/Vidmoly.kt
|
|
3
3
|
|
|
4
|
-
from KekikStream.Core
|
|
5
|
-
from
|
|
4
|
+
from KekikStream.Core import ExtractorBase, ExtractResult, Subtitle
|
|
5
|
+
from selectolax.parser import HTMLParser
|
|
6
6
|
import re, contextlib, json
|
|
7
7
|
|
|
8
8
|
class VidMoly(ExtractorBase):
|
|
@@ -29,16 +29,24 @@ class VidMoly(ExtractorBase):
|
|
|
29
29
|
# VidMoly bazen redirect ediyor, takip et
|
|
30
30
|
response = await self.httpx.get(url, follow_redirects=True)
|
|
31
31
|
if "Select number" in response.text:
|
|
32
|
-
secici =
|
|
32
|
+
secici = HTMLParser(response.text)
|
|
33
|
+
|
|
34
|
+
op_el = secici.css_first("input[name='op']")
|
|
35
|
+
file_code_el = secici.css_first("input[name='file_code']")
|
|
36
|
+
answer_el = secici.css_first("div.vhint b")
|
|
37
|
+
ts_el = secici.css_first("input[name='ts']")
|
|
38
|
+
nonce_el = secici.css_first("input[name='nonce']")
|
|
39
|
+
ctok_el = secici.css_first("input[name='ctok']")
|
|
40
|
+
|
|
33
41
|
response = await self.httpx.post(
|
|
34
42
|
url = url,
|
|
35
43
|
data = {
|
|
36
|
-
"op" :
|
|
37
|
-
"file_code" :
|
|
38
|
-
"answer" :
|
|
39
|
-
"ts" :
|
|
40
|
-
"nonce" :
|
|
41
|
-
"ctok" :
|
|
44
|
+
"op" : op_el.attrs.get("value") if op_el else None,
|
|
45
|
+
"file_code" : file_code_el.attrs.get("value") if file_code_el else None,
|
|
46
|
+
"answer" : answer_el.text(strip=True) if answer_el else None,
|
|
47
|
+
"ts" : ts_el.attrs.get("value") if ts_el else None,
|
|
48
|
+
"nonce" : nonce_el.attrs.get("value") if nonce_el else None,
|
|
49
|
+
"ctok" : ctok_el.attrs.get("value") if ctok_el else None
|
|
42
50
|
},
|
|
43
51
|
follow_redirects=True
|
|
44
52
|
)
|
KekikStream/Plugins/BelgeselX.py
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# Bu araç @keyiflerolsun tarafından | @KekikAkademi için yazılmıştır.
|
|
2
2
|
|
|
3
|
-
from KekikStream.Core
|
|
4
|
-
from
|
|
3
|
+
from KekikStream.Core import PluginBase, MainPageResult, SearchResult, SeriesInfo, Episode, ExtractResult
|
|
4
|
+
from selectolax.parser import HTMLParser
|
|
5
5
|
import re
|
|
6
6
|
|
|
7
7
|
class BelgeselX(PluginBase):
|
|
@@ -43,19 +43,27 @@ class BelgeselX(PluginBase):
|
|
|
43
43
|
|
|
44
44
|
async def get_main_page(self, page: int, url: str, category: str) -> list[MainPageResult]:
|
|
45
45
|
istek = self.cloudscraper.get(f"{url}{page}")
|
|
46
|
-
secici =
|
|
46
|
+
secici = HTMLParser(istek.text)
|
|
47
47
|
|
|
48
48
|
results = []
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
poster =
|
|
49
|
+
# xpath kullanamıyoruz, en üst seviye gen-movie-contain'leri alıp içlerinden bilgileri çekelim
|
|
50
|
+
for container in secici.css("div.gen-movie-contain"):
|
|
51
|
+
# Poster için img'i container'ın içinden alalım
|
|
52
|
+
img_el = container.css_first("div.gen-movie-img img")
|
|
53
|
+
poster = img_el.attrs.get("src") if img_el else None
|
|
54
|
+
|
|
55
|
+
# Title ve href için gen-movie-info
|
|
56
|
+
h3_link = container.css_first("div.gen-movie-info h3 a")
|
|
57
|
+
if not h3_link:
|
|
58
|
+
continue
|
|
59
|
+
|
|
60
|
+
title = h3_link.text(strip=True)
|
|
61
|
+
href = h3_link.attrs.get("href")
|
|
54
62
|
|
|
55
63
|
if title and href:
|
|
56
64
|
results.append(MainPageResult(
|
|
57
65
|
category = category,
|
|
58
|
-
title = self._to_title_case(title
|
|
66
|
+
title = self._to_title_case(title),
|
|
59
67
|
url = self.fix_url(href),
|
|
60
68
|
poster = self.fix_url(poster) if poster else None
|
|
61
69
|
))
|
|
@@ -117,15 +125,20 @@ class BelgeselX(PluginBase):
|
|
|
117
125
|
|
|
118
126
|
async def load_item(self, url: str) -> SeriesInfo:
|
|
119
127
|
istek = await self.httpx.get(url)
|
|
120
|
-
secici =
|
|
128
|
+
secici = HTMLParser(istek.text)
|
|
129
|
+
|
|
130
|
+
title_el = secici.css_first("h2.gen-title")
|
|
131
|
+
title = title_el.text(strip=True) if title_el else None
|
|
132
|
+
|
|
133
|
+
poster_el = secici.css_first("div.gen-tv-show-top img")
|
|
134
|
+
poster = poster_el.attrs.get("src") if poster_el else None
|
|
121
135
|
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
description = secici.css("div.gen-single-tv-show-info p::text").get()
|
|
136
|
+
desc_el = secici.css_first("div.gen-single-tv-show-info p")
|
|
137
|
+
description = desc_el.text(strip=True) if desc_el else None
|
|
125
138
|
|
|
126
139
|
tags = []
|
|
127
140
|
for tag_link in secici.css("div.gen-socail-share a[href*='belgeselkanali']"):
|
|
128
|
-
tag_href = tag_link.
|
|
141
|
+
tag_href = tag_link.attrs.get("href")
|
|
129
142
|
if tag_href:
|
|
130
143
|
tag_name = tag_href.rsplit("/", 1)[-1].replace("-", " ")
|
|
131
144
|
tags.append(self._to_title_case(tag_name))
|
|
@@ -133,13 +146,19 @@ class BelgeselX(PluginBase):
|
|
|
133
146
|
episodes = []
|
|
134
147
|
counter = 0
|
|
135
148
|
for ep_item in secici.css("div.gen-movie-contain"):
|
|
136
|
-
|
|
137
|
-
|
|
149
|
+
ep_link = ep_item.css_first("div.gen-movie-info h3 a")
|
|
150
|
+
if not ep_link:
|
|
151
|
+
continue
|
|
152
|
+
|
|
153
|
+
ep_name = ep_link.text(strip=True)
|
|
154
|
+
ep_href = ep_link.attrs.get("href")
|
|
138
155
|
|
|
139
156
|
if not ep_name or not ep_href:
|
|
140
157
|
continue
|
|
141
158
|
|
|
142
|
-
|
|
159
|
+
meta_el = ep_item.css_first("div.gen-single-meta-holder ul li")
|
|
160
|
+
season_text = meta_el.text(strip=True) if meta_el else ""
|
|
161
|
+
|
|
143
162
|
episode_match = re.search(r"Bölüm (\d+)", season_text)
|
|
144
163
|
season_match = re.search(r"Sezon (\d+)", season_text)
|
|
145
164
|
|
|
@@ -151,15 +170,15 @@ class BelgeselX(PluginBase):
|
|
|
151
170
|
episodes.append(Episode(
|
|
152
171
|
season = ep_season,
|
|
153
172
|
episode = ep_episode,
|
|
154
|
-
title = ep_name
|
|
173
|
+
title = ep_name,
|
|
155
174
|
url = self.fix_url(ep_href)
|
|
156
175
|
))
|
|
157
176
|
|
|
158
177
|
return SeriesInfo(
|
|
159
178
|
url = url,
|
|
160
179
|
poster = self.fix_url(poster) if poster else None,
|
|
161
|
-
title = self._to_title_case(title
|
|
162
|
-
description = description
|
|
180
|
+
title = self._to_title_case(title) if title else None,
|
|
181
|
+
description = description,
|
|
163
182
|
tags = tags,
|
|
164
183
|
episodes = episodes
|
|
165
184
|
)
|
KekikStream/Plugins/DiziBox.py
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
# Bu araç @keyiflerolsun tarafından | @KekikAkademi için yazılmıştır.
|
|
2
2
|
|
|
3
|
-
from KekikStream.Core
|
|
4
|
-
from Kekik.Sifreleme
|
|
5
|
-
from
|
|
3
|
+
from KekikStream.Core import PluginBase, MainPageResult, SearchResult, SeriesInfo, Episode, ExtractResult
|
|
4
|
+
from Kekik.Sifreleme import CryptoJS
|
|
5
|
+
from selectolax.parser import HTMLParser
|
|
6
6
|
import re, urllib.parse, base64, contextlib, asyncio, time
|
|
7
7
|
|
|
8
8
|
class DiziBox(PluginBase):
|
|
@@ -49,17 +49,26 @@ class DiziBox(PluginBase):
|
|
|
49
49
|
url = f"{url.replace('SAYFA', str(page))}",
|
|
50
50
|
follow_redirects = True
|
|
51
51
|
)
|
|
52
|
-
secici =
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
)
|
|
61
|
-
|
|
62
|
-
|
|
52
|
+
secici = HTMLParser(istek.text)
|
|
53
|
+
|
|
54
|
+
results = []
|
|
55
|
+
for veri in secici.css("article.detailed-article"):
|
|
56
|
+
h3_link = veri.css_first("h3 a")
|
|
57
|
+
img_el = veri.css_first("img")
|
|
58
|
+
|
|
59
|
+
title = h3_link.text(strip=True) if h3_link else None
|
|
60
|
+
href = h3_link.attrs.get("href") if h3_link else None
|
|
61
|
+
poster = img_el.attrs.get("src") if img_el else None
|
|
62
|
+
|
|
63
|
+
if title and href:
|
|
64
|
+
results.append(MainPageResult(
|
|
65
|
+
category = category,
|
|
66
|
+
title = title,
|
|
67
|
+
url = self.fix_url(href),
|
|
68
|
+
poster = self.fix_url(poster) if poster else None,
|
|
69
|
+
))
|
|
70
|
+
|
|
71
|
+
return results
|
|
63
72
|
|
|
64
73
|
async def search(self, query: str) -> list[SearchResult]:
|
|
65
74
|
self.httpx.cookies.update({
|
|
@@ -67,54 +76,92 @@ class DiziBox(PluginBase):
|
|
|
67
76
|
"dbxu" : str(time.time() * 1000).split(".")[0]
|
|
68
77
|
})
|
|
69
78
|
istek = await self.httpx.get(f"{self.main_url}/?s={query}")
|
|
70
|
-
secici =
|
|
79
|
+
secici = HTMLParser(istek.text)
|
|
80
|
+
|
|
81
|
+
results = []
|
|
82
|
+
for item in secici.css("article.detailed-article"):
|
|
83
|
+
h3_link = item.css_first("h3 a")
|
|
84
|
+
img_el = item.css_first("img")
|
|
71
85
|
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
86
|
+
title = h3_link.text(strip=True) if h3_link else None
|
|
87
|
+
href = h3_link.attrs.get("href") if h3_link else None
|
|
88
|
+
poster = img_el.attrs.get("src") if img_el else None
|
|
89
|
+
|
|
90
|
+
if title and href:
|
|
91
|
+
results.append(SearchResult(
|
|
92
|
+
title = title,
|
|
93
|
+
url = self.fix_url(href),
|
|
94
|
+
poster = self.fix_url(poster) if poster else None,
|
|
95
|
+
))
|
|
96
|
+
|
|
97
|
+
return results
|
|
80
98
|
|
|
81
99
|
async def load_item(self, url: str) -> SeriesInfo:
|
|
82
100
|
istek = await self.httpx.get(url)
|
|
83
|
-
secici =
|
|
101
|
+
secici = HTMLParser(istek.text)
|
|
102
|
+
|
|
103
|
+
title_el = secici.css_first("div.tv-overview h1 a")
|
|
104
|
+
title = title_el.text(strip=True) if title_el else None
|
|
105
|
+
|
|
106
|
+
poster_el = secici.css_first("div.tv-overview figure img")
|
|
107
|
+
poster = poster_el.attrs.get("src") if poster_el else None
|
|
84
108
|
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
year
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
109
|
+
desc_el = secici.css_first("div.tv-story p")
|
|
110
|
+
description = desc_el.text(strip=True) if desc_el else None
|
|
111
|
+
|
|
112
|
+
# year: re_first yerine re.search
|
|
113
|
+
year_el = secici.css_first("a[href*='/yil/']")
|
|
114
|
+
year_text = year_el.text(strip=True) if year_el else ""
|
|
115
|
+
year_match = re.search(r"(\d{4})", year_text)
|
|
116
|
+
year = year_match.group(1) if year_match else None
|
|
117
|
+
|
|
118
|
+
tags = [a.text(strip=True) for a in secici.css("a[href*='/tur/']") if a.text(strip=True)]
|
|
119
|
+
|
|
120
|
+
# rating: re_first yerine re.search
|
|
121
|
+
rating_el = secici.css_first("span.label-imdb b")
|
|
122
|
+
rating_text = rating_el.text(strip=True) if rating_el else ""
|
|
123
|
+
rating_match = re.search(r"[\d.,]+", rating_text)
|
|
124
|
+
rating = rating_match.group() if rating_match else None
|
|
125
|
+
|
|
126
|
+
actors = [a.text(strip=True) for a in secici.css("a[href*='/oyuncu/']") if a.text(strip=True)]
|
|
92
127
|
|
|
93
128
|
episodes = []
|
|
94
|
-
for
|
|
129
|
+
for sezon_link_el in secici.css("div#seasons-list a"):
|
|
130
|
+
sezon_link = sezon_link_el.attrs.get("href")
|
|
131
|
+
if not sezon_link:
|
|
132
|
+
continue
|
|
133
|
+
|
|
95
134
|
sezon_url = self.fix_url(sezon_link)
|
|
96
135
|
sezon_istek = await self.httpx.get(sezon_url)
|
|
97
|
-
sezon_secici =
|
|
136
|
+
sezon_secici = HTMLParser(sezon_istek.text)
|
|
98
137
|
|
|
99
138
|
for bolum in sezon_secici.css("article.grid-box"):
|
|
100
|
-
|
|
139
|
+
ep_link = bolum.css_first("div.post-title a")
|
|
140
|
+
if not ep_link:
|
|
141
|
+
continue
|
|
142
|
+
|
|
143
|
+
ep_title = ep_link.text(strip=True)
|
|
144
|
+
ep_href = ep_link.attrs.get("href")
|
|
145
|
+
|
|
146
|
+
# re_first yerine re.search
|
|
147
|
+
ep_title_text = ep_title or ""
|
|
148
|
+
season_match = re.search(r"(\d+)\. ?Sezon", ep_title_text)
|
|
149
|
+
episode_match = re.search(r"(\d+)\. ?Bölüm", ep_title_text)
|
|
101
150
|
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
ep_season = ep_secici.re_first(r"(\d+)\. ?Sezon")
|
|
105
|
-
ep_episode = ep_secici.re_first(r"(\d+)\. ?Bölüm")
|
|
151
|
+
ep_season = season_match.group(1) if season_match else None
|
|
152
|
+
ep_episode = episode_match.group(1) if episode_match else None
|
|
106
153
|
|
|
107
154
|
if ep_title and ep_href:
|
|
108
155
|
episodes.append(Episode(
|
|
109
156
|
season = ep_season,
|
|
110
157
|
episode = ep_episode,
|
|
111
158
|
title = ep_title,
|
|
112
|
-
url = ep_href,
|
|
159
|
+
url = self.fix_url(ep_href),
|
|
113
160
|
))
|
|
114
161
|
|
|
115
162
|
return SeriesInfo(
|
|
116
163
|
url = url,
|
|
117
|
-
poster = poster,
|
|
164
|
+
poster = self.fix_url(poster) if poster else None,
|
|
118
165
|
title = title,
|
|
119
166
|
description = description,
|
|
120
167
|
tags = tags,
|
|
@@ -137,20 +184,22 @@ class DiziBox(PluginBase):
|
|
|
137
184
|
iframe_link = iframe_link.replace("king.php?v=", "king.php?wmode=opaque&v=")
|
|
138
185
|
|
|
139
186
|
istek = await self.httpx.get(iframe_link)
|
|
140
|
-
secici =
|
|
141
|
-
|
|
187
|
+
secici = HTMLParser(istek.text)
|
|
188
|
+
iframe_el = secici.css_first("div#Player iframe")
|
|
189
|
+
iframe = iframe_el.attrs.get("src") if iframe_el else None
|
|
142
190
|
|
|
143
|
-
|
|
144
|
-
|
|
191
|
+
if iframe:
|
|
192
|
+
self.httpx.headers.update({"Referer": self.main_url})
|
|
193
|
+
istek = await self.httpx.get(iframe)
|
|
145
194
|
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
195
|
+
crypt_data = re.search(r"CryptoJS\.AES\.decrypt\(\"(.*)\",\"", istek.text)[1]
|
|
196
|
+
crypt_pass = re.search(r"\",\"(.*)\"\);", istek.text)[1]
|
|
197
|
+
decode = CryptoJS.decrypt(crypt_pass, crypt_data)
|
|
149
198
|
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
199
|
+
if video_match := re.search(r"file: '(.*)',", decode):
|
|
200
|
+
results.append(video_match[1])
|
|
201
|
+
else:
|
|
202
|
+
results.append(decode)
|
|
154
203
|
|
|
155
204
|
elif "/player/moly/moly.php" in iframe_link:
|
|
156
205
|
iframe_link = iframe_link.replace("moly.php?h=", "moly.php?wmode=opaque&h=")
|
|
@@ -163,8 +212,9 @@ class DiziBox(PluginBase):
|
|
|
163
212
|
decoded_atob = urllib.parse.unquote(atob_data[1])
|
|
164
213
|
str_atob = base64.b64decode(decoded_atob).decode("utf-8")
|
|
165
214
|
|
|
166
|
-
|
|
167
|
-
|
|
215
|
+
iframe_el = HTMLParser(str_atob).css_first("div#Player iframe")
|
|
216
|
+
if iframe_el:
|
|
217
|
+
results.append(iframe_el.attrs.get("src"))
|
|
168
218
|
|
|
169
219
|
break
|
|
170
220
|
|
|
@@ -176,10 +226,13 @@ class DiziBox(PluginBase):
|
|
|
176
226
|
|
|
177
227
|
async def load_links(self, url: str) -> list[ExtractResult]:
|
|
178
228
|
istek = await self.httpx.get(url)
|
|
179
|
-
secici =
|
|
229
|
+
secici = HTMLParser(istek.text)
|
|
180
230
|
|
|
181
231
|
results = []
|
|
182
|
-
|
|
232
|
+
main_iframe_el = secici.css_first("div#video-area iframe")
|
|
233
|
+
main_iframe = main_iframe_el.attrs.get("src") if main_iframe_el else None
|
|
234
|
+
|
|
235
|
+
if main_iframe:
|
|
183
236
|
if decoded := await self._iframe_decode(self.name, main_iframe, url):
|
|
184
237
|
for iframe in decoded:
|
|
185
238
|
data = await self.extract(iframe)
|
|
@@ -187,8 +240,8 @@ class DiziBox(PluginBase):
|
|
|
187
240
|
results.append(data)
|
|
188
241
|
|
|
189
242
|
for alternatif in secici.css("div.video-toolbar option[value]"):
|
|
190
|
-
alt_name = alternatif.
|
|
191
|
-
alt_link = alternatif.
|
|
243
|
+
alt_name = alternatif.text(strip=True)
|
|
244
|
+
alt_link = alternatif.attrs.get("value")
|
|
192
245
|
|
|
193
246
|
if not alt_link:
|
|
194
247
|
continue
|
|
@@ -197,8 +250,11 @@ class DiziBox(PluginBase):
|
|
|
197
250
|
alt_istek = await self.httpx.get(alt_link)
|
|
198
251
|
alt_istek.raise_for_status()
|
|
199
252
|
|
|
200
|
-
alt_secici =
|
|
201
|
-
|
|
253
|
+
alt_secici = HTMLParser(alt_istek.text)
|
|
254
|
+
alt_iframe_el = alt_secici.css_first("div#video-area iframe")
|
|
255
|
+
alt_iframe = alt_iframe_el.attrs.get("src") if alt_iframe_el else None
|
|
256
|
+
|
|
257
|
+
if alt_iframe:
|
|
202
258
|
if decoded := await self._iframe_decode(alt_name, alt_iframe, url):
|
|
203
259
|
for iframe in decoded:
|
|
204
260
|
data = await self.extract(iframe, prefix=alt_name)
|