Posts Tagged ‘Internet’

How to reduce spam in PHPBB based internet forum on Debian GNU / Linux

Monday, March 26th, 2012

phpbb reduce spam bot registrations on Debian Linux tiny script

I had to install two PHPBB based internet forums, some long time ago. Since long time passed and I haven't checked what's happening with them I just noticed. They start filling up spam threads. The phpbb installations are done using the standard shipped deb packages in Debian Linux Lenny.

After checking online, I found one smart solution to . The idea is very simple most spam bots are written in a way that they don't have a properly set timezone. Therefore the quickest way to get rid of spam bots which try to auto register and put spam content inside the a forum category or post is to add a simple if condition in php to check the browser set timezone:

The file to add the php if condition is ucp_register.phpThe phpbb package install places default phpbb path on Debian is /usr/share/phpbb3/ and hence the file I had to modify is located in:

/usr/share/phpbb3/www/includes/ucp/ucp_register.php

To make the TZ check one needs to modify ../www/includes/ucp/ucp_register.php and look for php array definition:

$data = array(
'username' => utf8_normalize_nfc(request_var('username', '', true)),
'new_password' => request_var('new_password', '', true),
'password_confirm' => request_var('password_confirm', '', true),
'email' => strtolower(request_var('email', '')),
'email_confirm' => strtolower(request_var('email_confirm', '')),
'confirm_code' => request_var('confirm_code', ''),
'lang' => basename(request_var('lang', $user->lang_name)),
'tz' => request_var('tz', (float) $timezone),
);

Right after this chunk of code add the if condition code which is like so:

if ($data['tz'] == '-12.00')
{
die('Die, bot! Die.');
}

From now onwards, any attempt for new user registration with an incorrect timezone of -12.00 will be immediately stopped while the forum spammer bot will be offered an empty page 🙂

Another good practice is to disable Birthday Listing from phpbb Admin Control panel (ACP). Go to menus:

ACP -> General -> Board Settings -> Enable Birthday listing: (No)

Enable birthday listing phpbb forum screenshot

I like disabling birthday listing, as when it is enabled and you have some spammer registrations, which even though didn't succeeded to contaminate your forum content has specified a birthday and therefore there profiles gets popping up each different day on the main page of the forum.
This will not eradicate all spammer bots, but at least will significantly decrease spammer bot registrations.

Configure HAN Wireless WI-FI Internet on Windows XP/ Vista / 7 and Linux (Wireless Internet in Arnhem Business School)

Thursday, October 28th, 2010

It’s so annoying. Everytime you need to configure your internet at HAN (Arnhem Business School) you have to go to the Computer Center and look for the university IT support to just install you a simple program.

For one or another reason this guys has decided to use a strange encryption protocol which is an add on over the normal Wireless Connection.
Thus to properly connect to the Internet with your Notebook running Microsoft Windows or Microsoft XP or probably Windows 7 you have to install a software called SecureW2

Since I believe many students at HAN / Arnhem Business School (ABS) had to reinstall their Windows or has to do some routine thing like reinstalling completely the Wireless Network drivers on their PCs.
Then you certainly need the SecureW2 program and then again you have to go to this Computer Center instead of being able to simply do it on your own.

Therefore I decided to share here the complete SecureW2 software they use here in Hogelschool van Arnhem en Nijmegen

You can download the Wireless Internet Configuration Software for Arnhem Business School (ABS) / HAN here
Above I share all the versions of the program I have for both Windows XP / Vista and 7.
However for those who want to download the SecureW2 HAN Wireless Internet Configuration program file by size please check here

The program is also coming with documentation and manual even 🙂
So after downloading the SecureW2 and going to HAN at school then you can configure the program on your own.

Apart from that you might also want to check my previous post where I have explained how to configure the Wireless Network to work with Anrhem Business School’s Internet on my Debian Linux

Configure Wireless Internet on Linux in Arnhem Business School ( Hogelschool van Arnhem and Nijmegen ).

Wednesday, September 24th, 2008

I was able to configure SecureW2′s Wireless Internet within ABS (Arnhem Business School) on Linux. By taking some time to experiment. Here is how I did it.
1. You’ll need the package wpasupplicant
2. Use wpa_supplicant.conf configuration like this one:

ctrl_interface=/var/run/wpa_supplicantctrl_interface_group=0eapol_version=1ap_scan=1#fast_reauth=1network={         ssid=”han”         scan_ssid=1         key_mgmt=IEEE8021X         eap=TTLS         phase2=”auth=PAP”         identity=”your_username”         password=”yoursecretpass”         priority=100}

Put the above configuration in let’s say /etc/ under the name wpa_supplicant.conf
Create a script han-internet.sh, put the following within the script

#!/bin/sh# Written by hip0 23.09.2008# Under GPL v2# Read it here http://gnu.org/licenses/gpl2.txt# kill any existing instances of wpa_supplicant or dhclient if [[ $(ps ax |grep -i dhclient|grep -v grep) ]]; thenkillall -9 dhclient >/dev/null 2>&1[[ $(ps ax |grep -i wpa_supplicant|grep -v grep) ]]; thenkillall -9 wpa_supplicant >/dev/null 2>&1fi# initialize connection to the HAN wireless APwpa_supplicant -B -i wlan0 -D wext -c /etc/wpa_supplicant.confsleep 5;dhclient -nw wlan0 >/dev/null 2>&1

If you’re a debian user you could configure your machine to connect to yourwireless network during boot:
To do this you have to:
Edit /etc/network/interfaces
Add something similar in it:

iface wlan0 inet dhcppre-up wpa_supplicant -B -D wext -i wlan0 -c /etc/wpa_supplicant.confpre-down killall -9 wpa_supplicantpre-down killall -9 dhclient

Don’t forget to change your interface name mine is wlan, yours could be different
3. Enjoy your Wireless Internet within the HAN building! 🙂
P.S. I configured that on my Debian 4.0 system, but I think t would work with any other Linux/BSD system out thereEND—–

Configuring easy access and Internet keyboards on Linux (lineak)

Saturday, October 3rd, 2009

I’ve bough a media keyboard yesterday, since I ran Debian I needed
a way to configure my keyboard. After some research online I found lineak .
Lineak does have support already for many Linux keyboards key sets.
However my keboard Delux K5201 was not supported. Thus I’ll now
follow the documentation to make it fully work with my Debian Linux.
Anyways surely the project will be helpful for many whose keyboards
are supported on Linux through lineak.
Seems that most of the easy access keys on my Delux K5201 kbd are workingcorretcly. 70% out of all the easy access keys are working out of the box.The keys that don’t work and are most vital are the “Shutdown Button” andthe “Mail button”.END—–