[2.0.18] Block Open Proxy Registrants

All new MODs released in our MOD Database will be announced in here. All support for released MODs needs to take place in here. No new MODs will be accepted into the MOD Database for phpBB2
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

On February 1, 2009 this forum will be set to read only as part of retiring of phpBB2.

Rating:

Excellent!
50
63%
Very Good
11
14%
Good
8
10%
Fair
1
1%
Poor
9
11%
 
Total votes: 79

Mittineague
Registered User
Posts: 25
Joined: Tue Jul 11, 2006 3:20 am
Location: West Springfield, Massachusetts
Contact:

bug in proxy list body tpl file

Post by Mittineague » Fri Jan 05, 2007 9:12 am

Great MOD. Even with email verified registration, CAPTCHA, "humanizer" checkbox, and anti-SPAM no filled in hidden fields, I was still getting 2-3 SPAM posts per day. Now with this MOD and the DNS BlackList MOD installed I only get an occassional SPAM post.
I did find a bug, however.
The admin/proxy_list_body.tpl file needs this line

Code: Select all

<option value="status"{S_STATUS}>{L_TYPE}</option>
to be changed to

Code: Select all

<option value="behavior"{S_STATUS}>{L_TYPE}</option>
so that when and if you sort the list by "type", "status" won't get inserted into the db and used for the list query throwing a "no column 'status'" error.

EDIT: adding error message content to aid searchers
GENERAL_ERROR:
msg_title: .... /admin/admin_proxy.php
msg_text: Unable to load recently used proxies
err_file: SELECT * FROM phpbb_proxies ORDER BY status ASC LIMIT 0, 15
err_line: 225
Database Error Array Information:
message: Unknown column 'status' in 'order clause'
code: 1054
"I have not failed.
I've just found 10,000 ways that won't work."
~ Thomas Edison

User avatar
KeusssiX
Registered User
Posts: 3
Joined: Thu Jan 11, 2007 12:20 am
Location: Lille, 59 France
Contact:

Post by KeusssiX » Thu Jan 11, 2007 12:44 am

I've searched the answer in this support but didn't found, so i post my question :
the mod seems to be correctly installed (2.2.1), there is no error message, but i still can't activate it. i've scanned several IP, information given seems correct, but then i return back to the panel to activate it, it seems to work, i go to the index of the forum, then i come back, and it's still desactivated...
and some open proxies succeed to register of course...

i've just checked the box Ban Open Proxies to yes, and here a message when i scan a random IP (there is some translations into french, that's the only modifications i've done : duplicate & translate the $lang lines and add to the french folder) :

Code: Select all

Check IP Address

Checking 66.197.255.229...
Hostname: 66-197-255-229.hostnoc.net

Connection Timeout (0)
 

Corriger l'information
Sample HTTP Request 1

    GET /forum/proxy/connect.php?address=66.197.255.229&port=6588 HTTP/1.0
    Host: www.toutalamaison.com
    User-Agent: phpBB Open Proxy Detector
    Connection: close

Sample HTTP Request 2

    Service Unavailable

    Suggestions: 

Sample SQL Query

Execution Time: 0.05ms
by the way, is it worth to update to the 3.0.0, and did you create a .txt to update to 2.2.1 to 3.0.0, because i'm not really good in SQL...

thx for your support.
Image toutalamaison.com le site de la maison et des services à domicile

TerraFrost
Former Team Member
Posts: 5957
Joined: Sun Dec 26, 2004 3:40 am
Location: Austin, TX

Post by TerraFrost » Thu Jan 11, 2007 2:25 am

KeusssiX wrote: the mod seems to be correctly installed (2.2.1), there is no error message, but i still can't activate it.

Since you're using 2.2.1, it's possible that the server is simply configured such that when the page loading stops, so to does the php's processing of the page. Alternatively, the DBMS may be set up to do some sort of caching.

3.0.0 includes more options, but... to be honest, I consider this MOD to be largely depreciated in favor of IP Unmasker. Unfortunately, users of IP Unmasker have found certain features of it to be somewhat confusing. I intend on releasing a new version of it, soon, but do not yet have an ETA.

User avatar
KeusssiX
Registered User
Posts: 3
Joined: Thu Jan 11, 2007 12:20 am
Location: Lille, 59 France
Contact:

Post by KeusssiX » Thu Jan 11, 2007 5:16 pm

TerraFrost wrote: Since you're using 2.2.1, it's possible that the server is simply configured such that when the page loading stops, so to does the php's processing of the page. Alternatively, the DBMS may be set up to do some sort of caching.

sorry, i don't understand, and especially what's the DBMS.
i see only one checkbox "Ban Open Proxies" which i check yes.
when i activate the "Block Open Proxy Registrants", i go on a page which says operation succeed, & click here to return, so i return : at this time, it seems activated (checkbox is correct), but when i quit this page & come back, in all case, it's deactivated...
Image toutalamaison.com le site de la maison et des services à domicile

TerraFrost
Former Team Member
Posts: 5957
Joined: Sun Dec 26, 2004 3:40 am
Location: Austin, TX

Post by TerraFrost » Thu Jan 11, 2007 5:19 pm

KeusssiX wrote: sorry, i don't understand, and especially what's the DBMS.

Database Management System. Examples include MySQL, PostgreSQL, Sybase, Oracle, DB2, MSSQL, etc.
i see only one checkbox "Ban Open Proxies" which i check yes.
when i activate the "Block Open Proxy Registrants", i go on a page which says operation succeed, & click here to return, so i return : at this time, it seems activated (checkbox is correct), but when i quit this page & come back, in all case, it's deactivated...

The MOD will continue to deactivate itself until you are able to successfully perform a test through the ACP. And, for whatever reason (maybe one of the above reasons I proposed is, in fact, the problem), tests aren't being successfully performed.

User avatar
KeusssiX
Registered User
Posts: 3
Joined: Thu Jan 11, 2007 12:20 am
Location: Lille, 59 France
Contact:

Post by KeusssiX » Thu Jan 11, 2007 7:27 pm

i don't understand. yep, it's working like i didn't performed a test through the ACP, but i did it. i have even the list by clicking on the link at the bottom...
for the server where i am, i use lots of mod and don't have any problem, except that i have sometimes to change some stuffs because it runs under IISS & ISAPI rewrite, but i don't see why it could be here a problem...
do u see something i could have forget, or a special case i could be ?
Image toutalamaison.com le site de la maison et des services à domicile

TerraFrost
Former Team Member
Posts: 5957
Joined: Sun Dec 26, 2004 3:40 am
Location: Austin, TX

Post by TerraFrost » Thu Jan 11, 2007 8:40 pm

KeusssiX wrote: i don't understand. yep, it's working like i didn't performed a test through the ACP, but i did it. i have even the list by clicking on the link at the bottom...

The fact that you have a list doesn't necessarily imply that it's working. The best determinant of whether or not it's working is the ACP test.
for the server where i am, i use lots of mod and don't have any problem, except that i have sometimes to change some stuffs because it runs under IISS & ISAPI rewrite, but i don't see why it could be here a problem...
do u see something i could have forget, or a special case i could be ?

This MOD usually isn't broken by other MODs - it's usually broken by server configurations. And unfortunately, I'm not sure what those server configurations are. I can describe the symptoms - and indeed, I attempt to check for them with this MOD - but knowing the symptoms and being able to diagnose the cause of those symptoms are two rather different things...

phpDummie
Registered User
Posts: 292
Joined: Thu Feb 16, 2006 12:09 am
Location: USA
Contact:

Post by phpDummie » Sat Jan 13, 2007 3:19 am

I installed this MOD today with no problem at all, checked my own IP trough the ACP and it didn't turn out to be an open proxy - no surprise there :roll:

It seems to be working since the list of checked IPs is growing, but I do have a question:

If I turn on the option to ban open proxy IPs, will those IPs show up in ACP banned list or anywhere else? How do I know that some IP actually got banned?

