Hello. In a situation like this: - a firewall has two or more internet connections, - a firewall runs shorewall 4.5.1 (multiple isps configured) - one connection is broken, - default route in the main routing table leads through the failed connection, - a firewall is 20000 km away from admin ;), and after taking the following actions: - logging in to the firewall through working connection, - changing shorewall configuration and making a stupid error in it - doing "shorewall stop; shorewall start" :s, you must take nearest flight from Europe to Australia to bring the firewall back to life ;) (because returning traffic goes through default, non-working link) Can shorewall handle such cases in a way, which would prevent similar accidents ? Did I miss any option ? If the above scenario was never considered - may I ask to add a possibility to retain appropriate route rules and routing tables after shorewall is stopped ? (extended routestopped functionality ?) Regards. -- Artur ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today''s security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
On Thu, May 24, 2012 at 11:24:32AM +0200, Artur Uszyński wrote:> Hello. > > In a situation like this: > - a firewall has two or more internet connections, > - a firewall runs shorewall 4.5.1 (multiple isps configured) > - one connection is broken, > - default route in the main routing table leads through the failed connection, > - a firewall is 20000 km away from admin ;), > > and after taking the following actions: > - logging in to the firewall through working connection, > - changing shorewall configuration and making a stupid error in it > - doing "shorewall stop; shorewall start" :s, > > you must take nearest flight from Europe to Australia to bring the firewall back to life ;) (because returning traffic goes through default, non-working link) > > Can shorewall handle such cases in a way, which would prevent similar accidents ? Did I miss any option ? > If the above scenario was never considered - may I ask to add a possibility to retain appropriate route rules and routing tables after shorewall is stopped ? (extended routestopped functionality ?) >Did you mean to execute ''shorewall safe-restart'' instead? Regards, -Roberto -- Roberto C. Sánchez http://people.connexer.com/~roberto http://www.connexer.com ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today''s security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
Hi All On 05/24/12 11:24, Artur Uszyński wrote:> Hello. > > In a situation like this: > - a firewall has two or more internet connections, > - a firewall runs shorewall 4.5.1 (multiple isps configured) > - one connection is broken, > - default route in the main routing table leads through the failed connection, > - a firewall is 20000 km away from admin ;),And here I complain about a customer 200Km away! Only ever had one emergency trip there to phix a typo I made! I strangled the ingress shaping to 500 bits per second instead of 500K!> and after taking the following actions: > - logging in to the firewall through working connection, > - changing shorewall configuration and making a stupid error in it > - doing "shorewall stop; shorewall start" :s, > > you must take nearest flight from Europe to Australia to bring the firewall back to life ;) (because returning traffic goes through default, non-working link) > > Can shorewall handle such cases in a way, which would prevent similar accidents ? Did I miss any option ? > If the above scenario was never considered - may I ask to add a possibility to retain appropriate route rules and routing tables after shorewall is stopped ? (extended routestopped functionality ?)Do you not have a pair of smart hands that you could use? I have successfully brought a system back to life by working step by step with the company owner as she typed what I told her! One trick I have learnt is to force a backdoor route just in case and even if that does mean customer hopping! Cheers Ang -- Angela Williams angierfw at gmail dot com Linux/Networking Hacker Blog http://angierfw.wordpress.com Smile! Yeshua Loves You! ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ _______________________________________________ Shorewall-users mailing list Shorewall-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/shorewall-users
I have ip static on the wan side. When i stop shorewall i only stop the lan side and i can still connecting over wan side (from another site) and over lan if i am working in the same place. I only put on /etc/shorewall/routestopped this line eth0 - Where eth0 is my LAN nic. Regards! Emiliano Vazquez | PcCentro S.R.L. Callao 80 | CP 1022 | C.A.B.A. Office: +54 (11) 4951-0203 / 4155 Celular: 15.6253.7165 Mail: emilianovazquez@gmail.com Web: http://www.pccentro.com.ar -----Original Message----- From: Artur Uszyski <arus@so.com.pl> Date: Thu, 24 May 2012 11:24:32 To: Shorewall Users<shorewall-users@lists.sourceforge.net> Reply-To: Shorewall Users <shorewall-users@lists.sourceforge.net> Subject: [Shorewall-users] Absent-minded admin + multi isp Hello. In a situation like this: - a firewall has two or more internet connections, - a firewall runs shorewall 4.5.1 (multiple isps configured) - one connection is broken, - default route in the main routing table leads through the failed connection, - a firewall is 20000 km away from admin ;), and after taking the following actions: - logging in to the firewall through working connection, - changing shorewall configuration and making a stupid error in it - doing "shorewall stop; shorewall start" :s, you must take nearest flight from Europe to Australia to bring the firewall back to life ;) (because returning traffic goes through default, non-working link) Can shorewall handle such cases in a way, which would prevent similar accidents ? Did I miss any option ? If the above scenario was never considered - may I ask to add a possibility to retain appropriate route rules and routing tables after shorewall is stopped ? (extended routestopped functionality ?) Regards. -- Artur ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today''s security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ _______________________________________________ Shorewall-users mailing list Shorewall-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/shorewall-users ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today''s security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
On 05/24/2012 02:24 AM, Artur Uszyński wrote:> Hello. > > In a situation like this: > - a firewall has two or more internet connections, > - a firewall runs shorewall 4.5.1 (multiple isps configured) > - one connection is broken, > - default route in the main routing table leads through the failed connection, > - a firewall is 20000 km away from admin ;), > > and after taking the following actions: > - logging in to the firewall through working connection, > - changing shorewall configuration and making a stupid error in it > - doing "shorewall stop; shorewall start" :s, > > you must take nearest flight from Europe to Australia to bring the firewall back to life ;) (because returning traffic goes through default, non-working link) > > Can shorewall handle such cases in a way, which would prevent similar accidents ? Did I miss any option ?A couple of things: a) Before making a configuration change, execute 'shorewall save'. This will save the currently running configuration which can then be restored if a 'restart' fails. b) Use 'shorewall restart' rather than 'shorewall stop; shorewall start'. 'shorewall stop' restores the default route(s) that were in place before the last 'start' command. 'shorewall restart' replaces, adds or deletes default routes based on the state of the links. And if the 'restart' fails, the firewall will be restored to its prior state. c) After you are satisfied that the change works correctly, do another 'shorewall save'. Note: As someone noted in another response to your post, the 'safe-restart' command combines 'save' and 'restart' in a single command. -Tom -- Tom Eastep \ When I die, I want to go like my Grandfather who Shoreline, \ died peacefully in his sleep. Not screaming like Washington, USA \ all of the passengers in his car http://shorewall.net \________________________________________________ ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ _______________________________________________ Shorewall-users mailing list Shorewall-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/shorewall-users
Tom where go the files "saved" with shorewall save command? If the restart command is not working the previos saved files go up again and lost the configuration in /etc/shorewall? Best regards Emiliano Emiliano Vazquez | PcCentro S.R.L. Callao 80 | CP 1022 | C.A.B.A. Office: +54 (11) 4951-0203 / 4155 Celular: 15.6253.7165 Mail: emilianovazquez@gmail.com Web: http://www.pccentro.com.ar -----Original Message----- From: Tom Eastep <teastep@shorewall.net> Date: Thu, 24 May 2012 07:08:21 To: <shorewall-users@lists.sourceforge.net> Reply-To: Shorewall Users <shorewall-users@lists.sourceforge.net> Subject: Re: [Shorewall-users] Absent-minded admin + multi isp On 05/24/2012 02:24 AM, Artur Uszyński wrote:> Hello. > > In a situation like this: > - a firewall has two or more internet connections, > - a firewall runs shorewall 4.5.1 (multiple isps configured) > - one connection is broken, > - default route in the main routing table leads through the failed connection, > - a firewall is 20000 km away from admin ;), > > and after taking the following actions: > - logging in to the firewall through working connection, > - changing shorewall configuration and making a stupid error in it > - doing "shorewall stop; shorewall start" :s, > > you must take nearest flight from Europe to Australia to bring the firewall back to life ;) (because returning traffic goes through default, non-working link) > > Can shorewall handle such cases in a way, which would prevent similar accidents ? Did I miss any option ?A couple of things: a) Before making a configuration change, execute 'shorewall save'. This will save the currently running configuration which can then be restored if a 'restart' fails. b) Use 'shorewall restart' rather than 'shorewall stop; shorewall start'. 'shorewall stop' restores the default route(s) that were in place before the last 'start' command. 'shorewall restart' replaces, adds or deletes default routes based on the state of the links. And if the 'restart' fails, the firewall will be restored to its prior state. c) After you are satisfied that the change works correctly, do another 'shorewall save'. Note: As someone noted in another response to your post, the 'safe-restart' command combines 'save' and 'restart' in a single command. -Tom -- Tom Eastep \ When I die, I want to go like my Grandfather who Shoreline, \ died peacefully in his sleep. Not screaming like Washington, USA \ all of the passengers in his car http://shorewall.net \________________________________________________ ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ _______________________________________________ Shorewall-users mailing list Shorewall-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/shorewall-users ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ _______________________________________________ Shorewall-users mailing list Shorewall-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/shorewall-users
On 05/24/2012 07:39 AM, emilianovazquez@gmail.com wrote:> Tom where go the files "saved" with shorewall save command? > > If the restart command is not working the previos saved files go up again and lost the configuration in /etc/shorewall? >The files from /etc/shorewall are *not* saved. Rather, the compiled firewall script (/var/lib/shorewall/firewall) is copied to /var/lib/shorewall/restore (default name) and the current iptables contents are saved to /var/lib/shorewall/restore-iptables (again, the default name). You can override the default name by typing ''shorewall save <filename>'' or you can change it globally using the RESTOREFILE setting in shorewall.conf. A saved configuration may be reactivated using the ''restore'' command. -Tom -- Tom Eastep \ When I die, I want to go like my Grandfather who Shoreline, \ died peacefully in his sleep. Not screaming like Washington, USA \ all of the passengers in his car http://shorewall.net \________________________________________________ ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today''s security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
>________________________________ > From: Tom Eastep <teastep@shorewall.net> >To: shorewall-users@lists.sourceforge.net >Sent: Thursday, May 24, 2012 9:08 PM >Subject: Re: [Shorewall-users] Absent-minded admin + multi isp > >A couple of things: > >a) Before making a configuration change, execute ''shorewall save''. This > will save the currently running configuration which can then be > restored if a ''restart'' fails. > >b) Use ''shorewall restart'' rather than ''shorewall stop; shorewall > start''. ''shorewall stop'' restores the default route(s) that were in > place before the last ''start'' command. ''shorewall restart'' replaces, > adds or deletes default routes based on the state of the links. And > if the ''restart'' fails, the firewall will be restored to its prior > state. > >c) After you are satisfied that the change works correctly, do another > ''shorewall save''. >Thanks Tom for the information. I should change my behaviour of restarting shorewall.>Note: As someone noted in another response to your post, the >''safe-restart'' command combines ''save'' and ''restart'' in a single command. > >-Tom >-------------------------------------------------------------------------------- Live Security Virtual Conference Exclusive live event will cover all the ways today''s security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/