Lantern Watch: A free, open-source family/parental-control layer for GL.iNet + AdGuard Home (no cloud, no subscription)

Hey all, I run a homeschool household with a big family where everyone is online constantly for school. Like most parents, I've gone back and forth on how to keep our kids safe and monitor network activity. A while back, a neighboring homeschooling mom asked for advice on securing her network. I looked at everything—DNS filtering, blocklists, paid parental control apps. It all works, but none of it was something she could actually set up or maintain. She wasn't going to SSH into a router or edit config files, and honestly, most parents won't.

That gap is why I started building Lantern Watch. It’s a dashboard that sits on top of a GL.iNet router (with AdGuard Home and dnsmasq doing the underlying work) and turns it into something a non-technical parent can use: schedule internet access per device, block categories or specific sites, pause the internet at dinner, and view clear network activity without needing to parse raw logs.

It’s been running on my home network for a while now across 30+ devices as a daily driver. A few technical details worth noting if you're the tinkering type:

  • Lightweight stack: Built with pure Python (stdlib only) and SQLite for storage—runs directly as a service on the router itself with zero extra dependencies.

  • GL.iNet-specific DNS architecture: dnsmasq stays on port 53 and forwards queries to AdGuard Home on port 3053. If AdGuard handles port 53 directly, all upstream queries report as 127.0.0.1, which breaks per-device filtering and tracking.

  • No MITM / HTTPS Interception: Blocked HTTPS sites trigger a standard certificate warning rather than a custom landing page. This is an intentional design choice to avoid installing root CA certificates on family devices.

  • 100% Local: Nothing leaves your local network—no cloud service, no subscriptions, and no persistent remote access.

  • Hardware: Developed and daily-driven on the Flint 2 (GL-MT6000), Beryl 7 (GL-MT3600BE), and the Brume 3 (GL-MT5000), with testing underway for other Wi-Fi 6/7 GL.iNet builds.

It’s still early, but it’s stable enough that I’d love to get it in front of a few other GL.iNet users for feedback before a broader release. If you’re running a compatible router and want to test it out—or if you have feedback on the integration—I’d love to hear from you.
Ryan (in Canada)

Hi Ryan,

Thank you for developing Lantern Watch and sharing it with the GL.iNet community!

We appreciate its thoughtful, privacy-first approach and the effort to make family network management more accessible to non-technical users. It’s great to see GL.iNet routers and AdGuard Home being used in such a practical open-source project.

We look forward to seeing how Lantern Watch evolves. Thanks again for your contribution!

Thanks Will, appreciate the warm feedback!

My main goal is to give families and business a practical, privacy-first way to manage their networks without relying on complex configurations. GL.iNet hardware makes an ideal foundation for that.

I'd be very open to any suggestions on other communities or channels where you think this project would be helpful. Also, if the GL.iNet team ever has feedback or technical insights on deep-linking deeper into OpenWrt/GL-iNet UI integrations down the road, I'd love to connect!
Ryan.

This is a great project since the built in parental controls were nerfed in the latest firmware update.

However, there are some issues I spotted that I wasn’t sure if they were intended or not:

The installer explicitly disables all Wi-Fi interfaces on a Flint 2 and runs wifi down, assuming it is used as a wired pass-through router.
The installer changes existing AdGuard Home settings, including filter lists, upstream DNS, Safe Browsing, parental filtering, cache and retention.
It creates an AdGuard service account named lanternwatch with a random password. This is stored in lanternwatch_config.json, but it is not clearly presented as a separate AdGuard login.
It removes the GL.iNet --glinet option from the AdGuard Home startup script to enable standard AdGuard authentication.
It restarts AdGuard Home and dnsmasq during installation, causing a temporary DNS interruption.
It alters dnsmasq DNS forwarding and enables GL.iNet’s DNS redirect.
It changes GL.iNet firmware-update settings by disabling automatic updates and switching to the stable channel.
It modifies important router and AdGuard settings without first backing up the AdGuard, DHCP or wireless configurations.
Device settings, schedules and pause rules commonly depend on the device’s current IP address or hostname. They may stop following a device after its DHCP address changes.
Pausing uses IPv4 iptables rules. Devices with working routed IPv6 may potentially bypass the pause.
The scheduler uses a different database path from the collector and dashboard, which can cause screen-time calculations to read the wrong database.
Screen time is estimated from DNS requests rather than actual screen activity. Background requests can count as activity, while activity that generates no new DNS requests can be missed.
Filtering and social-media controls are mainly household-wide rather than being assignable to individual people or devices.

I think some users would be very confused if they installed via WiFi and wonder why they didn't see their SSID any more after the initial install.

Here is a bit of an extensive wishlist I came up with too:

Add People/Groups without removing existing device roles.
Allow multiple devices to be assigned to one person, with one group per device.
Add one shared daily allowance across all devices belonging to that person.
Merge overlapping device activity so simultaneous use normally counts only once.
Add group bedtime, permitted hours and Focus Time schedules.
Add group-specific adult, social-media, SafeSearch and YouTube filtering where AdGuard supports it.
Allow device-specific overrides and show whether each setting comes from the household, group or device.
Add Pause Group and Resume Group alongside the existing pause controls.
Add temporary +15, +30 and +60-minute bonus allowances.
Show group usage, remaining time, online devices and the next restriction on the dashboard.
Retain group and device-level daily usage history.
Track group membership by MAC identity and update enforcement when DHCP addresses change.
Preserve existing installations, device settings, AdGuard configuration, Wi-Fi, DHCP and network connectivity during installation and upgrades

I would have loved to have seen glinet themselves build something like you've done but this could turn into a really cool and much needed tool!

This is one of the most useful things anyone's done for this project. Thank you for actually reading the code. You nailed several, a few are deliberate trade-offs I should've documented, and your People/Groups list is basically the roadmap in my head. Honestly, item by item:

You're right — these are getting fixed:

  • Wi-Fi getting disabled on the Flint 2. Guilty. I run mine as a wired pass-through in a media closet with a mesh booster downstream, so I'd defaulted Wi-Fi off for my own setup — which is exactly the wrong default for everyone else. You're 100% right that someone installing over Wi-Fi loses their SSID and panics. Flipping it: Wi-Fi stays on by default, and the pass-through/disable behavior moves behind an explicit flag for oddballs like me.

  • The scheduler reading a different database path than the collector and dashboard. That's a real bug, not a design choice — the screen-time check is pointed at the wrong DB file. Fixing it to share the one canonical path. Great catch.

  • No backup before the installer changes things. Fair and important — I'll add a pre-install snapshot of the AdGuard, DHCP and wireless config, plus a clean restore/uninstall, so nothing's a one-way door.

  • IPv6 pause bypass — valid; pause is IPv4-only today, adding ip6tables rules.

  • Device identity drifting on DHCP change — right, and it ties straight into your wishlist: moving enforcement to MAC-based identity so rules follow the device, not the lease.

Intentional — but I owe better docs:

  • Configuring AdGuard (lists/upstreams/Safe Browsing/safe search/retention) is the core job — the whole point is that a non-technical parent doesn't have to. It avoids clobbering lists you've already added; the pre-install backup above is the safety net.

  • Removing --glinet is on purpose — that mode routes AdGuard auth through the firmware and blocks the standard API login Lantern Watch needs to manage AdGuard with its own service account.

  • dnsmasq→AdGuard forwarding + the DNS redirect is what preserves per-device visibility (dnsmasq on :53 → AdGuard on :3053, so each device keeps its real IP instead of everything showing as the router).

  • Disabling GL.iNet auto-updates — the scar tissue is real, an unattended OTA wiped this router on me once. But you're right it's heavy to do silently; I'll make the installer ask rather than just do it.

  • The lanternwatch AdGuard account (the API account) — intentional, but not clearly surfaced as a separate login; I'll document it.

  • Screen time from DNS rather than real activity — true; it's the trade-off of being fully agentless (no app on each kid's device). It's an estimate and I should say so plainly in the UI.

Household-wide vs per-person — your wishlist: you put your finger on the biggest limitation. Multiple devices per person, one shared daily allowance with overlapping use merged, group bedtimes/Focus, group filtering with device overrides that show where a setting came from, Pause Group, bonus +15/+30/+60, a dashboard showing each person's remaining time and next restriction, MAC identity that survives DHCP, and preserving everything on upgrade — that's not a wishlist to me, it's the direction. And I'm literally about to rework first-run setup next, so this is perfect timing to design toward it.

And your last line — "I would have loved to see GL.iNet themselves build this." Same. 1000%. If GL.iNet or AdGuard ever want to take this further, or fold it in, I'd be thrilled — my goal was never to own it, it's to get as many families a safe browsing experience as possible. So — GL.iNet, AdGuard: if you see the vision, let's talk. And until then… Lantern Watch it is. :red_paper_lantern:

Seriously, thank you. This is the kind of feedback that makes a project better.

@pspr33 **
Quick update — and thank you again.**