TerraFrost
Former Team Member
Posts: 5957
Joined: Sun Dec 26, 2004 3:40 am
Location: Austin, TX

Post by TerraFrost » Sat Jan 13, 2007 3:22 am

phpDummie wrote: If I turn on the option to ban open proxy IPs, will those IPs show up in ACP banned list or anywhere else? How do I know that some IP actually got banned?

Yup - they should show up in the ban list :)

User avatar
Star La
Registered User
Posts: 26
Joined: Mon Jul 03, 2006 1:39 pm
Location: London, UK

Post by Star La » Tue Jan 16, 2007 1:01 pm

Unable to load recently used proxies

DEBUG MODE

SQL Error : 1146 Table 'ct_phpbb.PROXY_TABLE' doesn't exist

Line : 421
File : SELECT * FROM PROXY_TABLE WHERE behavior >= PROXY_TRANSPARE AND behavior <> PROXY_ERROR ORDER BY last_checked DESC LIMIT 3


I ran the SQL query and double checked so I don't really know what to do next. Any idea?

Thanks,

TerraFrost
Former Team Member
Posts: 5957
Joined: Sun Dec 26, 2004 3:40 am
Location: Austin, TX

Post by TerraFrost » Tue Jan 16, 2007 6:25 pm

Looks like you didn't modify constants.php as appropriate.

User avatar
Star La
Registered User
Posts: 26
Joined: Mon Jul 03, 2006 1:39 pm
Location: London, UK

Post by Star La » Tue Jan 16, 2007 11:01 pm

