Thanks for the suggestions.
I've tried in the past with an external router and it works fine. But in my case I need to run this directly on my mac, in "real-time", not to have the special external setup.
I'll have a look with the pfctl, but might also be complicated. because I'm already modifying this from another app, and I need to add extra things for the logging.
Topic:
App & System Services
SubTopic:
Core OS
Tags: