Latest LQ Deal: Linux Power User Bundle
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 04-17-2015, 07:55 AM   #1
LQ Newbie
Registered: Mar 2015
Posts: 9

Rep: Reputation: Disabled
Unhappy Problem with Firewall. :(

i have a index page in /var/www/html, from the local machine i can open the page as localhost or the machine name even the firewall is on or off, But when i type the ip of the machine in another LAN pc it automautically navigate to another folder say like enter -> and gives out 404 error when the firewall is up but i get the page when the firewall is down what do i do?
Old 04-17-2015, 08:35 AM   #2
Registered: Sep 2003
Location: Texas
Distribution: Red Hat/CentOS
Posts: 295
Blog Entries: 3

Rep: Reputation: Disabled
Adjust your firewall to account for the web traffic. man iptables.
Old 04-17-2015, 06:25 PM   #3
Registered: Jul 2012
Location: Aachen, Germany
Distribution: Void, Debian
Posts: 824

Rep: Reputation: 237Reputation: 237Reputation: 237
You need to allow inbound traffic on ports 80 (http) and 443 (https)

Something like this in your iptables config script:
/sbin/iptables -I INPUT -p tcp -m multiport --dports 80,443 -j ACCEPT -m comment --comment "Allow outbound http and https"
Then you might also need to allow the established connections to go back out:

/sbin/iptables -I OUTPUT -m state --state ESTABLISHED,RELATED -j ACCEPT
Note the -I flags are inserting the rules at the beginning of the rule chain. This is to make sure they will actually be applied before some other rejection rules kick in.

Now depending on your setup you may want to use the -A flag (append) and place the rules at a specific location in your overall config.

These are just examples that may open holes that are larger than you want them to be. If you post your current config and provide more input on what traffic you want to be blocked more detailed advice could be given...


apache, http, httpd, httpdconf

Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Firewall problem? Marc-ahs Linux - Newbie 8 03-19-2009 08:34 AM
Firewall problem Rayskovsky Linux - Networking 1 01-23-2009 08:27 PM
firewall problem? holden94122 Linux - Networking 4 07-26-2005 09:08 PM
firewall problem ? CavRider Slackware 4 12-13-2003 05:17 PM
Problem with FireWall??? please help! latehit Linux - Security 1 12-14-2002 03:27 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 01:04 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration