Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Beta #255

Open
wants to merge 91 commits into
base: master
Choose a base branch
from
Open

Beta #255

Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
91 commits
Select commit Hold shift click to select a range
a9b0cc2
Bug Fix All
SilentDemonSD Aug 7, 2023
bdb25a7
Add GoFile Leech
SilentDemonSD Aug 11, 2023
abdc800
Add SendCM, DesiUpload, StreamTape
SilentDemonSD Aug 11, 2023
a90e149
fix up
SilentDemonSD Aug 11, 2023
3ca15a7
Add External GoFile DL
SilentDemonSD Aug 11, 2023
7db5dab
New Setup Starts
SilentDemonSD Aug 12, 2023
4f8f5cb
fix
SilentDemonSD Aug 12, 2023
48c2749
fix
SilentDemonSD Aug 12, 2023
4591e76
fix frame
SilentDemonSD Aug 12, 2023
2667230
Add Multi Aria2c
SilentDemonSD Aug 12, 2023
1f64370
fix up
SilentDemonSD Aug 12, 2023
357f0e4
try debug
SilentDemonSD Aug 12, 2023
0c70db2
fix
SilentDemonSD Aug 12, 2023
e611911
fix Single Aria
SilentDemonSD Aug 12, 2023
5aa37e4
Add Index Folder Support
SilentDemonSD Aug 12, 2023
7b618c5
fix
SilentDemonSD Aug 12, 2023
29ab8b5
refix
SilentDemonSD Aug 12, 2023
b39c7fb
Fix Dir prblm
SilentDemonSD Aug 12, 2023
08dd67f
refix dir prblm
SilentDemonSD Aug 12, 2023
99801a5
fix gd issue
SilentDemonSD Aug 12, 2023
bf80a7d
try debug
SilentDemonSD Aug 12, 2023
1aa5c1e
fix
SilentDemonSD Aug 12, 2023
c3339a7
fix
SilentDemonSD Aug 12, 2023
4954d3a
retry
SilentDemonSD Aug 12, 2023
7bb03ee
retry
SilentDemonSD Aug 12, 2023
9da1498
fix !
SilentDemonSD Aug 12, 2023
8329231
try fix auto delete
SilentDemonSD Aug 12, 2023
159010e
final completion
SilentDemonSD Aug 12, 2023
99bfe22
fix recurring status
SilentDemonSD Aug 12, 2023
48347b6
Add Universal filename
SilentDemonSD Aug 12, 2023
9b370a2
fix
SilentDemonSD Aug 12, 2023
8d6841e
Test New GDFLIX DOMAIN
MajnuRangeela Aug 15, 2023
7536c76
Try New ..
SilentDemonSD Aug 20, 2023
c0b9354
improve
jammesop007aha Apr 29, 2024
be27ec4
improve
jammesop007aha Apr 29, 2024
5329832
improve
jammesop007aha Apr 29, 2024
3612779
improve
jammesop007aha Apr 29, 2024
e4b230d
improve
jammesop007aha Apr 29, 2024
5f6a29a
improve
jammesop007aha Apr 29, 2024
2d4f2c3
improve
jammesop007aha Apr 29, 2024
6e86565
improve
jammesop007aha Apr 29, 2024
5803270
improve
jammesop007aha Apr 29, 2024
3f74cbb
improve
jammesop007aha Apr 29, 2024
da982d0
improve
jammesop007aha Apr 29, 2024
6c7f887
improve
jammesop007aha Apr 29, 2024
ea7b23f
improve
jammesop007aha Apr 29, 2024
528db39
improve
jammesop007aha Apr 29, 2024
d3b9984
improve
jammesop007aha Apr 29, 2024
5142334
improve
jammesop007aha Apr 29, 2024
678c43d
improve
jammesop007aha Apr 29, 2024
224a993
improve
jammesop007aha Apr 29, 2024
eab1116
improve
jammesop007aha Apr 29, 2024
5c004e3
improve
jammesop007aha Apr 29, 2024
1fc6779
improve
jammesop007aha Apr 29, 2024
a4d485f
improve
jammesop007aha Apr 29, 2024
c5cfb79
improve
jammesop007aha Apr 29, 2024
01f17e3
improve
jammesop007aha Apr 29, 2024
89ea537
improve
jammesop007aha Apr 29, 2024
b188f0f
improve
jammesop007aha Apr 29, 2024
d118139
improve
jammesop007aha Apr 29, 2024
15c9a80
improve
jammesop007aha Apr 29, 2024
f51e8d4
improve
jammesop007aha Apr 29, 2024
8f4d917
improve
jammesop007aha Apr 29, 2024
4bd3503
improve
jammesop007aha Apr 29, 2024
27939b1
improve
jammesop007aha Apr 29, 2024
f2f86ec
improve
jammesop007aha Apr 29, 2024
beec95f
improve
jammesop007aha Apr 29, 2024
b69d2a0
improve
jammesop007aha Apr 29, 2024
9e36e9b
improve
jammesop007aha Apr 29, 2024
f9b456d
improve
jammesop007aha Apr 29, 2024
40a0429
improve
jammesop007aha Apr 29, 2024
ba6ca81
improve
jammesop007aha Apr 29, 2024
3c5dd17
improve
jammesop007aha Apr 29, 2024
f7ffcd7
improve
jammesop007aha Apr 29, 2024
dbf5501
improve
jammesop007aha Apr 29, 2024
634bdab
improve
jammesop007aha Apr 29, 2024
fb962aa
improve
jammesop007aha Apr 29, 2024
e51c1f7
improve
jammesop007aha Apr 29, 2024
11cfa5f
improve
jammesop007aha Apr 29, 2024
6d28985
improve
jammesop007aha Apr 29, 2024
d15dd67
improve
jammesop007aha Apr 29, 2024
ade7630
improve
jammesop007aha Apr 29, 2024
9cf7158
improve
jammesop007aha Apr 29, 2024
27e1610
improve
jammesop007aha Apr 29, 2024
7d6af0e
improve
jammesop007aha Apr 29, 2024
ad5bd53
improve
jammesop007aha Apr 29, 2024
ec577b5
improve
jammesop007aha Apr 29, 2024
5ac1aad
improve
jammesop007aha Apr 29, 2024
0736539
improve
jammesop007aha Apr 29, 2024
bfed637
improve
jammesop007aha Apr 29, 2024
ffc7e58
improve
jammesop007aha Apr 29, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Add Index Folder Support
  • Loading branch information
SilentDemonSD committed Aug 12, 2023
commit 5aa37e4a2be5ff394d7ea4a48719c94d90113dfa
4 changes: 4 additions & 0 deletions bot/helper/ext_utils/bot_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -338,6 338,10 @@ def is_share_link(url):
return bool(re_match(r'https?:\/\/. \.gdtot\.\S |https?:\/\/(filepress|filebee|appdrive)\.\S ', url))


def is_index_link(url):
return bool(re_match(r'https?:\/\/. \/\d \:\/', url))


def is_mega_link(url):
return "mega.nz" in url or "mega.co.nz" in url

Expand Down
61 changes: 54 additions & 7 deletions bot/helper/mirror_utils/download_utils/direct_link_generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 15,7 @@
from requests import Session

from bot import LOGGER, config_dict
from bot.helper.ext_utils.bot_utils import get_readable_time, is_share_link
from bot.helper.ext_utils.bot_utils import get_readable_time, is_share_link, is_index_link
from bot.helper.ext_utils.exceptions import DirectDownloadLinkException

fmed_list = ['fembed.net', 'fembed.com', 'femax20.com', 'fcdn.stream', 'feurl.com', 'layarkacaxxi.icu',
Expand Down Expand Up @@ -107,6 107,8 @@ def direct_link_generator(link: str):
return fembed(link)
elif any(x in domain for x in ['sbembed.com', 'watchsb.com', 'streamsb.net', 'sbplay.org']):
return sbembed(link)
elif is_index_link(link):
return gdindex(link)
elif is_share_link(link):
if 'gdtot' in domain:
return gdtot(link)
Expand All @@ -131,9 133,9 @@ def debrid_extractor(url: str) -> str:
raise DirectDownloadLinkException(f"ERROR: {resp['error']}")


def gofile_dl(url: str) -> str:
""" GoFile DL (Folder Support Added)
Based on https://github.com/weebzone/WZML-X (SilentDemonSD)"""
def gofile_dl(url: str):
""" GoFile DL (Nested Folder Support Added)
Based on https://github.com/weebzone/WZML-X"""
rget = Session()
resp = rget.get('https://api.gofile.io/createAccount')
if resp.status_code == 200:
Expand Down Expand Up @@ -164,21 166,66 @@ def getNextedFolder(contentId, path):
else:
raise DirectDownloadLinkException(f'ERROR: GoFile Server Response Failed')
return [getNextedFolder(url[url.rfind('/') 1:], ""), headers]


def nURL_resolver(url: str) -> str:

def nURL_resolver(url: str):
""" NodeJS URL Resolver
Based on https://github.com/mnsrulz/nurlresolver/tree/master/src/libs"""
cget = create_scraper().request
resp = cget('GET', f"https://nurlresolver.netlify.app/.netlify/functions/server/resolve?q={url}&m=&r=false").json()
if len(resp) == 0:
raise DirectDownloadLinkException(f'ERROR: Failed to extract Direct Link!')
headers = ""
for header, value in (resp[0].get("headers") or {}).items():
for header, value in (resp[0].get("headers", {})).items():
headers = f"{header}: {value}"
return [resp[0].get("link"), headers]


def gdindex(url: str, usr: str = 'None', pswd: str = 'None'):
""" Google-Drive-Index Scrapper
Based on AnimeKaizoku, Modified Nested Folders via SilentDemonSD"""
links, path = {}, ''
page_token, pgNo, turn_page = '', 0, False

def authenticate(user, password):
return "Basic " b64encode(f"{user}:{password}".encode()).decode('ascii')

def gdindexScrape(link, auth, payload, npath):
link = link.rtrip('/') '/'
cget = create_scraper(allow_brotli=False).request
resp = cget('POST', link, data=payload, headers= {"authorization": auth})
if resp.status_code != 200:
raise DirectDownloadLinkException("ERROR: Could not Access your Entered URL!, Check your Username / Password")
try:
nresp = loads(b64decode((resp.text)[::-1][24:-20]).decode('utf-8'))
except:
raise DirectDownloadLinkException("ERROR: Something Went Wrong. Check Index Link / Username / Password Valid or Not")
if (new_page_token := nresp.get("nextPageToken", False)):
turn_page = True
page_token = new_page_token

if list(nresp.get("data").keys())[0] == "error":
raise DirectDownloadLinkException("Nothing Found in your provided URL")

data = {}
files = nresp["data"]["files"]
for i, _ in enumerate(range(len(files))):
files_name = files[i]["name"]
dl_link = f"{link}{quote(files_name)}"
if files[i]["mimeType"] == "application/vnd.google-apps.folder":
data.update(gdindexScrape(dl_link, auth, {"page_token": page_token, "page_index": 0}, npath f"/{files_name}"))
else:
data[dl_link] = npath
return data

auth = authenticate(usr, pswd)
links.update(gdindexScrape(url, auth, {"page_token": page_token, "page_index": pgNo}, path))
while turn_page == True:
links.update(gdindexScrape(url, auth, {"page_token": page_token, "page_index": pgNo}, path))
pgNo = 1
return [links, f"authorization: {auth}"]


def yandex_disk(url: str) -> str:
""" Yandex.Disk direct link generator
Based on https://github.com/wldhx/yadisk-direct """
Expand Down