Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ip2location/codeigniter-ip2proxy
IP2Proxy library for CodeIgniter. It can be used to find the IP addresses which are used as VPN anonymizer, open proxies, web proxies and TOR exits nodes, search engine robots, data center ranges and residential proxies.
https://github.com/ip2location/codeigniter-ip2proxy
codeigniter-ip2proxy ip-lookup ip2proxy-bin-database proxy-information proxy-lookup web-service
Last synced: 23 days ago
JSON representation
IP2Proxy library for CodeIgniter. It can be used to find the IP addresses which are used as VPN anonymizer, open proxies, web proxies and TOR exits nodes, search engine robots, data center ranges and residential proxies.
- Host: GitHub
- URL: https://github.com/ip2location/codeigniter-ip2proxy
- Owner: ip2location
- License: mit
- Created: 2020-09-14T06:36:44.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2024-02-19T05:04:24.000Z (10 months ago)
- Last Synced: 2024-02-19T06:23:58.804Z (10 months ago)
- Topics: codeigniter-ip2proxy, ip-lookup, ip2proxy-bin-database, proxy-information, proxy-lookup, web-service
- Language: PHP
- Homepage: https://www.ip2location.com
- Size: 32.2 KB
- Stars: 4
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.TXT
Awesome Lists containing this project
README
CodeIgniter IP2Proxy Library
===============================
This module allows user to reverse search of IP address to detect VPN servers, open proxies, web proxies, Tor exit nodes, search engine robots, data center ranges, residential proxies, consumer privacy networks, and enterprise private networks. Other information available includes proxy type, country, state, city, ISP, domain name, usage type, AS number, AS name, threats, last seen date and provider names.## Installation
Upload `controllers` and `libraries` to CodeIgniter `application` folder.## Usage
This module is able to query the IP address information from either BIN database or web service. This section will explain how to use this extension to query from BIN database and web service.Sample codes are given in this project, under **controllers** folder. You may run the sample code by using /index.php/ip2proxy_test.
### BIN Database
Use following codes in your application for get geolocation information.// (optional) Define IP2Proxy database path.
define('IP2PROXY_DATABASE', '/path/to/ip2proxy/database');$ipx = new IP2Proxy_lib();
$countryCode = $ipx->getCountryShort('1.0.241.135');Below are the methods supported for BIN data file lookup.
$countryShort = $ipx->getCountryShort($ip);
$countryLong = $ipx->getCountryLong($ip);
$region = $ipx->getRegion($ip);
$city = $ipx->getCity($ip);
$isp = $ipx->getISP($ip);
$doamin = $ipx->getDomain($ip);
$usageType = $ipx->getUsageType($ip);
$proxyType = $ipx->getProxyType($ip);
$asn = $ipx->getASN($ip);
$as = $ipx->getAS($ip);
$lastSeen = $ipx->getLastSeen($ip);
$threat = $ipx->getThreat($ip);
$provider = $ipx->getProvider($ip);
$isProxy = $ipx->isProxy($ip);### Web Service
Use following codes in your application for get geolocation information.// (required) Define IP2Proxy API key.
define('IP2PROXY_API_KEY', 'your_api_key');// (required) Define IP2Proxy Web service package of different granularity of return information.
define('IP2PROXY_PACKAGE', 'PX1');// (optional) Define to use https or http.
define('IP2PROXY_USESSL', false);$ipx = new IP2Proxy_lib();
print_r ($ipx->getWebService('1.0.241.135'));## Dependencies
This module requires IP2Proxy BIN data file or IP2Proxy API key to function. You may download the BIN data file at* IP2Proxy LITE BIN Data (Free): https://lite.ip2location.com
* IP2Proxy Commercial BIN Data (Comprehensive): https://www.ip2location.com/proxy-databaseYou can also sign up for [IP2Proxy Web Service](https://www.ip2location.com/web-service/ip2proxy) to get one free API key.
## IPv4 BIN vs IPv6 BIN
* Use the IPv4 BIN file if you just need to query IPv4 addresses.
* Use the IPv6 BIN file if you need to query BOTH IPv4 and IPv6 addresses.## SUPPORT
Email: [email protected]Website: https://www.ip2location.com