Post Pacific  

Go Back   Post Pacific > Восстановленный архив > Темы без сохранившегося раздела

Notices

 
 
Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
Old 06.05.2005, 19:40   #4
porkmaster
Архивный участник
 
Join Date: Feb 2005
Posts: 11
Default

Allright, here's an easy way to block out ip addresses on windows.
It does not require very much knowledge and you need some *nix tools ported on mswin.

The tools you're going to need are:
- wipfw (ipfw port for windows) - http://wipfw.sourceforge.net
- winbash (bourn again shell port for windows) http://winbash.tigris.org/servlets/ProjectDocumentList

Download wipfw and bash.exe and put the binaries in one directory.
In the same directory, make a file called "blocked.txt".
Add the IP addresses you want to block in that file, one IP address/subnet on a line.
You can use the IANA network naming convention - this means that:
1.2.3.4 = one IP address
1.2.3.0/24 = class C - from 1.2.3.0 to 1.2.3.255
(google up if you need more info)

Create a file named firewall.sh that should look like this:
Code:
#!/the/dir/where/you/have/bash.exe
wipfw flush
for subnet in $(cat blocked.txt); do
 wipfw add deny ip from $subnet to any
done
Note that this script will prompt you for a "yes/no" each time you run `wipfw flush` (you gotta dig up a bit to see how you can cancel that out ).

So, each time you're starting up the machine or adding/removing ip addresses to/from the blocklist, go in to that directory and run:
bash firewall.sh

(you may set up .sh file to be opened by bash).

Further improvements can be done with a bit of RTFM also
This will secure all ports, not only 2106 (authd) port.

Friendly warning: do not have a VERY LARGE NUMBER of IP addresses to block.
porkmaster is offline  
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 21:05.