<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Saul Goodman</title>
    <description>The latest articles on DEV Community by Saul Goodman (@saul323).</description>
    <link>https://dev.to/saul323</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4279135%2F398b97ac-9958-4f01-940a-c024a8969b6c.jpg</url>
      <title>DEV Community: Saul Goodman</title>
      <link>https://dev.to/saul323</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/saul323"/>
    <language>en</language>
    <item>
      <title>Building a Hardened Android (Kotlin) + iOS (SwiftUI) CBZ/PDF/OPDS Reader &amp; a 20-Agent AI QA Fleet</title>
      <dc:creator>Saul Goodman</dc:creator>
      <pubDate>Wed, 02 Dec 2026 19:09:19 +0000</pubDate>
      <link>https://dev.to/saul323/building-a-hardened-android-kotlin-ios-swiftui-cbzpdfopds-reader-a-20-agent-ai-qa-fleet-1np5</link>
      <guid>https://dev.to/saul323/building-a-hardened-android-kotlin-ios-swiftui-cbzpdfopds-reader-a-20-agent-ai-qa-fleet-1np5</guid>
      <description>&lt;p&gt;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).&lt;/p&gt;

&lt;p&gt;I built &lt;strong&gt;PanelVerse&lt;/strong&gt; to solve that — a dual-native &lt;strong&gt;Android (Kotlin / Material 3)&lt;/strong&gt; and &lt;strong&gt;iOS (SwiftUI / iOS 16+)&lt;/strong&gt; comic, manga, and PDF reader designed for indie publishers and self-hosted &lt;strong&gt;Komga / Kavita / Calibre&lt;/strong&gt; libraries.&lt;/p&gt;

&lt;p&gt;Here are the four engineering decisions that mattered most:&lt;/p&gt;




&lt;h3&gt;
  
  
  1. Validating Untrusted CBZ &amp;amp; PDF Files On-Device
&lt;/h3&gt;

&lt;p&gt;Accepting local &lt;code&gt;.cbz&lt;/code&gt; and &lt;code&gt;.pdf&lt;/code&gt; files up to 250 MB means treating every archive as hostile input:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;ZIP-slip protection:&lt;/strong&gt; Reject any archive entry containing path traversal (&lt;code&gt;../&lt;/code&gt;), absolute paths, or backslashes before extraction.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Image-bounds validation:&lt;/strong&gt; Decode bounds first (&lt;code&gt;inJustDecodeBounds = true&lt;/code&gt;), verify actual MIME type (&lt;code&gt;image/jpeg&lt;/code&gt;, &lt;code&gt;image/png&lt;/code&gt;, &lt;code&gt;image/webp&lt;/code&gt;), and cap total pixels at &lt;strong&gt;128 MP&lt;/strong&gt; to prevent OOM bitmap bombs.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Native PDF rendering:&lt;/strong&gt; Verify &lt;code&gt;%PDF-&lt;/code&gt; magic bytes and page-count bounds via Android SDK &lt;code&gt;PdfRenderer&lt;/code&gt; before saving to app-private storage.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  2. XXE-Safe, HTTPS-Only OPDS 1.2 Browser
&lt;/h3&gt;

&lt;p&gt;Instead of relying on fragile web scrapers, PanelVerse includes a native &lt;strong&gt;OPDS 1.2 Atom&lt;/strong&gt; browser so users can connect their own self-hosted Komga, Kavita, or Calibre servers:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Disables DTDs and external entities (&lt;code&gt;disallow-doctype-decl&lt;/code&gt;, &lt;code&gt;external-general-entities&lt;/code&gt;, &lt;code&gt;external-parameter-entities&lt;/code&gt;) to block XXE.&lt;/li&gt;
&lt;li&gt;Rejects non-HTTPS URLs, embedded credentials, and SSL downgrades (&lt;code&gt;followSslRedirects(false)&lt;/code&gt;), with a strict 2 MB XML response cap.&lt;/li&gt;
&lt;li&gt;Downloads &lt;code&gt;.cbz&lt;/code&gt; and &lt;code&gt;.pdf&lt;/code&gt; acquisitions straight through the same validated offline import pipeline.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  3. Store Compliance &amp;amp; OWASP MASVS Hardening
&lt;/h3&gt;

&lt;p&gt;Google Play and Apple App Store reviews fail apps quickly when privacy or security is an afterthought:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Firebase security:&lt;/strong&gt; Least-privilege &lt;code&gt;database.rules.json&lt;/code&gt; verified by an automated emulator test suite + &lt;strong&gt;Firebase App Check (Play Integrity)&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Runtime anti-tampering:&lt;/strong&gt; Blocks &lt;code&gt;FLAG_DEBUGGABLE&lt;/code&gt; and attached debuggers in release builds, plus optional XOR-masked SHA-256 release signing certificate pinning configured via &lt;code&gt;gradle.properties&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Automated compliance gate:&lt;/strong&gt; A 12-check CI script verifies zero remote fonts, zero third-party ad/tracker SDKs, active Age Gate + server-timestamped Policy Consent, and one-tap &lt;strong&gt;Delete Account&lt;/strong&gt; (wiping Firebase Auth + all RTDB user nodes).&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  4. Testing With 20 Parallel AI User Personas
&lt;/h3&gt;

&lt;p&gt;Manually testing RTL layouts, long-text German/Swedish/Finnish compound words, and &lt;code&gt;1.4x&lt;/code&gt; accessibility font scales across 10+ devices takes days.&lt;/p&gt;

&lt;p&gt;So I built and bundled &lt;strong&gt;&lt;code&gt;mobile-agent-testers&lt;/code&gt;&lt;/strong&gt; right inside &lt;code&gt;tools/mobile-agent-testers/&lt;/code&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Uses &lt;strong&gt;Maestro CLI&lt;/strong&gt; (unified Android + iOS automation) + pluggable &lt;strong&gt;Google Gemini / Claude&lt;/strong&gt; vision backends.&lt;/li&gt;
&lt;li&gt;Spins up &lt;strong&gt;20 unique &lt;code&gt;(device × locale × persona)&lt;/code&gt; agents&lt;/strong&gt; in parallel via a GitHub Actions matrix strategy (e.g., &lt;em&gt;Anna, 68, 1.4x font on iPhone SE in Swedish&lt;/em&gt; and &lt;em&gt;Fatima, 42, RTL Arabic on Pixel 8&lt;/em&gt;).&lt;/li&gt;
&lt;li&gt;Annotates screenshots with severity bounding boxes (&lt;code&gt;BLOCKER&lt;/code&gt; / &lt;code&gt;MAJOR&lt;/code&gt; / &lt;code&gt;MINOR&lt;/code&gt;), deduplicates identical bugs across devices, and outputs &lt;code&gt;report.md&lt;/code&gt;, &lt;code&gt;report.json&lt;/code&gt;, and a single-file interactive &lt;code&gt;dashboard.html&lt;/code&gt;.
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;cd&lt;/span&gt; tools/mobile-agent-testers &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; ./setup.sh
mobile-agent-testers plan -c panelverse.yaml -n 20
mobile-agent-testers run -c panelverse.yaml -n 4 \
  --devices iphone-se,pixel-8 --locales sv-SE,ar-SA \
  --backend gemini --driver maestro
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  Check Out the Full Source Code
&lt;/h3&gt;

&lt;p&gt;If you're building an indie comic publisher app, self-hosted OPDS reader, or white-label PDF/manga reader and want to skip months of native boilerplate and security work, the complete Android + iOS source code (plus the 20-agent AI QA suite and 10-minute &lt;code&gt;BUYER_SETUP.md&lt;/code&gt;) is live here:&lt;/p&gt;

&lt;p&gt;👉 &lt;strong&gt;&lt;a href="https://saulicious5.gumroad.com/l/panelverse" rel="noopener noreferrer"&gt;Get PanelVerse on Gumroad&lt;/a&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Happy to answer any questions about Android &lt;code&gt;PdfRenderer&lt;/code&gt;, OPDS 1.2 parsing, Firebase App Check, or running Maestro + vision agents on GitHub Actions!&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fh9dz0nb98w0gih34t26k.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fh9dz0nb98w0gih34t26k.png" alt=" " width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

</description>
      <category>showdev</category>
      <category>android</category>
      <category>ios</category>
      <category>security</category>
    </item>
  </channel>
</rss>
