Solved

Linux firehol/iptables on server

Posted on 2010-11-10
4
645 Views
Last Modified: 2012-05-10
Hi,

I have been looking different firewalls for Linux Centos 5.5 and have decided that firehol will be the easiest way to implement iptables.
However I need help configuring it. This is my senario...

I have a (physical) server sitting in a datacenter, it has one Ethernet network connection (to the internet). The server will be running VoIP for around 20 businesses so I want to restrict access to the server based on IP addresses as well as ports, as all the customers will have static IP Addresses.
So only authorized customers will be able to access the server and then only to authorized ports.

How would I accomplish this using iptables and firehol?

Thanks
0
Comment
Question by:mark_06
4 Comments
 
LVL 26

Expert Comment

by:jar3817
Comment Utility
Just skip firehol and edit the /etc/sysconfig/iptables file directly to build your firewall. For example:

-A INPUT -s <source IP here> -m state --state NEW -m tcp -p tcp --dport <tcp port here> -j ACCEPT

Please don't take this the wrong way, but if you don't know linux basics like iptables, you have no business hosting phone services to other businesses. Voice is a mission critical application, you REALLY need to know what you're doing when providing a service like that. Imagine if there is an emergency and people can't dial 911 because you didn't configure something right...
0
 
LVL 16

Accepted Solution

by:
Blaz earned 500 total points
Comment Utility
I normally use iptables direclty but if you minsist on using firehol then the sintax should be something like:
interface eth0 internet
      server <service_name>  accept src "IP1 IP2 IP3 ..."

service_name is your service if found on list: http://firehol.sourceforge.net/services.html. Otherwise you have to define it: http://firehol.sourceforge.net/adding.html

You will probably also accept some ssh traffic from your IP and other
0
 
LVL 6

Author Comment

by:mark_06
Comment Utility
Hi jar3817, I understand where you are coming from regarding Linux. A project like this is a team effort, not a one man job. I am a Cisco man myself I would consider myself an expert on VoIP, it's just linux isn't my platform. I am  working on this with another person who is a Linux guru, however he is away for a few weeks and I don't want to wait for him to get back before I start internal testing, but then I don't want to make the server live without restricting access to it.

Thanks for your suggestions guys I will give them a go!
0
 
LVL 4

Expert Comment

by:AbhisekSanyal
Comment Utility
Hi,
  I would suggest using Shorewall. It has a simple configuration syntax and is well supported by the community.
0

Featured Post

Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

Join & Write a Comment

Note: for this to work properly you need to use a Cross-Over network cable. 1. Connect both servers S1 and S2 on the second network slots respectively. Note that you can use the 1st slots but usually these would be occupied by the Service Provide…
BIND is the most widely used Name Server. A Name Server is the one that translates a site name to it's IP address. There is a new bug in BIND (https://kb.isc.org/article/AA-01272), affecting all versions of BIND 9 from BIND 9.1.0 (inclusive) thro…
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now