After my last reply I stopped talking and started shipping. Almost everything you flagged is done and live now:

  • Wi-Fi stays ON by default. The wired pass-through thing is now an optional flag, for oddballs like me.

  • The screen-time bug (it was reading the wrong file) — fixed.

  • Pause now covers IPv6 too, so nobody can slip past it.

  • The installer takes a backup of your settings before it touches anything, so nothing is a one-way door.

  • It no longer changes your firmware-update setting quietly — it asks first.

  • And I wrote up exactly what the installer changes on your router, so there are no surprises.

I also finally built a proper first-time setup — a simple, plain-language walkthrough that gets a non-techy parent going without ever touching AdGuard themselves.

Now the fun part — People/Groups. This is where you really got me thinking, and honestly, I ended up somewhere I didn't expect.

I started designing the big version — people, ages, shared time limits, the works. But I run this stuff past actual homeschool moms, and one thing kept coming up: they don't fiddle with software. They just say "kids, off the computer" — and the kids listen. The app isn't the parent. It's the backstop.

So I made a call. Instead of a big system nobody would set up, I built the one thing they'll actually use every day — a really good Pause:

  • Pause any device, or everyone at once, with a timer — 30 minutes, an hour, the rest of the day, or until you turn it back on. The timed ones turn themselves back on, so you never have to remember.

  • If you want, you can make simple groups you name yourself — like Kids or TVs — and pause the whole group in one tap. There's even a button that guesses the groups for you (phones, tablets, TVs), so you don't have to.

  • And it will never pause your router, a video doorbell, or a thermostat. The important stuff stays on, always.

The bigger People vision (shared limits per kid, group bedtimes, all that) is still written down, and I may build parts of it later. But I'd rather ship the simple thing families actually use than the fancy thing they won't.

Same offer stands — if GL.iNet or AdGuard ever want to take this further, or fold it in, I'm all ears. The goal was never to own it. It's to get as many families and businesses safe online as I can.

Thanks again for the push. It genuinely made the project better.

Quick ask for the community — and a thank you.

Since I first posted this, Lantern Watch has come a long way: a guided first-time setup, a really simple pause (pause a device or the whole house for 30 minutes, an hour, or until you turn it back on — and it turns itself back on), optional device groups, and a round of security hardening. Still free, open source, no cloud, no subscription — it just runs on your GL.iNet router.

Here's where I could use your help.

I only have a handful of routers to test on. This week a kind user emailed to say it's running great on a Brume 2 (1 GB RAM) — a model I'd never tried. Good reminder that it probably works on a lot more GL.iNet devices than I've personally confirmed.

So if you've got a spare GL.iNet router and a few minutes, give it a try and let me know how it goes. I'd especially love to hear:

  • Which router (and firmware) you ran it on

  • Whether the install and dashboard worked cleanly

  • Anything that felt rough, confusing, or missing

And if you have ideas or feature requests, I genuinely want them. This whole project got sharper because someone here read the code and pushed back — more of that, please.

You can reply here, open an issue on GitHub, or reach me through the site. Every confirmed router helps the next family find hardware that just works.

Thanks, as always. Ryan

So, Lantern Watch is able to block encrypted DNS from getting through? On Android, it's very easy to bypass the router's DNS by using Private DNS. If I can prevent devices or even IoT devices from bypassing the router by using their hardcoded encrypted DNS, then that would be very awesome.

I would love to see Lantern Watch tested on the Mudi 7, Slate 7, Slate 7 Pro, and the upcoming Flint 4.

Great question, and yes; Lantern Watch handles this, in two layers.

By default (nothing to turn on) it already blocks the common encrypted-DNS (DoH) providers and trips Firefox's built-in canary, so Firefox switches its own encrypted DNS off and uses your filtered DNS. That part is gentle — it won't break anything.

Then there's an optional "Strict mode." It goes further: it blocks DoT (port 853) — which is exactly what Android's "Private DNS" uses — plus the known public resolver IPs (Cloudflare, Google, Quad9, etc.). So with strict mode on, an Android phone set to Private DNS can't reach its server and falls back to the router's filtered DNS.

Fair warning, and the reason it's off by default: strict mode can occasionally interrupt a device that insists on its own DNS — some smart TVs and apps. So it's meant to be switched on when you actually suspect someone's getting around the filter, not left on for everyone.

