# 2024.11.18 - [up_fileditch / fileditch] Add fileditch.com as upload and download host
# 2024.11.17 - [innocent] Fix "Fetching file info". Support resume downloads. # 2024.11.16 - [mad] Fix reload on uploads.txt modified (uploads: filemode) # 2024.11.16 - [up_*] Fix removal of upload ticket if filesize is not supported # 2024.11.15 - [familleflender] Add famille-flender.fr as download host # 2024.11.15 - [up_familleflender] Add famille-flender.fr as upload host # 2024.11.15 - [up_filehaus] Finish the uploader (the server is back online)
This commit is contained in:
parent
d3d08d63f5
commit
fa83163a58
101 changed files with 1648 additions and 790 deletions
15
hosts/up_filehaus.sh
Executable file → Normal file
15
hosts/up_filehaus.sh
Executable file → Normal file
|
|
@ -1,6 +1,6 @@
|
|||
#! Name: up_filehaus.sh
|
||||
#! Author: kittykat
|
||||
#! Version: 2024.10.23
|
||||
#! Version: 2024.11.15
|
||||
#! Desc: Add support for uploading files to a new host
|
||||
#! Info: Files are accessible at http://filehaus.su/<hash> or https://filehaus.top/<hash>
|
||||
#! MaxSize: 300GB
|
||||
|
|
@ -37,7 +37,7 @@ fh_UploadFile() {
|
|||
local filepath=${2}
|
||||
local filecnt=${3}
|
||||
local pline=${4}
|
||||
local filename="${filepath##*/}"
|
||||
local filename="${filepath##*/}"
|
||||
warnAndRetryUnknownError=false
|
||||
exitUploadError=false
|
||||
exitUploadNotAvailable=false
|
||||
|
|
@ -47,7 +47,7 @@ fh_UploadFile() {
|
|||
MaxUploadSizeInBytes=10737418240
|
||||
fsize=$(GetFileSize "$filepath" "false")
|
||||
if ((fsize > MaxUploadSizeInBytes)); then
|
||||
m -f "${UploadTicket}"
|
||||
rm -f "${UploadTicket}"
|
||||
echo -e "${YELLOW}| SKIP${NC}: The size of $filename is to large for $_hostCode. ($fsize > $MaxUploadSizeInBytes)"
|
||||
failedUpload "$pline" "${filepath}" "${_hostCode}" "Skipping upload. The size of $filename is to large for $_hostCode. ($fsize > $MaxUploadSizeInBytes)"
|
||||
return 1
|
||||
|
|
@ -111,18 +111,17 @@ fh_PostFile() {
|
|||
if [ "${DebugAllEnabled}" == "true" ] ; then
|
||||
debugHtml "${filepath##*/}" "${_hostCode}_upload" "post_url: ${PostUrlHost}"$'\n'"${response}"
|
||||
fi
|
||||
if grep -Eqi '"status":"ok"' <<< "${response}" ; then
|
||||
url=$(grep -oPi '(?<="downloadPage":").*?(?=")' <<< "$response")
|
||||
hash=$(grep -oPi '(?<=https://gofile.io/d/).*?(?=")' <<< "$response")
|
||||
if grep -Eqi 'HTTP/.* 200|https://cdn' <<< "${response}" ; then
|
||||
url=$(grep -oPi '(?<=https://).*(?=\.filehaus\.su).*?(?=$)' <<< "$response")
|
||||
filesize=$(GetFileSize "$filepath" "false")
|
||||
downloadLink="${url}"
|
||||
downloadLink="https://${url}"
|
||||
echo -e "${GREEN}| Upload Success${NC}"
|
||||
echo -e "| Size: ${BLUE}${filesize}${NC} bytes${NC}"
|
||||
echo -e "| Link: ${YELLOW}${downloadLink}${NC}"
|
||||
successUpload "$pline" "${filepath}" "${_hostCode}" "${filesize}" "${downloadLink}" "{$response}"
|
||||
return 0
|
||||
else
|
||||
err=$(grep -oPi '(?<=HTTP/1.1 ).*?(?=$)' <<< "$response")
|
||||
err=$(grep -oPi '(?<=HTTP/.* ).*?(?=$)' <<< "$response")
|
||||
if [ "${finalAttempt}" == "true" ] ; then
|
||||
printf "\\n"
|
||||
echo -e "${RED}| Upload failed. Status: ${err}${NC}"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue