Hi all,
I just came into this thread having the same problem today.
My issue was not getting the reject behavior, and getting the drop only effect (request timeout, no immediate connection reset) for filtered tls traffic.
After a couple of hours, I just figured out the reason and the solution for it in pfSense.
Suricata, is sending the RST flag from the Loopback interface (actually it has a command line parameter for selecting the interface but it did not work/help).
The “permission denied” error is due to the pfsense firewall blocking traffic (you can check it in the firewall log) The traffic is out from lo0 interface and is blocked by a default built-in (hardcoded) rule.
You cannot create a passing rule to override this behavior neither from pfSense GUI nor easyrule, as it does not know about “Loopback” in GUI and easyrule.
So, the solution is patching the file /etc/inc/filter.inc
There is a default hard-coded for passing loopback traffic (but not all TCP flags, S/SA only by default)
So, we are going to change this behavior by patching the file and reloading filters.
Search for this line:
pass out {$log['pass']} on \$loopback inet all ridentifier {$increment_tracker()} label "pass IPv4 loopback"
add “flags any” before “ridentifier” so the full line becomes:
pass out {$log['pass']} on \$loopback inet all flags any ridentifier {$increment_tracker()} label "pass IPv4 loopback"
(There are two rules (IPv4 and IPv6))
Reload filter from the diagnostics GUI menu, and voila!