Home   Help Login Register  
Welcome, Guest. Please login or register.

Login with username, password and session length

Search
Free Website WooThemes - Quality Themes, Great Support
Pages: [1]   Go Down
Print
Topic: block IP address in the server  (Read 3493 times)
« on: June 24, 2009, 10:33:51 PM »
w3school Offline
Newbie

View Profile
*

iTrader: 0
Posts: 26



How can I block the IP addresses so that no one can access the server or sites from those IP addresses? I want block some IP addresses on my Red hat Linux (cPanel) box.

Thanks,

w3school

Share this topic on AskShare this topic on BlinkbitsShare this topic on BlinklistShare this topic on BloglinesShare this topic on BmarksShare this topic on Del.icio.usShare this topic on DiggShare this topic on DzoneShare this topic on FacebookShare this topic on Feed Me LinksShare this topic on FurlShare this topic on GoogleShare this topic on LiveShare this topic on MagnoliaShare this topic on MySpaceShare this topic on NetvouzShare this topic on NewsvineShare this topic on OneviewShare this topic on RedditShare this topic on RojoShare this topic on ScuttleShare this topic on ShadowsShare this topic on SlashdotShare this topic on SpurlShare this topic on SquidooShare this topic on StumbleUponShare this topic on TechnoratiShare this topic on TwitterShare this topic on TipdShare this topic on YahooShare this topic on Google buzz
Logged
« Reply #1 on: June 24, 2009, 10:37:15 PM »
Kailash Offline
Administrator
Newbie

View Profile WWW
*****

iTrader: 50
Posts: 285



You can use one of the following Firewall on your server:

[1] ConfigServer Security and Firewall
For more details on ConfigServer Security and Firewall, visit http://www.configserver.com/cp/csf.html

[2] APF
For APF installation, you can refer http://www.webhostgear.com/61.html

Also, if you want to block the IP address for one particular site then you can do it via .htaccess file. You just need to add following directive to block the IP address:

Code:
deny from IP address

Kailash
Logged

« Reply #2 on: June 24, 2009, 10:39:03 PM »
digitalpoint Offline
Newbie

View Profile
*

iTrader: 0
Posts: 46



Can we block the IP range for particular web site using .htaccess ?

Thanks,

Digitalpoint
Logged
« Reply #3 on: June 24, 2009, 10:40:27 PM »
Kailash Offline
Administrator
Newbie

View Profile WWW
*****

iTrader: 50
Posts: 285



Can we block the IP range for particular web site using .htaccess ?
Yes, you can. Just add following line:

deny from x.x.x.x-x.x.x.x

If you want to block just on IP range, you can do it using following:

deny from 192.168

It will block the access for 192.168.0.0 to 192.168.255.255

Kailash
Logged

« Reply #4 on: September 15, 2010, 03:48:02 AM »
Web Hosting In India
brainpulse Offline
Newbie

View Profile WWW
*

iTrader: 0
Posts: 14



Interesting solution via .htaccess,

thanks kailash

Logged
Pages: [1]   Go Up
Print
Jump to:  

Untitled Document
(c) 2010 HELM, WHM, cPanel, ASP, .Net development, PHP, MySQL, MSSQL Server, SEO support forum
Powered by SMF 1.1.16 | SMF © 2011, Simple Machines | Forum style designed by PixelSlot
Web Hosting - Sitemap - XML Sitemap