Created attachment 208032 [details]
Silence firewall_logif on ipfw service restart
Once the ipfw0 interface has been created, ifconfig(8) create will throw a warning: `ifconfig: create: bad value' when trying to create it again.
This patch silences it.
(In reply to Jose Luis Duran from comment #0)
The warning message is more descriptive now. Not sure if silencing it is really a benefit:
ifconfig: interface ipfw0 already exists
Created attachment 216277 [details]
Disable logging and destroy ipfw0 interface upon service stop
Second option just in case.
I oppose this approach.
Modifying a sysctl value in the background is surprising to the user.
I do not see any code for retaining the old value for the next usage. So if the service is restarted, the log-sysctl value will unconditionally lost and any new messages will be suppressed.
(In reply to lutz from comment #3)
That is understandable. Attached is patch3 (also just in case) which disables only the interface.
Created attachment 216298 [details]
Disable the interface ipfw0 upon service stop
Destroy just the interface and leave the sysctl on. (option 3).
Created attachment 216416 [details]
Less destructive approach
Take 4: Do not attempt to create interface if it already exists.
Created attachment 216419 [details]
Tell the user if the interface already existed