Repository navigation
v3.44 — Only Allow Mode Fix + Null URL Safety
v3.44 — Only Allow Mode Fix + Null URL Safety
Bug Fixes
-
Only Allow mode now works correctly: In whitelist (Only Allow) mode, newly discovered hosts now default to DENY instead of ALLOW. Previously every new host was added as ALLOW, which defeated the entire whitelist purpose — unknown hosts were let through. Now new hosts are blocked until explicitly marked ALLOW in host_rules.txt.
-
Null guard in shouldBlockByHostRules: Added a defensive if (!hostname || hostname.length === 0) return null guard at the entry of shouldBlockByHostRules to prevent a potential null-pointer error when hostname is empty or null.
-
OkHttp3
ewCall null-safe blocked URL: HttpUrl.parse() is nullable — if it ever returned null for the blocked URL placeholder,
equest.newBuilder().url(null) would throw IllegalStateException and crash the app. Added an explicit null check with a fallback URL so the app never receives a null URL object.
Summary
Only Allow (whitelist) mode is now fully functional: unknown hosts are blocked by default, and the app cannot crash from a null blocked URL being fed into OkHttp.