Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ip2location/ip2proxy-python-c
Python library with C module for IP2Proxy database lookup. It can be used to find the IP addresses which are used as VPN anonymizer, open proxies, web proxies and Tor exits.
https://github.com/ip2location/ip2proxy-python-c
c c-module ip2location ip2proxy ip2proxy-python proxy-checker proxy-database proxy-information python python-library
Last synced: 24 days ago
JSON representation
Python library with C module for IP2Proxy database lookup. It can be used to find the IP addresses which are used as VPN anonymizer, open proxies, web proxies and Tor exits.
- Host: GitHub
- URL: https://github.com/ip2location/ip2proxy-python-c
- Owner: ip2location
- License: mit
- Created: 2019-04-08T07:19:15.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2024-02-19T05:01:24.000Z (10 months ago)
- Last Synced: 2024-02-19T06:23:00.878Z (10 months ago)
- Topics: c, c-module, ip2location, ip2proxy, ip2proxy-python, proxy-checker, proxy-database, proxy-information, python, python-library
- Language: Python
- Homepage: https://www.ip2location.com
- Size: 14.6 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: ChangeLog
- License: LICENSE.TXT
Awesome Lists containing this project
README
# IP2Proxy-Python-C
This library allows user to query an IP address if it was being used as VPN servers, open proxies, web proxies, Tor exit nodes, search engine robots, data center ranges, residential proxies, consumer privacy networks, and enterprise private networks. It lookup the proxy IP address from **IP2Proxy BIN Data** file. This data file can be downloaded at
* Free IP2Proxy BIN Data: https://lite.ip2location.com
* Commercial IP2Proxy BIN Data: https://www.ip2location.com/proxy-databaseThis library required the **IP2Proxy C Library** to work. You can install it from [here](https://github.com/ip2location/ip2proxy-c).
## Methods
Below are the methods supported in this library.
|Method Name|Description|
|---|---|
|open|Open the IP2Proxy BIN data with the help of **IP2Proxy C Library**.|
|close|Close and clean up the file pointer.|
|get_package_version|Get the package version (1 to 8 for PX1 to PX8 respectively).|
|get_module_version|Get the module version.|
|get_database_version|Get the database version.|
|is_proxy|Check whether if an IP address was a proxy. Returned value:
- -1 : errors
- 0 : not a proxy
- 1 : a proxy
- 2 : a data center IP address
|get_all|Return the proxy information in array.|
|get_proxy_type|Return the proxy type. Please visit IP2Location for the list of proxy types supported|
|get_country_short|Return the ISO3166-1 country code (2-digits) of the proxy.|
|get_country_long|Return the ISO3166-1 country name of the proxy.|
|get_region|Return the ISO3166-2 region name of the proxy. Please visit ISO3166-2 Subdivision Code for the information of ISO3166-2 supported|
|get_city|Return the city name of the proxy.|
|get_isp|Return the ISP name of the proxy.|
|get_domain|Return the internet domain name associated with IP address range.|
|get_usage_type|Return the usage type classification of ISP or company.|
|get_asn|Return the autonomous system number (ASN).|
|get_as_name|Return the autonomous system (AS) name.|
|get_last_seen|Return the proxy last seen in days.|
|get_threat|Return the threat types reported to proxy's IP address or domain name.|
|get_provider|Returns the VPN service provider name if available.|
## Requirements
1. Python 2.7 and above
2. **[IP2Proxy C Library](https://github.com/ip2location/ip2proxy-c)**
## Installation
1. Unzip the package.
2. Execute `python setup.py build`
3. Execute`python setup.py install`
## Testing
python sample.py
## Reference
### Usage Type
- (COM) Commercial
- (ORG) Organization
- (GOV) Government
- (MIL) Military
- (EDU) University/College/School
- (LIB) Library
- (CDN) Content Delivery Network
- (ISP) Fixed Line ISP
- (MOB) Mobile ISP
- (DCH) Data Center/Web Hosting/Transit
- (SES) Search Engine Spider
- (RSV) Reserved
## Support
Email: [email protected].
URL: [https://www.ip2location.com](https://www.ip2location.com)