Skip to content

v1.2.0 — Performance Fine-Tuning & Universal IoT Telemetry Shield

Choose a tag to compare

@pphothidaen pphothidaen released this 26 Nov 06:39
· 28 commits to main since this release

🛡️ HomeShield v1.2.0 — Performance Fine-Tuning & Universal IoT Telemetry Shield

⚡ Performance Fine-Tuning (Design Patterns)

  • Builder & Strategy Pattern (BlocklistCompiler::with_capacity): Pre-sizes HashSet & Vec to 300,000+ capacity across homeshield-daemon and homeshield-cli compile, eliminating repeated O(n) rehashing on embedded ARMv7 and CI builds.
  • Flyweight Pattern (Arc<HashSet<String>>): Shares immutable whitelist via BlocklistCompiler::with_shared_whitelist for zero-clone CDN fallback rebuilds.
  • Cache-Aside Pattern (domain_count Sidecar): Writes verified unique domain count during do_update() so do_status() reads in O(1) without scanning 8 MB+ hosts files (reporting 0 cleanly when PAUSED).
  • Buffer Reuse Pattern & 128 KB Streaming I/O: Upgraded file_len_and_fnv1a, write_hosts, write_dual_stack_hosts, apply_hosts, ensure_base_hosts, and fallback count_blocked_v4_domains to 128 KB buffers and single reused String line buffers (eliminating 600k+ heap allocations).
  • Single-Pass Visitor Pattern (/proc scan): Added SystemOps::find_any_process_pids to locate resident daemon processes in 1 /proc directory walk instead of 3.
  • Scatter-Gather Pattern (JoinSet LAN Probe): Parallelized ADB port 5555 discovery across all LAN DHCP/ARP leases (~800 ms total instead of N × 800 ms sequentially).

🌐 Universal IoT & Device Telemetry Blocking (29 Live Feeds)

  • Added 8 verified telemetry feeds (native.amazon.txt, native.apple.txt, native.huawei.txt, native.oppo-realme.txt, native.vivo.txt, native.roku.txt, native.winoffice.txt, WindowsSpyBlocker/spy.txt).
  • Added device CLI alias + DeviceCategory classifier (Smart TV, Smartphone / Tablet, IP Camera, Smart Speaker, Gaming Console) + built-in OEM telemetry fallback rules & mobile core protection.

📊 Verification Highlights

  • TurtleCute Ad Blocker Test: 97% (126 / 130 Blocked) (4 remaining are browser-only cosmetic CSS placeholders and first-party ads.js / pagead.js scripts).
  • Embedded Memory Footprint: 408 kB VmRSS on ARMv7 (ZTE ZXHN F6107A).
  • Diagnostic Whitelist: adblock.turtlecute.org whitelisted for live browser verification.

📦 Release Asset & Checksum

Asset SHA-256
homeshield-daemon-armv7-unknown-linux-musleabi 02e651da197b8251b578a1da2608145fd83a22a71c6ef1c0da6957a73164c9ef