1. What is an open proxy or anonymous proxy?An open proxy is a proxy server which is accessible by any Internet user. Generally, a proxy server allows users within a network group to store and forward internet services such as DNS or web pages so that the bandwidth used by the group is reduced and controlled. By using some anonymous open proxies, users can conceal their true IP address from the accessed service, and this is sometimes used to abuse or interrupt that service. Open or Anonymous proxies are therefore often seen as a problem to Web sites. [ Back to Top ] 2. What is the database format?The database format is known as Comma Separated Values (CSV). All fields are separated by a comma and each individual line is a record by itself. [ Back to Top ] 3. What is an open proxy or anonymous proxy?
Column
Number |
Column
Descriptions |
1 |
Proxy IP Address
|
2 |
ISO 3166 Country Code (2 Characters) |
3 |
ISO 3166 Country Name |
[ Back to Top ] 4. What is the minus sign "-" in country name or country code?The IP2Location will display the "-" in country field when the IP address range
is still unallocated to any countries. It is also known as reserved IP address
range. [ Back to Top ] 5. How can I automate the download process?Our subscribers can automate the download process using the free command-line script written in Perl which can be downloaded from our Web site at http://www.ip2location.com/downloader.aspx.
Command Line Syntax
perl download.pl -package PX1 -login <login> -password <password> -output IP2PROXY-IP-COUNTRY.ZIP
Since the database is being updated daily at 12:00am (GMT+8), please download the database only once a day to avoid congestion on the download server. [ Back to Top ] 6. How do I use this database?Firstly, import this database into MS-SQL, MS-ACCESS, PL/SQL, mySQL or other RDMS. Secondly, get the visitor IP address and search through the first column of the IP2Proxy database. If the IP record is found, then the user is using an anonymous or open proxy server.
Example of SQL Query
SELECT [COUNTRY NAME COLUMN] FROM [IP2PROXY TABLE] WHERE
[SEARCH IP ADDRESS] = [IP ADDRESS COLUMN] [ Back to Top ] 7. How do I retrieve visitor's IP address using ASP, ASP.NET, C#, VB.NET, PHP, JSP & ColdFusion?The IP address is available from the web server variable "REMOTE_ADDR".
ASP without Proxy
detection
<% ipaddress =
Request.ServerVariables("REMOTE_ADDR") %>
ASP with Proxy
detection
<% ipaddress =
Request.ServerVariables("HTTP_X_FORWARDED_FOR") if
ipaddress = "" then ipaddress =
Request.ServerVariables("REMOTE_ADDR") end
if %>
PHP without Proxy
detection
<? $ipaddress =
getenv(REMOTE_ADDR); ?>
PHP with Proxy
detection
<? if
(getenv(HTTP_X_FORWARDED_FOR)) {
$ipaddress = getenv(HTTP_X_FORWARDED_FOR); } else {
$ipaddress =
getenv(REMOTE_ADDR); } ?>
JSP without Proxy
detection
<% String ipaddress =
request.getRemoteAddr(); %>
JSP with Proxy
detection
<% if
(request.getHeader("X_FORWARDED_FOR") == null)
{ String ipaddress =
request.getRemoteAddr(); } else
{ String ipaddress =
request.getHeader("X_FORWARDED_FOR");
} %>
ColdFusion without Proxy
detection
<CFCOMPONENT> <CFSET
ipaddress="#CGI.Remote_Addr#"> </CFCOMPONENT>
ColdFusion
with Proxy detection
<CFCOMPONENT> <CFIF
#CGI.HTTP_X_Forwarded_For# EQ ""> <CFSET
ipaddress="#CGI.Remote_Addr#"> <CFELSE> <CFSET
ipaddress="#CGI.HTTP_X_Forwarded_For#"> </CFIF> </CFCOMPONENT>
ASP.NET (C#) without Proxy
detection
public string IpAddress() { return
Request.ServerVariables["HTTP_X_FORWARDED_FOR"]; }
ASP.NET (C#)
with Proxy detection
public string
IpAddress() { string strIp; strIp
= Request.ServerVariables["HTTP_X_FORWARDED_FOR"]; if
(strIp == null) {
strIp = Request.ServerVariables["REMOTE_ADDR"];
} return strIp; }
ASP.NET (VB.NET) without Proxy
detection
Public Function IpAddress() IpAddress
= Request.ServerVariables("HTTP_X_FORWARDED_FOR") End
Function
ASP.NET (VB.NET) with Proxy detection
Public
Function IpAddress() Dim strIp As
String strIp =
Request.ServerVariables("HTTP_X_FORWARDED_FOR") If strIp =
"" Then strIp =
Request.ServerVariables("REMOTE_ADDR") End
If IpAddress = strIp End Function
[ Back to Top ] 8. How do I create the SQL table?MSSQL
CREATE DATABASE IP2Proxy GO
CREATE TABLE [dbo].[IP2PROXY_IP_COUNTRY] ( [ipADDRESS] [nvarchar] (15) NOT NULL
,
[countrySHORT] [nvarchar] (2) COLLATE SQL_Latin1_General_CP1_CI_AS NULL
, [countryLONG] [nvarchar] (64) COLLATE
SQL_Latin1_General_CP1_CI_AS NULL ,
CONSTRAINT [PK_IP2PROXY_IP_COUNTRY] PRIMARY KEY CLUSTERED
(
[ipADDRESS]
) ON [PRIMARY]
) ON
[PRIMARY] GO
MYSQL
CREATE DATABASE IP2Proxy CHARACTER SET LATIN1;
CREATE TABLE IP2PROXY_IP_COUNTRY ( ipADDRESS VARCHAR(15) UNSIGNED ZEROFILL NOT NULL ,
countrySHORT CHAR(2) NOT
NULL, countryLONG VARCHAR(45) NOT
NULL, PRIMARY KEY(ipADDRESS) );
POSTGRESQL
CREATE DATABASE IP2Proxy WITH ENCODING 'LATIN1';
CREATE TABLE IP2PROXY_IP_COUNTRY
(
ipaddress character varying(15) NOT NULL,
countryshort character(2) NOT NULL,
countrylong character varying(64) NOT NULL,
CONSTRAINT IP2PROXY_IP_COUNTRY_pkey PRIMARY KEY (ipaddress)
);
[ Back to Top ] 9. Will I receive daily notification when the update is available?No, we will not notify you everyday. Instead, we will deliver the notification of subscription as a reminder via email every month. The database will be uploaded to the server at 12:00am (GMT+8) everyday. [ Back to Top ] 10. Why do we need to update this database periodically?The list will need to be updated when new proxy servers appear or old proxy servers are disabled. Therefore, we roll out the changes in a new database everyday. Subscribers need to remove the old database from the system and replace it with the new one everyday to make sure the list is up-to-date. [ Back to Top ] 11. What do I get if I purchase the full version?You will receive your login and password through email immediately after payment is
authorized. You can use your credentials to download the database from our website at
anytime. The database is in a ZIP compressed format to save your bandwidth and
downloading time. [ Back to Top ] 12. How much is the cost of the database license for multiple servers?
Number
of License |
Price |
1 |
US$399 |
2 |
US$699 |
5 |
US$1499 |
10 |
US$2399 |
| Corporate (20) |
US$3999 |
Note: For corporate license purchase, please add "20" units to any subscriptions and the shopping cart will process it as "Corporate License" for online checkout. [ Back to Top ] 13. Who is using IP2Location products?IP2Location is a trusted brand in the field of Internet geolocation. It has been used by many different organizations such as large corporations, small and medium businesses as well as not-for-profit organizations in a wide range of purposes. You can view the list of customers here. Meanwhile, you can also find IP2Location in many academic researches which you can view here. [ Back to Top ]
|