ok now that i double checked that, thanks for the tip, i have come across another problem
$lang['Install_No_PCRE'] $lang['proxy_title'] = 'Block Open Proxy Registrants';
$lang['proxy_desc'] = 'This page will allow you to customize Block Open Proxy Registrants, to check individual IP addresses, and to view recently used proxies.';
$lang['proxy_desc_list'] = 'Lists recently tested IP addresses. Entries that specify a port number but not a proxy type represent IP addresses that were, during a prior test, open proxies.';
$lang['proxy_desc_test'] = 'Scans for proxies on the specified ports. Debug information can be found by clicking on the "Debug Information" text.';
$lang['proxy_test'] = 'Check IP Address';
$lang['proxy_test_desc'] = 'Checks whether or not an IP address of your chosing is a proxy using the current settings. Can conduct checks even when Block Open Proxy Registrants has been disabled.';
$lang['proxy_ip'] = 'IP Address';
$lang['proxy_enable'] = 'Block Open Proxy Registrants';
$lang['proxy_enable_desc'] = 'This MOD can only be enabled once a proxy has been successfully tested via the ACP.';
$lang['proxy_ban'] = 'Ban Open Proxies';
$lang['proxy_ban_explain'] = 'Bans IP addresses revealed to be open proxies.';
$lang['proxy_timeout'] = 'Connection Timeout';
$lang['proxy_timeout_explain'] = 'The larger the value, the more accurate proxy detection will be, but the longer the users attempting to register will have to wait.';
$lang['proxy_seconds'] = 'seconds';
$lang['proxy_minutes'] = 'minutes';
$lang['proxy_hours'] = 'hours';
$lang['proxy_days'] = 'days';
$lang['proxy_weeks'] = 'weeks';
$lang['proxy_months'] = 'months';
$lang['proxy_years'] = 'years';
$lang['proxy_type'] = 'Type';
$lang['proxy_last_checked'] = 'Last Checked';
$lang['proxy_port'] = 'Port';
$lang['proxy_ports'] = 'Ports to scan';
$lang['proxy_ports_explain'] = 'In theory, up to 64 ports can be simultaneously scanned, but in practice, the total number should be kept to a bare minimum. Also, changing the ports that are to be scanned will reset the cached data.';
$lang['proxy_cache_time'] = 'Cache Time';
$lang['proxy_cache_time_explain'] = 'Determines how frequently the same IP address will be checked. Entering 0 will result in IP addresses never being checked twice.';
$lang['proxy_user_agent'] = 'User Agent String';
$lang['proxy_user_agent_explain'] = 'Determines how HTTP requests ought to identify themselves when attempting to connect to a proxy.';
$lang['proxy_debug'] = 'Debug Information';
$lang['proxy_settings'] = 'MOD Configuration';
$lang['proxy_list_desc'] = 'Lists the three most recently confirmed proxies.';
$lang['proxy_sample_http_1'] = 'Sample HTTP Request 1';
$lang['proxy_sample_http_2'] = 'Sample HTTP Request 2';
$lang['proxy_sample_sql'] = 'Sample SQL Query';
$lang['proxy_exec_time'] = 'Execution Time';
$lang['proxy_none'] = 'No Proxy Severs Detected.';
$lang['proxy_connect_error'] = 'Unable to connect to %s to spawn processes<br /><b>Error %d</b>: %s';
$lang['proxy_testing'] = 'Checking <b>%s</b>...';
$lang['proxy_hostname'] = 'Hostname: <b>%s</b>';
$lang['proxy_check'] = 'Check';
$lang['proxy_view_list'] = 'View Complete List';
$lang['proxy_deleted'] = '%s has been deleted.';
$lang['proxy_download'] = 'Download As Text';
$lang['proxy_return'] = 'Click %sHere%s to return to the previous page.';
$lang['proxy_name'] = 'Block Open Proxies';
$lang['proxy_show'] = 'Show';
$lang['proxy_suggestions'] = 'Suggestions';
$lang['proxy_error99'] = 'Just remove lines 26-32 in connect.php to bypass this problem. The reason they\'re not removed by default is because they work on <i>most</i> servers and because without them, people could, in theory, use your servers resources to build their own proxy lists';
$lang['proxy_error302'] = 'This error can occur when the domain name used by the board (domain.tld, as an example) redirects all requests to another domain (say www.domain.tld). If this is the case, you will need to use the latter domain with phpBB - not the former.';
$lang['proxy_error403'] = 'If you have configured the server (via .htaccess, or whatever) to restrict access to this directory, you\'ll need unrestrict access for this MOD to work.';
$lang['proxy_error404'] = 'There are two possible solutions for this problem<blockquote>1. Create a proxy subdirectory and upload the appropriate files in it.<br />2. Replace all occurances of <i>trim($board_config[\'server_name\']))</i> with <i>127.0.0.1</i>. The reason this isn\'t done by default is that it doesn\'t work on virtual hosts</blockquote>';
$lang['proxy_error500'] = 'Your server is misconfigured. Due to the multitude of ways in which it could be misconfigured, I can\'t really say much more than that...'; = 'phpBB2 Requires the Perl-Compatible Regular Expressions Module for PHP which your PHP configuration doesn\'t appear to support!';



The error I get is;
Parse error: syntax error, unexpected T_VARIABLE in /home3/ctimiami/public_html/forum/language/lang_english/lang_admin.php on line 748

line 748 being the first line you see in the quote.

Thanksm,

TerraFrost
Former Team Member
Posts: 5957
Joined: Sun Dec 26, 2004 3:40 am
Location: Austin, TX

Post by TerraFrost » Tue Jan 16, 2007 11:27 pm

From your code...

Code: Select all

$lang['Install_No_PCRE'] $lang['proxy_title'] = 'Block Open Proxy Registrants'; 
You didn't do an AFTER, ADD. You do an IN-LINE AFTER, ADD. This KB article discusses the differences.

zeitlin
Registered User
Posts: 24
Joined: Thu Oct 13, 2005 1:51 am

Post by zeitlin » Sat Feb 03, 2007 9:31 pm

In your installation instructions for the proxy MOD, you have:

