<?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: Keshav</title>
    <description>The latest articles on DEV Community by Keshav (@roninyt_).</description>
    <link>https://dev.to/roninyt_</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.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3949265%2Fd1b7424a-fe2f-444d-81ac-b5cc81ec6c44.jpg</url>
      <title>DEV Community: Keshav</title>
      <link>https://dev.to/roninyt_</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/roninyt_"/>
    <language>en</language>
    <item>
      <title>The Hardest Part of Building an Encrypted Journaling App Wasn’t Encryption</title>
      <dc:creator>Keshav</dc:creator>
      <pubDate>Tue, 26 May 2026 13:30:00 +0000</pubDate>
      <link>https://dev.to/roninyt_/the-hardest-part-of-building-an-encrypted-journaling-app-wasnt-encryption-3amj</link>
      <guid>https://dev.to/roninyt_/the-hardest-part-of-building-an-encrypted-journaling-app-wasnt-encryption-3amj</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;Lessons learned building client-side AES-256 encryption, secure sync, and emotionally safe UX in Flutter.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Most apps treat privacy as a feature.&lt;/p&gt;

&lt;p&gt;We treated it as infrastructure.&lt;/p&gt;

&lt;p&gt;When we started building RozVibe — a privacy-first encrypted journaling app built with Flutter — we quickly realized something uncomfortable:&lt;/p&gt;

&lt;p&gt;A journaling app without real privacy creates emotional hesitation.&lt;/p&gt;

&lt;p&gt;People write differently when they think someone else might read their thoughts.&lt;/p&gt;

&lt;p&gt;And that changes everything.&lt;/p&gt;

&lt;p&gt;Because journaling is not just data storage.&lt;/p&gt;

&lt;p&gt;It’s cognitive decompression.&lt;/p&gt;

&lt;p&gt;It’s emotional honesty.&lt;/p&gt;

&lt;p&gt;And honesty requires trust.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;The Problem With Most “Private” Apps&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;A surprising number of apps marketed as “private” still process user data server-side.&lt;/p&gt;

&lt;p&gt;Yes, they may use HTTPS.&lt;/p&gt;

&lt;p&gt;Yes, databases may be encrypted at rest.&lt;/p&gt;

&lt;p&gt;But in many systems:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;the company can still access user content&lt;/li&gt;
&lt;li&gt;administrators theoretically retain visibility&lt;/li&gt;
&lt;li&gt;journal entries may be processed in plaintext&lt;/li&gt;
&lt;li&gt;personal reflections become behavioral analytics data&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Technically, the data may be secured.&lt;/p&gt;

&lt;p&gt;Psychologically, it still doesn’t feel safe.&lt;/p&gt;

&lt;p&gt;That distinction became incredibly important while designing RozVibe.&lt;/p&gt;

&lt;p&gt;Because emotional safety is not only a UX problem.&lt;/p&gt;

&lt;p&gt;It’s an architectural problem.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Our Decision: Encrypt Before Data Leaves the Device&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;From the beginning, we adopted a strict engineering principle:&lt;/p&gt;

&lt;p&gt;User journal content should never be readable by our servers.&lt;/p&gt;

&lt;p&gt;That decision immediately shaped the entire system architecture.&lt;/p&gt;

&lt;p&gt;Instead of relying on traditional server-side encryption, we implemented client-side AES-256-GCM encryption directly on the device.&lt;/p&gt;

&lt;p&gt;Before any journal entry is synced:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Content is encrypted locally&lt;/li&gt;
&lt;li&gt;A unique nonce/IV is generated for every encryption operation&lt;/li&gt;
&lt;li&gt;Authentication tags are attached&lt;/li&gt;
&lt;li&gt;Only ciphertext is transmitted to the backend&lt;/li&gt;
&lt;li&gt;The server stores encrypted blobs only&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The backend never sees plaintext journal entries.&lt;/p&gt;

&lt;p&gt;Even if storage infrastructure were compromised, the stored data would remain unreadable without user-controlled encryption keys.&lt;/p&gt;

&lt;p&gt;That trust model mattered deeply to us.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Why We Didn’t Use Server-Side Encryption&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Server-side encryption solves infrastructure security problems.&lt;/p&gt;

&lt;p&gt;But it does not fully solve trust problems.&lt;/p&gt;

&lt;p&gt;With server-side encryption:&lt;/p&gt;

&lt;p&gt;the backend still controls decryption&lt;br&gt;
plaintext may exist during processing&lt;br&gt;
administrators can theoretically access content&lt;br&gt;
users must trust infrastructure they cannot verify&lt;/p&gt;