Where I'll be straight with you: the one case no router can fully solve is a device that hardcodes encrypted DNS to some obscure server over port 443 — same port as normal web traffic, so blocking all of it would break the internet. Nobody can catch every proprietary IoT endpoint. Lantern Watch covers the realistic, common ones — the Android Private DNS trick and the major providers — which is the vast majority of real bypass attempts. For plain (unencrypted) DNS, GL.iNet's own "Override DNS Settings of All Clients" covers that layer.

On your other note — Mudi 7, Slate 7, Slate 7 Pro, and the Flint 4 — I'd love to see those confirmed. They're all GL.iNet OpenWrt routers so it should run fine, but I haven't personally tested them. If you (or anyone) gets it going on one, let me know and I'll add it to the community-confirmed list I just started (someone confirmed the Brume 2 this week). Whichever of those you have, Lantern Watch checks the router's memory and picks the right profile automatically — 1 GB+ runs the full on-device filtering, and 512 MB routers run a lighter "Lite" profile (adult/malware filtering rides a fast filtered-DNS upstream to stay light). Every parental feature works the same either way, so a 512 MB travel router is totally fine.

Thanks for the thoughtful question. Ryan.

Thanks for the response. I have a bunch of follow-up questions.

Has anyone ever tried to compile a list of known DNS servers to block besides the list that you have in Lantern Watch?

Just to be clear, under strict mode, both DoT and DoQ are blocked? I think DoQ is using port 853. Does that mean in the GL.iNet GUI, I should select DoH as the secured DNS protocol?

So even if DoT is blocked, all Android devices will still connect to the internet via the router automatically, but now using the router's DNS settings? Is this all seamless and no user intervention with their Android devices?

I'm definitely going to have to give your tool a try, as it's not just about parenting, but I just want a fairly locked down and secured network.

Are you planning to add any more features? Any outstanding bugs that need to be addressed? Any plans to make this available for other router platforms like OPNsense, OpenWRT, Omada, and UniFi?

Has anyone ever tried to compile a list of known DNS servers to block besides the list that you have in Lantern Watch?

With the constantly-changing DNS structure of the Interwebz, this is a failed effort before you even start. The best you can do is block the well-known services and ports (except tcp/udp:443, of course) that are used for legitimate (in)secure DNS. More often than not, this is good enough. Anything else would require DPI, and when dealing with encrypted sessions, a trusted CA to use for dynamic cert spoofing for your trusted MITM.

I had Claude look through the app and help with this response below. Ryan

@JimmyJoeBobAlooba — that's exactly right, and it's why Lantern Watch doesn't try to chase a "complete" blocklist. Blocking known resolver IPs on 443 only ever catches DoH from providers you happen to know about — the protocol itself is indistinguishable from ordinary HTTPS traffic, so anything past "block the well-known ones" really does mean DPI and a trusted CA doing dynamic cert spoofing on every device, which is a different (and much more invasive) product than what we're building. Appreciate you saying it plainly — that's the honest ceiling, not a limitation of our list specifically.

@knee_mountain523 — answering the rest:

DNS server lists — given the above, the list we ship (10 IPs — Cloudflare, Google, Quad9, OpenDNS, AdGuard DNS) is deliberately small: it's "the common defaults a kid might set up," not an attempt at completeness. If you want to go further on your own, there are a few actively-maintained lists built for exactly this — dibdot/DoH-IP-blocklists ( GitHub - dibdot/DoH-IP-blocklists: This repo contains the domain names and the resolved IPv4/IPv6 addresses of public DoH server · GitHub ) is the one OpenWrt firewall tools like banIP draw from, and crypt0rr/public-doh-servers and DNSCrypt/dnscrypt-resolvers are worth a search on GitHub too.

Worth going in with eyes open per JimmyJoeBobAlooba's point above: more IPs means more maintenance (they rotate) and more chance of a false-positive on a shared CDN range, for protection that's still fundamentally bounded by "known IPs only."

DoT vs DoQ — both blocked under strict mode, yes. DoT is TCP port 853; DoQ (RFC 9250) is UDP port 853 — same port, different transport. Strict mode blocks 853 on both TCP and UDP, so DoQ's covered without needing anything extra.

The GL.iNet "Secured DNS" dropdown is a separate, unrelated layer — that's how the router itself resolves upstream, not whether your LAN devices can bypass the filter with their own encrypted DNS. Set that to whatever you like; it doesn't interact with strict mode either way.

Android devices — seamless for the default case. "Private DNS" defaults to "Automatic," which is opportunistic — it tries DoT to the network's DNS server, and silently falls back to plain DNS to that same server if it's blocked. No action needed. The one exception: if someone manually set a specific Private DNS provider hostname (not "Automatic") on their phone, blocking port 853 will make that device show "Private DNS server cannot be accessed" until they flip that setting back to Automatic themselves — that's an Android-side setting we can't reach remotely, so it'd be a one-time fix on that device if it ever comes up.

Roadmap / bugs / other platforms — nothing outstanding that I know of right now; the last couple rounds of feedback all made it into recent releases. No promises on a timeline for new features, but if something's bugging you, open an issue on GitHub and I'll take a look. As for OPNsense/OpenWrt-generic/Omada/UniFi — no plans right now. The install leans on GL.iNet's specific package system, so supporting another platform would be a real port, not a config tweak, and that's a bigger undertaking than I'm signed up for at the moment.

Glad to see this thread digging into the actual mechanics — that's exactly the kind of scrutiny that makes this thing better.

I understand how difficult to block DoH and in not suggesting that it can be done. The goal is to get all the obvious targets. I want to create friction for the end user.

What's the difference between your tool and something like banIP? It seems like banIP has compatibility issue with GL.iNet products due to the different versions of OpenWRT.

I think you wrote that Lantern Watch turns AdGuard Home on. I currently have it off since NextDNS do most of what I thought I needed. I am interested in further tightening control of my network. Is it possible for me to use AdGuard Home with other blocklists that deal with DoH and not duplicate what NextDNS already do, NextDNS as the “primary”, and Lantern Watch under strict mode to block DoT/DoQ?

Honestly, for what you're describing, you probably don't need Lantern Watch at all. You've already got NextDNS doing the content filtering, and "raise the friction" is achievable with a couple of firewall rules on the router itself:

  1. Block outbound TCP and UDP port 853. That kills DoT and DoQ regardless of provider, no blocklist needed.

  2. Block outbound TCP 443 to the handful of major public DoH resolver IPs you actually care about (Cloudflare, Google, Quad9, whatever's realistic for your household).

  3. Redirect all outbound port 53 traffic to your own router, so a device can't just point itself at a different DNS server and skip your rules entirely.

All three are plain firewall rules. Your GL.iNet router can do this directly through custom firewall rules (or SSH, if you're comfortable there), no AdGuard Home and no Lantern Watch required. That's genuinely the whole mechanism strict mode uses under the hood anyway, so you're not missing anything by skipping the app.

banIP vs. Lantern Watch, quickly: different tools. banIP is general IP-blocklist firewall enforcement (Spamhaus, abuse.ch, geo-blocking), no family features at all. Lantern Watch is the parental-control layer (schedules, pause, device management, alerts) on top of AdGuard Home. Given what you've described, sounds like neither is really what you're after here, just the raw firewall rules above.

If you ever do want the household-management side of things (schedules, notifications, per-kid device tracking) on top of what you've already got, that's when Lantern Watch would actually add something. For just raising DoH/DoT friction on top of NextDNS, the router's own firewall gets you there.

Ryan (& Claude)

That approach is reasonable for adding friction while retaining NextDNS, but the firewall rules must be scoped carefully. Blocking port 853 should apply to forwarded LAN/guest traffic, not router-originated traffic, or it may also block the router’s own NextDNS DoT connection. Port 53 redirection should cover TCP and UDP, IPv4 and IPv6; blocking known DoH endpoints may also require both TCP and UDP 443 because HTTP/3 uses QUIC.

The exact implementation depends on the router model and complete firmware version: older branches use iptables/firewall3, while newer branches may use nftables/firewall4. Please confirm those details before applying commands, and keep a recovery path such as a configuration backup or wired access. Lantern Watch and custom firewall enforcement are not official GL.iNet features: This feature is not officially supported by GL.iNet. Any guidance is provided on a best-effort basis, and GL.iNet Technical Support may not be able to troubleshoot or maintain this configuration.

This reply was generated by AI. Please verify its accuracy.

GL.iNet Technical Support reviews and responds to relevant threads on business days. Please allow time for a staff response.

Thanks for taking the time to respond to my post and I'll reflect on what you have said.

Would you mind posting instructions on how to create custom firewall rules with a GL.iNet router for anyone else that's reading this thread and new to networking concepts?

  1. Block outbound TCP and UDP port 853. That kills DoT and DoQ regardless of provider, no blocklist needed.
  2. Block outbound TCP 443 to the handful of major public DoH resolver IPs you actually care about (Cloudflare, Google, Quad9, whatever's realistic for your household).
  3. Redirect all outbound port 53 traffic to your own router, so a device can't just point itself at a different DNS server and skip your rules entirely.