Re: Problem with iptables

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Jun 30, 2014 at 7:04 PM, Pete Travis <lists@xxxxxxxxxxxxxx> wrote:


On Jun 30, 2014 6:51 PM, "JD" <jd1008@xxxxxxxxx> wrote:
>
> ​​
> On Mon, Jun 30, 2014 at 6:28 PM, Ed Greshko <ed.greshko@xxxxxxxxxxx> wrote:
> >
> > On 07/01/14 08:11, JD wrote:
> >
> > Hi all,
> > When I run /sbin/system-config-services
> > I see that iptables is enabled, and that
> > /etc/sysconfig/iptables contains the rules
> > I want.
> >
> > However, after bootup, I open a terminal and
> > run iptables -L -n
> > and do not see those rules at all, and all
> > the rules are in "ACCEPT" state.
> >
> > I have to resort to start iptables manually
> > in order to install the rules I have in
> > /etc/sysconfig/iptables.
> >
> > So, what needs to be done to force iptables to run
> > and to use the rules I have in the iptables file?
> >
> >
> >
> >
> >
> > Directly after a reboot I would run....
> >
> > systemctl status iptables.service
> >
> > And, yeah, your emails are a bit hard to read.
> >
>
> # systemctl status iptables.service
> iptables.service - IPv4 firewall with iptables
>    Loaded: loaded (/usr/lib/systemd/system/iptables.service; enabled)
>    Active: inactive (dead)
>
> # iptables -L -n                                        ....
>
> --------------------------
>
> What I have in /etc/sysconfig/iptables:
> # Firewall configuration written by system-config-firewall
> # Manual customization of this file is not recommended.
> *filter
> :INPUT
> ACCEPT[0:0]
> :FORWARD ACCEPT [0:0]
> :OUTPUT ACCEPT [0:0]
> -A INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT
> -A INPUT -m state --state NEW -j DROP
> COMMIT
>
> --
>

Congrats, you've created a firewall ruleset just like the default, but without ssh. You could have:
`firewall-cmd --remove-service ssh --permanent `

You can read about firewalld at https://fedoraproject.org/wiki/FirewallD . If you prefer to disable firewalld and use iptables, there are instructions on the same page.

-


​I am not familiar with firewalld (yet).
But it was enbled by default, and I think that
is what was the culprit, since I had not created
any rulesets for it.
I just disabled it, and will spend some time studying
ruleset creation for it.
By the way, why would I need a rule to allow sshd?
I never ssh into my machine from other computers.

Thanks for the heads up.
 
-- 
users mailing list
users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Fedora Code of Conduct: http://fedoraproject.org/code-of-conduct
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
Have a question? Ask away: http://ask.fedoraproject.org
[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux