<div dir="ltr"><div class="gmail_default" style="font-family:trebuchet ms,sans-serif">No, I think the rules you created might have a better place in a custom xml file instead of being given to firewall cmd directly :)</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, 26 Apr 2019 at 23:01, Kimberlee Integer Model <<a href="mailto:kimee.i.model@gmail.com">kimee.i.model@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">I'm not sure I follow, you just think the modified one should be called<br>
"ssh-custom", or you think there shouldn't be a modified service file<br>
at all?<br>
<br>
-- Kimee<br>
<br>
On Fri, 2019-04-26 at 19:46 +0200, Thibaut Perrin wrote:<br>
> Hi there,<br>
> <br>
> Wouldn't that be a better solution to create a custom xml file to put<br>
> in /etc/firewalld and load that "ssh-custom" service instead ?<br>
> <br>
> Thanks<br>
> <br>
> On 26/04/2019, Kimberlee Integer Model <<a href="mailto:kimee.i.model@gmail.com" target="_blank">kimee.i.model@gmail.com</a>><br>
> wrote:<br>
> > Thank you, I've gone in and made the listed changes changed<br>
> > firewalld<br>
> > sections to use services instead of just port numbers.<br>
> > <br>
> > -- Kimee<br>
> > <br>
> > <br>
> > On Wed, 2019-04-24 at 17:05 -0700, Akemi Yagi wrote:<br>
> > > On Wed, Apr 24, 2019 at 12:13 AM Kimberlee Integer Model<br>
> > > <<a href="mailto:kimee.i.model@gmail.com" target="_blank">kimee.i.model@gmail.com</a>> wrote:<br>
> > > > <br>
> > > > HI all,<br>
> > > > <br>
> > > > 1st time contributor here. I was using the guide on securing<br>
> > > > SSH,<br>
> > > > and<br>
> > > > noticed that the firewall-cmd snippets for filtering by<br>
> > > > requests<br>
> > > > per<br>
> > > > time seem somewhat outdated. From what I can tell the given<br>
> > > > snippets,<br>
> > > > relay arguments directly down to iptables, and do not cover<br>
> > > > both<br>
> > > > IPv4<br>
> > > > and v6. (and in fact when attempting to extend to v6 the<br>
> > > > firewall<br>
> > > > would<br>
> > > > fail to reload). I came up with an "all firewall-cmd" solution<br>
> > > > which<br>
> > > > I'd like to share.<br>
> > > > <br>
> > > > It boils down to using rich rules in firewalld instead of<br>
> > > > direct<br>
> > > > rules<br>
> > > > for iptables. The code snippets in section 6 of <<br>
> > > > <a href="https://wiki.centos.org/HowTos/Network/SecuringSSH" rel="noreferrer" target="_blank">https://wiki.centos.org/HowTos/Network/SecuringSSH</a>>;; would be<br>
> > > > changed to<br>
> > > > <br>
> > > > firewall-cmd --permanent --add-rich-rule='rule port port="22"<br>
> > > > protocol="tcp" accept limit value="4/m"'<br>
> > > > firewall-cmd --permanent --remove-service ssh<br>
> > > > firewall-cmd --permanent --remove-port 22/tcp<br>
> > > > firewall-cmd --reload<br>
> > > > <br>
> > > > newly minted wiki username is "KimeeModel".<br>
> > > > <br>
> > > > Regards,<br>
> > > > Kimee<br>
> > > <br>
> > > You should be able to edit that page. Let us know if you find any<br>
> > > problem.<br>
> > > <br>
> > > Akemi<br>
> > > _______________________________________________<br>
> > > CentOS-docs mailing list<br>
> > > <a href="mailto:CentOS-docs@centos.org" target="_blank">CentOS-docs@centos.org</a><br>
> > > <a href="https://lists.centos.org/mailman/listinfo/centos-docs" rel="noreferrer" target="_blank">https://lists.centos.org/mailman/listinfo/centos-docs</a><br>
> > <br>
> > _______________________________________________<br>
> > CentOS-docs mailing list<br>
> > <a href="mailto:CentOS-docs@centos.org" target="_blank">CentOS-docs@centos.org</a><br>
> > <a href="https://lists.centos.org/mailman/listinfo/centos-docs" rel="noreferrer" target="_blank">https://lists.centos.org/mailman/listinfo/centos-docs</a><br>
> > <br>
> <br>
> _______________________________________________<br>
> CentOS-docs mailing list<br>
> <a href="mailto:CentOS-docs@centos.org" target="_blank">CentOS-docs@centos.org</a><br>
> <a href="https://lists.centos.org/mailman/listinfo/centos-docs" rel="noreferrer" target="_blank">https://lists.centos.org/mailman/listinfo/centos-docs</a><br>
<br>
_______________________________________________<br>
CentOS-docs mailing list<br>
<a href="mailto:CentOS-docs@centos.org" target="_blank">CentOS-docs@centos.org</a><br>
<a href="https://lists.centos.org/mailman/listinfo/centos-docs" rel="noreferrer" target="_blank">https://lists.centos.org/mailman/listinfo/centos-docs</a><br>
</blockquote></div>