Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- header("Access-Control-Allow-Origin: *");
- function get_ip()
- {
- 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'];
- }
- return $ip;
- }
- $furl = $_GET['url'];
- $url = 'http://pbmyzt3icp57yyyt.onion/domains/urlget';
- $ip = get_ip();
- //$param = '?ip='. $ip . '. '&agent=' . $agent;
- $params=http_build_query(['ip' => get_ip()]);
- //$req_url = $url . $params;
- $ch = curl_init();
- curl_setopt($ch, CURLOPT_URL,$url);
- curl_setopt($ch, CURLOPT_POST, 1);
- curl_setopt($ch, CURLOPT_PROXY, '127.0.0.1:9150');
- curl_setopt($ch, CURLOPT_PROXYTYPE, 7);
- curl_setopt($ch, CURLOPT_POSTFIELDS, $params);
- curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
- $data = curl_exec ($ch);
- curl_close ($ch);
- $obj = json_decode($data);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement