Most mobile comic and PDF reader templates cut corners: sluggish WebView wrappers, zero archive validation, hardcoded Firebase configs, and missing store-compliance flows (Age Gate, consent timestamps, in-app account deletion).
I built PanelVerse to solve that — a dual-native Android (Kotlin / Material 3) and iOS (SwiftUI / iOS 16+) comic, manga, and PDF reader designed for indie publishers and self-hosted Komga / Kavita / Calibre libraries.
Here are the four engineering decisions that mattered most:
1. Validating Untrusted CBZ & PDF Files On-Device
Accepting local .cbz and .pdf files up to 250 MB means treating every archive as hostile input:
ZIP-slip protection: Reject any archive entry containing path traversal ( ../ ), absolute paths, or backslashes before extraction.
Image-bounds validation: Decode bounds first ( inJustDecodeBounds = true ), verify actual MIME type ( image/jpeg , image/png , image/webp ), and cap total pixels at 128 MP to prevent OOM bitmap bombs.
Native PDF rendering: Verify…