#-----[ SQL ]-------------------------------------------
#
INSERT INTO phpbb_config (config_name, config_value) VALUES ('proxy_enable',2);
INSERT INTO phpbb_config (config_name, config_value) VALUES ('proxy_ban',0);
INSERT INTO phpbb_config (config_name, config_value) VALUES ('proxy_delay',1);
INSERT INTO phpbb_config (config_name, config_value) VALUES ('proxy_ports','005008fd0c3819bc1f401f90');
INSERT INTO phpbb_config (config_name, config_value) VALUES ('proxy_cache_time',0);
INSERT INTO phpbb_config (config_name, config_value) VALUES ('proxy_block',1);
INSERT INTO phpbb_config (config_name, config_value) VALUES ('proxy_sort','last_checked,DESC');
INSERT INTO phpbb_config (config_name, config_value) VALUES ('proxy_user_agent','phpBB Open Proxy Detector');
CREATE TABLE phpbb_proxies (
ip_address char( DEFAULT '0' NOT NULL,
behavior tinyint(2) DEFAULT '0' NOT NULL,
port char(4) DEFAULT '0' NULL,
last_checked int(11) DEFAULT '0' NOT NULL,
PRIMARY KEY (ip_address)
);


I'm unclear how to use this. My best guess is that this gets added to the end of the file update_to_latest.php in my local folder 2.0.21_to_2.0.22\install that was part of the latest update package. Then perhaps I am to upload that file and execute it.

Is this correct? I am very nervous about taking this step on the basis of a mere guess.

I mentioned in another question outside this thread that I'm looking at EasyMOD but that makes me nervous too. Do you recommend using this?

EasyMOD raises questions not related to this thread, such as what you do when phpBB is upgraded. Do changes in the SQL that were made by EasyMOD remain there when the database is upgraded?

Thanks

TerraFrost
Former Team Member
Posts: 5957
Joined: Sun Dec 26, 2004 3:40 am
Location: Austin, TX

Post by TerraFrost » Sat Feb 03, 2007 9:45 pm

zeitlin wrote: In your installation instructions for the proxy MOD, you have:

#-----[ SQL ]-------------------------------------------
#
INSERT INTO phpbb_config (config_name, config_value) VALUES ('proxy_enable',2);
INSERT INTO phpbb_config (config_name, config_value) VALUES ('proxy_ban',0);
INSERT INTO phpbb_config (config_name, config_value) VALUES ('proxy_delay',1);
INSERT INTO phpbb_config (config_name, config_value) VALUES ('proxy_ports','005008fd0c3819bc1f401f90');
INSERT INTO phpbb_config (config_name, config_value) VALUES ('proxy_cache_time',0);
INSERT INTO phpbb_config (config_name, config_value) VALUES ('proxy_block',1);
INSERT INTO phpbb_config (config_name, config_value) VALUES ('proxy_sort','last_checked,DESC');
INSERT INTO phpbb_config (config_name, config_value) VALUES ('proxy_user_agent','phpBB Open Proxy Detector');
CREATE TABLE phpbb_proxies (
ip_address char( DEFAULT '0' NOT NULL,
behavior tinyint(2) DEFAULT '0' NOT NULL,
port char(4) DEFAULT '0' NULL,
last_checked int(11) DEFAULT '0' NOT NULL,
PRIMARY KEY (ip_address)
);


I'm unclear how to use this. My best guess is that this gets added to the end of the file update_to_latest.php in my local folder 2.0.21_to_2.0.22\install that was part of the latest update package. Then perhaps I am to upload that file and execute it.

Is this correct? I am very nervous about taking this step on the basis of a mere guess.

That might work (I don't know), but I wouldn't recommend it. Instead, I would recommend doing the queries through something like phpMyAdmin, EasyMOD, or plugging them into this tool.
I mentioned in another question outside this thread that I'm looking at EasyMOD but that makes me nervous too. Do you recommend using this?

I use it :)
EasyMOD raises questions not related to this thread, such as what you do when phpBB is upgraded. Do changes in the SQL that were made by EasyMOD remain there when the database is upgraded?

I guess that really depends on what you mean by upgraded. If you mean... can you upgrade from 2.0.21 to 2.0.22 (or whatever) and still expect EasyMOD's changes to be there, the answer is yes.

Post Reply

Return to “[2.0.x] MOD Database Releases”