←back to thread

1901 points l2silver | 2 comments | | HN request time: 0.426s | source

Maybe you've created your own AR program for wearables that shows the definition of a word when you highlight it IRL, or you've built a personal calendar app for your family to display on a monitor in the kitchen. Whatever it is, I'd love to hear it.
Show context
btbuilder ◴[] No.35741173[source]
I built a program in Go to defeat GeoIP lock-outs for my home network.

It runs on our home router and functions as the primary DNS server. If the record name matches a regex the DNS request is forwarded over a VPN to a DNS server in the target country. Any other requests are forwarded to my ISP’s DNS. If the response is a CNAME then the A record name is cached so that follow-up requests are also forwarded over the VPN.

Before returning the IPs in the foreign DNS response /32 routes for the IPs are added to send any home network traffic for them over the VPN.

This means that any client on our home network can transparently access GeoIP locked sites. It’s worked for around 8 years with no modifications.

replies(2): >>35745343 #>>35765106 #
ornornor ◴[] No.35765106[source]
Curious: why not routing and vpn? I do this with opnsense, for instance Pandora is forbidden where I live so I’ve looked up all IPs for their ASN and made routing rules that any packet going to these IPs go over the US VPN. And I’ve made WireGuard profiles for mobile phones so the Pandora traffic goes over WireGuard and through the us vpn via my home opnsense.
replies(1): >>35765301 #
1. btbuilder ◴[] No.35765301[source]
I did this for several years before but it was a constant maintenance burden because as third party services were integrated or removed over time. Eventually as AWS and third-party CDN usage grew routing by subnet was just not feasible.
replies(1): >>35765319 #
2. ornornor ◴[] No.35765319[source]
Didn't consider smaller services hosted on AWS. Subnet routing only works well for those that have their own ASN indeed.