Changeset 41279 for titan/mediathek


Ignore:
Timestamp:
Nov 25, 2017, 4:49:46 PM (3 years ago)
Author:
obi
Message:

update tithek hoster streamlist

File:
1 edited

Legend:

Unmodified
Added
Removed
  • titan/mediathek/localhoster/hoster.sh

    r41278 r41279  
    77
    88INPUT=`echo $INPUT | sed 's!/Out/?s=!!g'`
     9
     10#FILENAME="`echo $SRC | tr '/' '\n' | tail -n1 | sed 's/.sh//'` $INPUT $PAGE $NEXT"
     11FILENAME="`echo $INPUT | sed -e 's/\&\+/./g' -e 's#\/\+#.#g' -e 's/\?\+/./g' -e 's/;\+/./g' -e 's/=\+/./g' -e 's/ \+/./g' -e 's/\.\+/./g'`"
     12PICNAME=`echo $FILENAME`
     13
     14if [ -z "$FILENAME" ]; then
     15        FILENAME=none
     16fi
    917
    1018ARCH=`cat /etc/.arch`
     
    241249aliez()
    242250{
     251        rm -f $TMP/cache.hoster.$hoster.* > /dev/null 2>&1
    243252        #http://emb.aliez.me/player/live.php?id=56180&w=700&h=480"
    244253        REFERER=`echo "$INPUT" | sed -e 's/=/%3D/g' -e 's/&/%26/g'`
    245254        EXTRA="|Referer=$REFERER&User-Agent=$USERAGENT"
    246255
    247         $curlbin "$INPUT" -o $TMP/cache.$hoster.1
    248         cat $TMP/cache.$hoster.1 | sed 's/source:/\nfound=/' | grep ^found= | cut -d"'" -f2 >$TMP/cache.$hoster.url1
    249         URL=`cat $TMP/cache.$hoster.url1 | head -n1`
    250         URLMP41="$URL$EXTRA"
    251 
     256        STREAMLIST="$TMP/$TYPE.$hoster.$FILENAME.streamlist"
     257        if [ -e "$STREAMLIST" ];then
     258                rm -f $STREAMLIST > /dev/null 2>&1
     259        fi
     260
     261        $curlbin "$INPUT" -o $TMP/cache.hoster.$hoster.1
     262        cat $TMP/cache.hoster.$hoster.1 | sed 's/source:/\nfound=/' | grep ^found= | cut -d"'" -f2 >$TMP/cache.hoster.$hoster.url1
     263        URL=`cat $TMP/cache.hoster.$hoster.url1 | head -n1`
     264        if [ ! -z "$URL" ];then
     265                echo "$URL$EXTRA" >> $STREAMLIST
     266        fi
    252267#       URL=""
    253268        #file:  'http://a3.aliez.me:8080/hls/streama57449/index.m3u8?st=dgw2dOq8tyFkLLBLn2ycXA',
    254269
    255         cat $TMP/cache.$hoster.1 | sed 's/file:/\nfound=/' | grep ^found= | cut -d"'" -f2 >$TMP/cache.$hoster.url2
    256         URL=`cat $TMP/cache.$hoster.url2 | head -n1`
    257         URLMP42="$URL$EXTRA"
    258 
     270        cat $TMP/cache.hoster.$hoster.1 | sed 's/file:/\nfound=/' | grep ^found= | cut -d"'" -f2 >$TMP/cache.hoster.$hoster.url2
     271        URL=`cat $TMP/cache.hoster.$hoster.url2 | head -n1`
     272        if [ ! -z "$URL" ];then
     273                echo "$URL$EXTRA" >> $STREAMLIST
     274        fi
    259275#URL=""
    260276        #"file":                "rtmp%3A%2F%2Fa3.aliez.me%2Flive%2Fstreama57449%3Ftoken%3Dd11304fabb8e64327df8427e1c2fd5d9"
    261         cat $TMP/cache.$hoster.1 | sed 's/"file":/\nfound=/' | grep ^found= | cut -d'"' -f2 >$TMP/cache.$hoster.url3
    262         URL=`cat $TMP/cache.$hoster.url3 | head -n1`
     277        cat $TMP/cache.hoster.$hoster.1 | sed 's/"file":/\nfound=/' | grep ^found= | cut -d'"' -f2 >$TMP/cache.hoster.$hoster.url3
     278        URL=`cat $TMP/cache.hoster.$hoster.url3 | head -n1`
    263279
    264280        if [ "`echo $URL | grep rtmp | wc -l`" -eq 1 ];then
    265281                #new swfobject.embedSWF("http://i.aliez.me/swf/playernew.swf?0", "mediaspace", "700", "480", "9.0.115.0", false, flashvars, params);
    266                 cat $TMP/cache.$hoster.1 | sed 's/swfobject.embedSWF/\nfound=/' | grep ^found= | cut -d'"' -f2 >$TMP/cache.$hoster.rtmp.swfurl
    267                 SWFURL=`cat $TMP/cache.$hoster.rtmp.swfurl | head -n1`
     282                cat $TMP/cache.hoster.$hoster.1 | sed 's/swfobject.embedSWF/\nfound=/' | grep ^found= | cut -d'"' -f2 >$TMP/cache.hoster.$hoster.url3.rtmp.swfurl
     283                SWFURL=`cat $TMP/cache.hoster.$hoster.url3.rtmp.swfurl | head -n1`
    268284                URL=`echo "$URL" | sed -e 's/%3A/:/g' -e 's!%2F!/!g' -e 's!%3D!=!g' -e 's!%3F!?!g'`
    269285                EXTRA=" pageUrl=$REFERER"
     
    271287                        EXTRA="$EXTRA swfUrl=$SWFURL swfVfy=1 timeout=15 live=1"
    272288                fi
    273                 URLRTMP="$URL$EXTRA"
    274         fi
    275 
    276         STREAMLIST="$TMP/$PARSER.$INPUT.$FROM.$FILENAME.streamlist"
    277         if [ -e "$STREAMLIST" ];then
    278                 rm -f $STREAMLIST
    279         fi
    280         for ROUND in $URLMP42 $URLMP41 $URLRTMP; do
    281                 echo "$ROUND" >> $STREAMLIST
    282         done
     289                if [ ! -z "$URL" ];then
     290                        echo "$URL$EXTRA" >> $STREAMLIST
     291                fi
     292        fi
    283293        URL=$STREAMLIST
    284294
    285295
    286296        echo "$URL"
    287 #       echo "$URL|If-None-Match=5a1842ad-c4&Accept=*/*&Referer=$REFERER&User-Agent=Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/60.0.3112.113 Safari/537.36"
    288 
    289 
    290297}
    291298
Note: See TracChangeset for help on using the changeset viewer.