-
Notifications
You must be signed in to change notification settings - Fork 33
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
forwarding rules #236
Comments
i actually renamed the define and pushed the code here: may be updated with time, naturally. also, i just remembered we have dnat4 and snat4 rules in there, but for me those are really opaque and undocumented, and don't do all of the above. maybe the above should be rewritten to use the dnat/snat stuff, but i'm not sure i understand them well enough to tell. |
Unrelated to your code, but it sure would be simpler to use IPv6 rather than port forwarding. Being able to eliminate this kind of legacy IP complexity on my home network is what got me into IPv6 many years ago. |
Thanks, but if I had access to IPv6 on this setup, I wouldn't need this
stuff.
Obviously. :p
|
Not necessarily obvious, everyone has to learn at some point. Maybe also obvious, but tunnels are often a good workaround for lack of native IPv6, but I guess some ISPs make even that difficult. |
🤷 i understand where you're coming from, but i would assume someone that comes in with relatively advanced knowledge in firewall rules and Puppet would know about other ways to do what i'm trying to here. I wouldn't try to teach them the myriad of other ways they could do what they want to do. Heck, you could have told me about ipsec, tailscale, ngrok and god knows how else I might manage this. I'm just trying to keep things simple for now. :) |
or to frame this another way: do you fundamentally object to adding such a NAT forwarding rule here, in favor of telling people they should setup IPv6 tunnels instead? |
We do have have a simple wrapper that includes hairpinning here: https://code.immerda.ch/immerda/ibox/puppet-modules/-/blob/main/ib_nftables/manifests/simple_dnat.pp?ref_type=heads It seems to me that we did it slightly different, but I can assure you we have it in use for quite a while (longer than the commits are). I intended to contribute that wrapper eventually into the nftables module itself, but lacked a bit of time to properly clean it up and write tests. |
interesting! that leads to a 500 error here, but i'd be really curious to read it! i'd be happy to collaborate towards a final version, but i must admit i suck at unit tests, so i'm not sure i could help with that. :p |
Hello!
I've been working on a home router setup, and one of the things i have painfully figured out is the exact incantations to get not only port forwarding right (that's relatively easy), but "reflection" or "hairpinning" which allows users inside the NAT to access services as if they were on the outside.
I think this might be a worthwhile addition here. I'm still in the testing phase of this here, i have a handful of new forwards to deploy soon that I haven't tested yet, but when I did, i'd submit a PR for that... The code, right now, lives in a profile of mine:
How does that look?
The text was updated successfully, but these errors were encountered: