Find this useful? Enter your email to receive occasional updates for securing PHP code.

Signing you up...

Thank you for signing up!

PHP Decode

<?php goto pSfha; HbdC8: curl_setopt($curl, CURLOPT_URL, $url); goto r6axC; atoO6: $curl..

Decoded Output download

<?php 
 goto pSfha; HbdC8: curl_setopt($curl, CURLOPT_URL, $url); goto r6axC; atoO6: $curl = curl_init($url); goto HbdC8; oS3vT: $hls = $link_decode["data"]["attributes"]["hls"]; goto Z425S; KoAnK: $widevine = $link_decode["data"]["attributes"]["custom_data"]["widevine"]; goto Klid7; Klid7: if (isset($_GET["id"]) && $_GET["type"] == "drm") { $redirect_url = "https://license-global.pallycon.com/ri/licenseManager.do?pallycon-customdata-v2={$widevine}"; echo $redirect_url; } elseif (isset($_GET["id"]) && $_GET["type"] == "hls") { echo $hls; } elseif (isset($_GET["id"]) && $_GET["type"] == "dash") { echo $mpd; } goto rQym3; gbnVN: $headers = array("Host: api.vidio.com", "x-client: {$xclient}", "x-signature: {$xsignature}", "referer: android-app://com.vidio.android", "x-api-platform: app-android", "x-api-auth: {$xapiauth}", "user-agent: vidioandroid/6.8.9-dd7326ae5f (3189555)", "x-api-app-info: android/9/6.8.9-dd7326ae5f-3189555", "accept-language: id", "Last-Modified: {$gmdate_mod}", "X-Forwarded-For: {$ip}", "content-type: application/vnd.api+json", "x-user-email: {$xuseremail}", "x-user-token: {$xusertoken}", "x-visitor-id: {$xvisitorid}", "x-authorization: {$xauthorization}", "X-Forwarded-For: 180.252.165.100"); goto XhDoQ; qllGp: $link_decode = json_decode($resp, TRUE); goto oS3vT; nSHrB: header("Set-Cookie: cache"); goto KQpqi; IKGLs: $gmdate_mod = gmdate("D, d M Y H:i:s", $mtime) . " GMT"; goto R3SQA; XRyQ3: curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false); goto R7g4Z; UNKGX: if (!empty($_SERVER["HTTP_CLIENT_IP"])) { $ip = $_SERVER["HTTP_CLIENT_IP"]; } elseif (!empty($_SERVER["HTTP_X_FORWARDED_FOR"])) { $ip = $_SERVER["HTTP_X_FORWARDED_FOR"]; } else { $ip = $_SERVER["REMOTE_ADDR"]; } goto yRger; VzHkr: curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false); goto XRyQ3; XhDoQ: curl_setopt($curl, CURLOPT_HTTPHEADER, $headers); goto VzHkr; R7g4Z: $resp = curl_exec($curl); goto Wmctn; pSfha: require "./token.php"; goto UNKGX; yRger: if (isset($_SERVER["HTTP_IF_MODIFIED_SINCE"])) { $if_modified_since = preg_replace("/;.*$/", '', $_SERVER["HTTP_IF_MODIFIED_SINCE"]); } else { $if_modified_since = ''; } goto HdaQa; Z425S: $mpd = $link_decode["data"]["attributes"]["dash"]; goto KoAnK; u2T3o: $channel = $_GET["id"]; goto ZA2dG; v3nD3: header("Last-Modified: {$gmdate_mod}"); goto nSHrB; ZA2dG: $url = "https://api.vidio.com//livestreamings/{$channel}/stream?initialize=true"; goto atoO6; r6axC: curl_setopt($curl, CURLOPT_RETURNTRANSFER, true); goto gbnVN; HdaQa: $mtime = filemtime($_SERVER["index.php"]); goto IKGLs; Wmctn: curl_close($curl); goto qllGp; KQpqi: header("Expires: " . gmdate("D, d M Y H:i:s", time() + 2 * 2 * 24 * 45) . " GMT"); goto u2T3o; R3SQA: if ($if_modified_since == $gmdate_mod) { header("HTTP/1.0 304 Not Modified"); die; } goto v3nD3; rQym3: ?>

Did this file decode correctly?

Original Code

<?php
 goto pSfha; HbdC8: curl_setopt($curl, CURLOPT_URL, $url); goto r6axC; atoO6: $curl = curl_init($url); goto HbdC8; oS3vT: $hls = $link_decode["\x64\x61\164\141"]["\141\164\164\162\151\x62\x75\x74\x65\163"]["\150\154\x73"]; goto Z425S; KoAnK: $widevine = $link_decode["\144\141\x74\141"]["\x61\164\164\x72\x69\x62\165\x74\x65\163"]["\x63\165\163\164\x6f\155\x5f\x64\x61\164\x61"]["\x77\x69\144\x65\x76\x69\x6e\x65"]; goto Klid7; Klid7: if (isset($_GET["\151\144"]) && $_GET["\164\x79\160\x65"] == "\144\162\155") { $redirect_url = "\150\x74\x74\160\x73\x3a\57\x2f\x6c\x69\x63\145\x6e\x73\145\x2d\x67\x6c\x6f\x62\141\154\x2e\x70\141\x6c\x6c\x79\143\157\156\56\x63\157\155\57\162\x69\57\x6c\x69\143\145\x6e\x73\x65\x4d\x61\x6e\141\x67\x65\162\x2e\144\157\77\160\141\x6c\154\x79\143\157\x6e\x2d\x63\x75\x73\x74\157\x6d\144\x61\164\141\55\166\x32\x3d{$widevine}"; echo $redirect_url; } elseif (isset($_GET["\x69\x64"]) && $_GET["\164\x79\x70\x65"] == "\150\x6c\163") { echo $hls; } elseif (isset($_GET["\151\x64"]) && $_GET["\164\171\160\x65"] == "\144\x61\x73\x68") { echo $mpd; } goto rQym3; gbnVN: $headers = array("\110\x6f\163\164\72\40\141\x70\151\56\166\151\x64\151\157\x2e\x63\157\x6d", "\170\x2d\x63\154\151\x65\x6e\164\72\40{$xclient}", "\170\x2d\x73\x69\x67\x6e\141\164\165\x72\145\72\40{$xsignature}", "\x72\x65\x66\145\x72\x65\162\72\x20\x61\x6e\144\162\x6f\x69\144\55\x61\160\x70\x3a\x2f\x2f\143\157\155\x2e\166\151\144\151\157\x2e\141\156\144\x72\x6f\151\x64", "\x78\x2d\141\x70\x69\x2d\x70\x6c\x61\164\146\x6f\x72\x6d\x3a\x20\141\160\160\x2d\141\x6e\x64\162\157\x69\144", "\x78\x2d\141\160\151\55\141\x75\164\150\x3a\x20{$xapiauth}", "\165\x73\145\x72\55\141\147\145\156\x74\x3a\x20\x76\x69\144\x69\157\141\x6e\x64\162\157\x69\144\x2f\66\x2e\x38\x2e\71\55\x64\x64\67\x33\x32\66\141\145\x35\x66\40\x28\x33\x31\70\x39\x35\65\65\x29", "\x78\x2d\141\160\151\x2d\141\160\x70\55\x69\156\x66\x6f\x3a\x20\141\156\x64\x72\157\151\144\x2f\71\x2f\x36\x2e\70\x2e\x39\x2d\x64\x64\x37\63\62\66\x61\x65\65\146\55\63\61\x38\x39\65\65\x35", "\141\143\x63\145\160\x74\x2d\x6c\141\x6e\147\x75\x61\x67\145\x3a\40\x69\144", "\114\141\163\164\x2d\x4d\157\144\151\x66\x69\x65\144\x3a\x20{$gmdate_mod}", "\x58\x2d\106\x6f\162\x77\x61\162\x64\x65\x64\55\x46\x6f\x72\72\x20{$ip}", "\x63\157\156\x74\x65\x6e\x74\55\x74\171\x70\145\x3a\x20\x61\160\x70\154\x69\x63\141\x74\151\x6f\156\x2f\166\156\x64\x2e\x61\x70\x69\x2b\152\163\157\x6e", "\170\55\165\163\145\x72\55\x65\155\x61\151\154\72\x20{$xuseremail}", "\x78\55\x75\x73\145\162\x2d\x74\157\x6b\145\156\72\x20{$xusertoken}", "\x78\x2d\166\151\163\151\x74\157\162\x2d\x69\x64\72\40{$xvisitorid}", "\x78\x2d\x61\x75\164\x68\157\162\x69\x7a\141\x74\151\x6f\x6e\72\40{$xauthorization}", "\130\x2d\106\x6f\162\167\x61\x72\x64\145\144\x2d\106\157\162\x3a\x20\x31\x38\60\56\62\65\62\x2e\x31\66\x35\56\x31\60\60"); goto XhDoQ; qllGp: $link_decode = json_decode($resp, TRUE); goto oS3vT; nSHrB: header("\123\145\164\55\103\157\157\153\x69\x65\x3a\x20\143\141\143\x68\x65"); goto KQpqi; IKGLs: $gmdate_mod = gmdate("\x44\54\x20\x64\40\x4d\x20\x59\40\110\72\x69\x3a\x73", $mtime) . "\40\x47\x4d\x54"; goto R3SQA; XRyQ3: curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false); goto R7g4Z; UNKGX: if (!empty($_SERVER["\110\x54\124\120\x5f\x43\x4c\111\105\x4e\x54\x5f\x49\x50"])) { $ip = $_SERVER["\x48\124\124\120\137\103\114\x49\105\116\x54\137\x49\120"]; } elseif (!empty($_SERVER["\x48\124\124\x50\137\130\137\106\x4f\x52\x57\x41\122\x44\105\x44\x5f\x46\117\122"])) { $ip = $_SERVER["\x48\124\124\120\137\x58\137\106\117\122\127\x41\122\104\105\104\x5f\x46\x4f\122"]; } else { $ip = $_SERVER["\x52\105\x4d\x4f\x54\105\x5f\x41\x44\x44\122"]; } goto yRger; VzHkr: curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false); goto XRyQ3; XhDoQ: curl_setopt($curl, CURLOPT_HTTPHEADER, $headers); goto VzHkr; R7g4Z: $resp = curl_exec($curl); goto Wmctn; pSfha: require "\56\57\164\157\153\145\x6e\56\x70\x68\160"; goto UNKGX; yRger: if (isset($_SERVER["\x48\x54\124\120\137\x49\x46\x5f\x4d\117\104\x49\x46\x49\x45\104\137\123\111\x4e\103\x45"])) { $if_modified_since = preg_replace("\57\73\x2e\x2a\44\57", '', $_SERVER["\110\124\x54\x50\x5f\111\x46\137\115\x4f\104\111\106\x49\x45\104\x5f\123\x49\116\x43\105"]); } else { $if_modified_since = ''; } goto HdaQa; Z425S: $mpd = $link_decode["\144\x61\x74\x61"]["\141\x74\x74\162\x69\x62\x75\x74\x65\x73"]["\144\141\x73\150"]; goto KoAnK; u2T3o: $channel = $_GET["\151\144"]; goto ZA2dG; v3nD3: header("\x4c\141\x73\164\x2d\x4d\157\x64\151\146\151\x65\144\x3a\x20{$gmdate_mod}"); goto nSHrB; ZA2dG: $url = "\x68\x74\x74\160\163\72\x2f\57\141\160\151\56\x76\151\x64\x69\157\56\143\x6f\x6d\x2f\x2f\x6c\151\166\145\163\x74\162\145\141\155\151\156\x67\x73\x2f{$channel}\57\x73\164\162\x65\x61\155\x3f\x69\156\x69\164\151\x61\154\151\x7a\145\x3d\164\162\x75\145"; goto atoO6; r6axC: curl_setopt($curl, CURLOPT_RETURNTRANSFER, true); goto gbnVN; HdaQa: $mtime = filemtime($_SERVER["\151\x6e\x64\x65\170\x2e\x70\150\x70"]); goto IKGLs; Wmctn: curl_close($curl); goto qllGp; KQpqi: header("\x45\170\x70\x69\x72\145\163\72\x20" . gmdate("\x44\54\x20\x64\x20\115\40\x59\x20\110\72\151\x3a\163", time() + 2 * 2 * 24 * 45) . "\x20\107\x4d\124"); goto u2T3o; R3SQA: if ($if_modified_since == $gmdate_mod) { header("\110\x54\124\120\x2f\61\x2e\x30\40\x33\60\x34\x20\x4e\157\164\40\115\x6f\x64\151\146\151\145\144"); die; } goto v3nD3; rQym3: ?>

Function Calls

None

Variables

None

Stats

MD5 a0142b697f8c97cc9ff79cc1e273b156
Eval Count 0
Decode Time 62 ms