trueos / trueos-core

59 stars 18 forks source link

OpenRC / Firewall: `/etc/init.d/ipfw` from FreeBSD-runtime-12.0 incompatible with TrueOS firewall scripts #232

Closed baitisj closed 7 years ago

baitisj commented 7 years ago

This script should probably be removed, disabled by default, or modified to invoke /etc/ipfw.rules

I am not seeing the place in the OpenRC tree (should be in /etc/init.d) where /etc/ipfw.rules is executed.

That stated, I am not certain if TrueOS remembers the state of ipfw between reboots. If indeed that is the case, then this script should simply be disabled.

Usage case: Reboot machine. Multiple services (e.g. samba-server) are unreachable.

baitisj commented 7 years ago

This remained an issue for me until I executed: rc-update add ipfw default (I noticed that this issue was resolved no earlier than I had applied the TrueOS-DESKTOP-201701060022 UNSTABLE update).

I'm going to test that the rc-update command was also required.

pkgdemon commented 7 years ago

These were added to attempt to fix this:

https://github.com/trueos/freebsd/commit/49fc7cccbe8390f3cf872e705b120dce2eb43834

https://github.com/trueos/freebsd/commit/3558b1d706bad4c3d18908c54b1c1d023f78a6a6

I added the flags back into the proper place in /etc/defaults/rc.conf but I suspect the init.d job may have the flags hardcoded in. See the syslog, and newsyslog for scripts using the flags.

If we have a runlevel issue we can move it to default here:

https://github.com/trueos/trueos-desktop/blob/master/port-files/pkg-install

pkgdemon commented 7 years ago

I've tested here, and ipfw rules are working for me now.

baitisj commented 7 years ago

Yep, verified working here, too. Thanks all.