&lt;p&gt;We wanted a different model.&lt;/p&gt;

&lt;p&gt;In RozVibe, encryption happens before data leaves the device.&lt;/p&gt;

&lt;p&gt;The server stores ciphertext — not journal entries.&lt;/p&gt;

&lt;p&gt;That architectural distinction fundamentally changes the relationship between the product and the user.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Why AES-256-GCM?&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;We evaluated multiple encryption approaches before choosing AES-256-GCM.&lt;/p&gt;

&lt;p&gt;For a mobile journaling application, we needed:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;authenticated encryption&lt;/li&gt;
&lt;li&gt;strong security guarantees&lt;/li&gt;
&lt;li&gt;tamper detection&lt;/li&gt;
&lt;li&gt;low performance overhead&lt;/li&gt;
&lt;li&gt;reliable mobile compatibility&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;AES-GCM offered all of those advantages.&lt;/p&gt;

&lt;p&gt;Performance mattered more than we initially expected.&lt;/p&gt;

&lt;p&gt;People open journaling apps during emotionally important moments:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;late-night reflection&lt;/li&gt;
&lt;li&gt;anxiety spikes&lt;/li&gt;
&lt;li&gt;emotional overwhelm&lt;/li&gt;
&lt;li&gt;quick memory capture&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Encryption cannot introduce noticeable friction.&lt;/p&gt;

&lt;p&gt;Otherwise people stop writing.&lt;/p&gt;

&lt;p&gt;One of the most overlooked parts of privacy engineering is this:&lt;/p&gt;

&lt;p&gt;Security that feels heavy often becomes abandoned security.&lt;/p&gt;

&lt;p&gt;AES-GCM gave us both security and responsiveness.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;The Hardest Engineering Problem Wasn’t Encryption&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Surprisingly, implementing encryption itself was not the hardest challenge.&lt;/p&gt;

&lt;p&gt;Key management was.&lt;/p&gt;

&lt;p&gt;Because encryption strength becomes meaningless if key handling is weak.&lt;/p&gt;

&lt;p&gt;Mobile apps constantly deal with unstable environments:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;devices restart&lt;/li&gt;
&lt;li&gt;sessions expire&lt;/li&gt;
&lt;li&gt;users reinstall apps&lt;/li&gt;
&lt;li&gt;cloud sync introduces edge cases&lt;/li&gt;
&lt;li&gt;operating systems aggressively manage memory&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;We explored multiple approaches:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Secure Enclave / Keystore integration&lt;/li&gt;
&lt;li&gt;OS-protected secret storage&lt;/li&gt;
&lt;li&gt;session-derived keys&lt;/li&gt;
&lt;li&gt;encrypted persistence layers&lt;/li&gt;
&lt;li&gt;recovery edge cases&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Balancing usability with strong security became one of the most difficult architectural tradeoffs in the entire project.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Privacy-First Architecture Changes Everything&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;One of the surprising realizations during development was how quickly privacy-first architecture complicates otherwise normal product decisions.&lt;/p&gt;

&lt;p&gt;Even simple features become harder when the backend is intentionally blind.&lt;/p&gt;

&lt;p&gt;For example:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Search&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Traditional search systems index plaintext content server-side.&lt;/p&gt;

&lt;p&gt;Encrypted journaling systems cannot safely do that.&lt;/p&gt;

&lt;p&gt;That forces difficult tradeoffs:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;local indexing&lt;/li&gt;
&lt;li&gt;encrypted search models&lt;/li&gt;
&lt;li&gt;limited search capabilities&lt;/li&gt;
&lt;li&gt;offline-first constraints&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Syncing&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Traditional sync systems assume the backend understands the data structure.&lt;/p&gt;

&lt;p&gt;Encrypted sync changes that completely.&lt;/p&gt;

&lt;p&gt;The server becomes intentionally unaware of:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;journal content&lt;/li&gt;
&lt;li&gt;emotional metadata&lt;/li&gt;
&lt;li&gt;search context&lt;/li&gt;
&lt;li&gt;user meaning&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That affected:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;conflict resolution&lt;/li&gt;
&lt;li&gt;sync optimization&lt;/li&gt;
&lt;li&gt;storage debugging&lt;/li&gt;
&lt;li&gt;recovery flows&lt;/li&gt;
&lt;li&gt;consistency handling&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Privacy-first engineering forces you to rethink standard SaaS assumptions from the ground up.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Security UX Is Emotional UX&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;One lesson became increasingly clear while building RozVibe:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Security UX is emotional UX.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;If privacy tools feel intimidating, users disengage.&lt;/p&gt;

&lt;p&gt;Many secure products accidentally create anxiety through:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;aggressive warnings&lt;/li&gt;
&lt;li&gt;technical overload&lt;/li&gt;
&lt;li&gt;complicated onboarding&lt;/li&gt;
&lt;li&gt;“cybersecurity dashboard” aesthetics&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;We wanted the opposite.&lt;/p&gt;

&lt;p&gt;So we intentionally designed RozVibe with:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;minimal visual noise&lt;/li&gt;
&lt;li&gt;calm writing spaces&lt;/li&gt;
&lt;li&gt;quiet onboarding&lt;/li&gt;
&lt;li&gt;simple privacy explanations&lt;/li&gt;
&lt;li&gt;reduced cognitive overload&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;We didn’t want users to constantly think about encryption.&lt;/p&gt;

&lt;p&gt;We wanted them to feel psychologically safe enough to write honestly.&lt;/p&gt;

&lt;p&gt;That distinction matters more than many engineers realize.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Privacy Is Also a Psychological Design Problem&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Building RozVibe changed how we think about software itself.&lt;/p&gt;

&lt;p&gt;Modern apps are often optimized for:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;engagement&lt;/li&gt;
&lt;li&gt;retention&lt;/li&gt;
&lt;li&gt;extraction&lt;/li&gt;
&lt;li&gt;behavioral profiling&lt;/li&gt;
&lt;li&gt;surveillance-driven personalization&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Over time, users subconsciously learn this.&lt;/p&gt;

&lt;p&gt;And they become less honest online.&lt;/p&gt;

&lt;p&gt;Especially in personal spaces.&lt;/p&gt;

&lt;p&gt;People begin self-censoring.&lt;/p&gt;

&lt;p&gt;Even privately.&lt;/p&gt;

&lt;p&gt;That realization fundamentally changed how we approached product design.&lt;/p&gt;

&lt;p&gt;Instead of asking:&lt;/p&gt;

&lt;p&gt;“How much data can we collect?”&lt;/p&gt;

&lt;p&gt;We started asking:&lt;/p&gt;

&lt;p&gt;“How little data do we actually need?”&lt;/p&gt;

&lt;p&gt;Instead of:&lt;/p&gt;

&lt;p&gt;“How do we maximize engagement?”&lt;/p&gt;

&lt;p&gt;We ask:&lt;/p&gt;

&lt;p&gt;“How do we reduce emotional friction?”&lt;/p&gt;

&lt;p&gt;Instead of:&lt;/p&gt;

&lt;p&gt;“How do we maximize retention?”&lt;/p&gt;

&lt;p&gt;We ask:&lt;/p&gt;

&lt;p&gt;“How do we create trust?”&lt;/p&gt;

&lt;p&gt;Those questions lead to very different software.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;What Building RozVibe Taught Us&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Before building RozVibe, we viewed encryption mostly as a technical system.&lt;/p&gt;

&lt;p&gt;Now we see it differently.&lt;/p&gt;

&lt;p&gt;For deeply personal software, encryption becomes emotional infrastructure.&lt;/p&gt;

&lt;p&gt;It gives people space to think honestly without feeling observed.&lt;/p&gt;

&lt;p&gt;And honestly, building privacy-first software changed the way we think about engineering entirely.&lt;/p&gt;

&lt;p&gt;Not just technically.&lt;/p&gt;

&lt;p&gt;Philosophically.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Final Thoughts&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;The internet has trained people to expect surveillance by default.&lt;/p&gt;

&lt;p&gt;That expectation quietly changes human behavior.&lt;/p&gt;

&lt;p&gt;Especially in emotionally vulnerable spaces.&lt;/p&gt;

&lt;p&gt;Maybe privacy-first software is ultimately about restoring something much simpler:&lt;/p&gt;

&lt;p&gt;The ability to be honest with yourself.&lt;/p&gt;

&lt;p&gt;If you’re building privacy-first products, secure systems, or thoughtful software architecture, I’d genuinely love to hear how you think about trust, encryption, and emotional safety in modern apps.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;About RozVibe&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;RozVibe is a privacy-first encrypted journaling app focused on emotional safety, secure reflection, calm UX, and client-side encrypted storage.&lt;/p&gt;

&lt;p&gt;Download: &lt;a href="https://rozvibe.uptodown.com/" rel="noopener noreferrer"&gt;https://rozvibe.uptodown.com/&lt;/a&gt;&lt;/p&gt;

</description>
      <category>flutter</category>
      <category>security</category>
      <category>privacy</category>
      <category>programming</category>
    </item>
  </channel>
</rss>
