Compare commits
No commits in common. "311f30f8a93a2a2f74b4fa4d0f0d28110f9ecec0" and "7ebe8368ecef5034c967ebdf29ab1690e50e1c19" have entirely different histories.
311f30f8a9
...
7ebe8368ec
4 changed files with 967 additions and 1112 deletions
1032
M3U8/TV.m3u8
1032
M3U8/TV.m3u8
File diff suppressed because it is too large
Load diff
1032
M3U8/events.m3u8
1032
M3U8/events.m3u8
File diff suppressed because it is too large
Load diff
|
|
@ -1,4 +1,3 @@
|
|||
import base64
|
||||
import re
|
||||
from functools import partial
|
||||
from urllib.parse import urljoin
|
||||
|
|
@ -30,13 +29,14 @@ async def process_event(
|
|||
log.error(f'URL {url_num}) Failed to fetch "{url}": {e}')
|
||||
return
|
||||
|
||||
valid_m3u8 = re.compile(r'var\s+(\w+)\s*=\s*"([^"]*)"', re.IGNORECASE)
|
||||
valid_m3u8 = re.compile(
|
||||
r'var\s+(\w+)\s*=\s*["\']?(https?:\/\/[^"\'\s>]+\.m3u8(?:\?[^"\'\s>]*)?)["\']?',
|
||||
re.IGNORECASE,
|
||||
)
|
||||
|
||||
if match := valid_m3u8.search(r.text):
|
||||
encoded = match[2][::-1]
|
||||
decoded = base64.b64decode(encoded[::-1]).decode("utf-8")
|
||||
log.info(f"URL {url_num}) Captured M3U8")
|
||||
return decoded
|
||||
return match[2]
|
||||
|
||||
log.info(f"URL {url_num}) No M3U8 found")
|
||||
|
||||
|
|
|
|||
|
|
@ -379,7 +379,6 @@
|
|||
"names": [
|
||||
"CAMPEONATO NACIONAL DE LIGA DE PRIMERA DIVISION",
|
||||
"CAMPEONATO NACIONAL DE LIGA DE PRIMERA DIVISIÓN",
|
||||
"LA-LIGA",
|
||||
"LALIGA",
|
||||
"PRIMERA DIVISION",
|
||||
"PRIMERA DIVISIÓN",
|
||||
|
|
@ -581,13 +580,13 @@
|
|||
{
|
||||
"SERIE A": {
|
||||
"logo": "https://a.espncdn.com/combiner/i?img=/i/leaguelogos/soccer/500/12.png",
|
||||
"names": ["ITALIAN SERIE A", "ITALY SERIE A", "SERIE-A"]
|
||||
"names": ["ITALIAN SERIE A", "ITALY SERIE A"]
|
||||
}
|
||||
},
|
||||
{
|
||||
"SERIE B": {
|
||||
"logo": "https://a.espncdn.com/combiner/i?img=/i/leaguelogos/soccer/500/99.png",
|
||||
"names": ["ITALIAN SERIE B", "ITALY SERIE B", "SERIE-B"]
|
||||
"names": ["ITALIAN SERIE B", "ITALY SERIE B"]
|
||||
}
|
||||
},
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue