<?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: Matéo Callec</title>
    <description>The latest articles on DEV Community by Matéo Callec (@mateocallec).</description>
    <link>https://dev.to/mateocallec</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%2F3925799%2F65c3df55-c4d9-4358-8249-c289d9e63859.png</url>
      <title>DEV Community: Matéo Callec</title>
      <link>https://dev.to/mateocallec</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/mateocallec"/>
    <language>en</language>
    <item>
      <title>Building a Post-Quantum E2EE Library: Introducing Paranoia.ts (searching contributors)</title>
      <dc:creator>Matéo Callec</dc:creator>
      <pubDate>Fri, 15 May 2026 09:55:49 +0000</pubDate>
      <link>https://dev.to/mateocallec/building-a-post-quantum-e2ee-library-introducing-paranoiats-searching-contributors-1em3</link>
      <guid>https://dev.to/mateocallec/building-a-post-quantum-e2ee-library-introducing-paranoiats-searching-contributors-1em3</guid>
      <description>&lt;p&gt;The web security landscape is about to change dramatically.&lt;/p&gt;

&lt;p&gt;For years, modern cryptography has relied on algorithms like RSA and elliptic-curve cryptography (ECC). They are battle-tested and secure against classical computers — but quantum computing changes the equation entirely.&lt;/p&gt;

&lt;p&gt;Once large-scale quantum computers become practical, many of today’s public-key systems will become vulnerable.&lt;/p&gt;

&lt;p&gt;That future may still be years away, but encrypted data stolen today can still be decrypted later.&lt;/p&gt;

&lt;p&gt;This is why post-quantum cryptography (PQC) matters now.&lt;/p&gt;

&lt;p&gt;And yet, if you are a JavaScript or TypeScript developer, the ecosystem for PQC is still surprisingly small.&lt;/p&gt;

&lt;p&gt;That’s why I built &lt;strong&gt;Paranoia.ts&lt;/strong&gt;.&lt;/p&gt;




&lt;h2&gt;
  
  
  What is Paranoia.ts?
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Paranoia.ts&lt;/strong&gt; is a TypeScript-first cryptography library designed for frontend and full-stack applications that need:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;End-to-end encryption (E2EE)&lt;/li&gt;
&lt;li&gt;Post-quantum resistance&lt;/li&gt;
&lt;li&gt;Optimization&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The goal is simple:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Make post-quantum encryption practical and accessible for JavaScript developers.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Repositories:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;GitHub: &lt;a href="https://github.com/mateocallec/paranoia.ts" rel="noopener noreferrer"&gt;https://github.com/mateocallec/paranoia.ts&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;NPM: &lt;a href="https://www.npmjs.com/package/paranoia-ts" rel="noopener noreferrer"&gt;https://www.npmjs.com/package/paranoia-ts&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;




&lt;h1&gt;
  
  
  Why hybrid cryptography matters
&lt;/h1&gt;

&lt;p&gt;One of the biggest problems in modern PQC adoption is uncertainty.&lt;/p&gt;

&lt;p&gt;Post-quantum algorithms are newer than classical cryptographic systems. While they are standardized and heavily researched, they do not yet have the same decades-long track record as ECC.&lt;/p&gt;

&lt;p&gt;So Paranoia.ts does not force developers to choose between classical cryptography and post-quantum cryptography.&lt;/p&gt;

&lt;p&gt;It combines both.&lt;/p&gt;

&lt;p&gt;The library currently uses:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;ML-KEM-1024&lt;/strong&gt; (NIST FIPS 203)&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;P-521 ECDH&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;HKDF-SHA-384&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;AES-256-GCM&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The key idea is hybrid security:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Scenario&lt;/th&gt;
&lt;th&gt;Classical ECC&lt;/th&gt;
&lt;th&gt;PQC only&lt;/th&gt;
&lt;th&gt;Paranoia.ts&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Classical attacker&lt;/td&gt;
&lt;td&gt;✅&lt;/td&gt;
&lt;td&gt;⚠️&lt;/td&gt;
&lt;td&gt;✅&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Quantum attacker&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;td&gt;✅&lt;/td&gt;
&lt;td&gt;✅&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;PQC algorithm weakness&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;td&gt;✅&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;ECC weakness&lt;/td&gt;
&lt;td&gt;✅&lt;/td&gt;
&lt;td&gt;❌&lt;/td&gt;
&lt;td&gt;✅&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;In practice:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;An attacker would need to break both ML-KEM-1024 and P-521 simultaneously to recover plaintext.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;That significantly improves resilience against future uncertainty.&lt;/p&gt;




&lt;h1&gt;
  
  
  Example: Post-Quantum E2EE in TypeScript
&lt;/h1&gt;

&lt;p&gt;The library is intentionally designed to feel simple.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;Paranoia&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;paranoia-ts&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;paranoia&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nc"&gt;Paranoia&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;

&lt;span class="c1"&gt;// Generate hybrid ML-KEM + P-521 keypair&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;keyPair&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;paranoia&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;generateKeyPair&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;

&lt;span class="c1"&gt;// Encrypt&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;sealed&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;paranoia&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;sealTo&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
  &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nc"&gt;TextEncoder&lt;/span&gt;&lt;span class="p"&gt;().&lt;/span&gt;&lt;span class="nf"&gt;encode&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;Top secret message&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;
  &lt;span class="nx"&gt;keyPair&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;publicKey&lt;/span&gt;
&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="c1"&gt;// Decrypt&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;plain&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;paranoia&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;unsealWith&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;sealed&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;keyPair&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nc"&gt;TextDecoder&lt;/span&gt;&lt;span class="p"&gt;().&lt;/span&gt;&lt;span class="nf"&gt;decode&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;plain&lt;/span&gt;&lt;span class="p"&gt;));&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The objective is to expose advanced cryptography through a developer-friendly API without sacrificing transparency.&lt;/p&gt;




&lt;h1&gt;
  
  
  Beyond PQC: Experimental security features
&lt;/h1&gt;

&lt;p&gt;Paranoia.ts also explores ideas that are still relatively uncommon in web cryptography libraries.&lt;/p&gt;

&lt;p&gt;Some are experimental by design.&lt;/p&gt;

&lt;h2&gt;
  
  
  Webcam-based TRNG
&lt;/h2&gt;

&lt;p&gt;One of the most unusual features in the project is webcam entropy generation.&lt;/p&gt;

&lt;p&gt;The library can harvest webcam sensor noise and pixel variation as an additional entropy source.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;stream&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nb"&gt;navigator&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;mediaDevices&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getUserMedia&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt; &lt;span class="na"&gt;video&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt; &lt;span class="p"&gt;});&lt;/span&gt;

&lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;paranoia&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;enableWebcamEntropy&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;stream&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Internally:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Pixel noise is sampled from webcam frames&lt;/li&gt;
&lt;li&gt;Data is hashed with SHA3-256&lt;/li&gt;
&lt;li&gt;Mixed into the CSPRNG pool via HMAC&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This does &lt;strong&gt;not&lt;/strong&gt; replace the browser’s cryptographically secure RNG.&lt;/p&gt;

&lt;p&gt;Instead, it augments entropy generation for environments where additional randomness is desirable.&lt;/p&gt;




&lt;h2&gt;
  
  
  WebAuthn PRF integration
&lt;/h2&gt;

&lt;p&gt;Another major feature is WebAuthn PRF support.&lt;/p&gt;

&lt;p&gt;This enables hardware-backed key unlocking using:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Biometrics&lt;/li&gt;
&lt;li&gt;Security keys&lt;/li&gt;
&lt;li&gt;Platform authenticators&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The result is a workflow where users can unlock encrypted keypairs with a fingerprint or security key rather than repeatedly entering passwords.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;credentialId&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;prfKey&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nf"&gt;registerWebAuthnPRF&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
&lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nf"&gt;storeKeyPair&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;keyPair&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;prfKey&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;my-key&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This brings together:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;WebAuthn&lt;/li&gt;
&lt;li&gt;Browser-native crypto&lt;/li&gt;
&lt;li&gt;Post-quantum encryption&lt;/li&gt;
&lt;li&gt;Secure local storage&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;…inside a single TypeScript library.&lt;/p&gt;




&lt;h1&gt;
  
  
  Security philosophy
&lt;/h1&gt;

&lt;p&gt;One thing I want to make explicit:&lt;/p&gt;

&lt;p&gt;Paranoia.ts does &lt;strong&gt;not&lt;/strong&gt; pretend JavaScript is a perfect environment for high-assurance cryptography.&lt;/p&gt;

&lt;p&gt;The README openly documents limitations such as:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Garbage collector memory copying&lt;/li&gt;
&lt;li&gt;Non-wipeable JS strings&lt;/li&gt;
&lt;li&gt;Browser implementation constraints&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The project tries to balance:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Practicality&lt;/li&gt;
&lt;li&gt;Browser compatibility&lt;/li&gt;
&lt;li&gt;Transparency&lt;/li&gt;
&lt;li&gt;Defense in depth&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Security tooling should be honest about tradeoffs.&lt;/p&gt;




&lt;h1&gt;
  
  
  Reference implementation
&lt;/h1&gt;

&lt;p&gt;To demonstrate real-world usage, I also built a complete encrypted messaging application using Paranoia.ts:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://github.com/mateocallec/paranoia-messaging" rel="noopener noreferrer"&gt;https://github.com/mateocallec/paranoia-messaging&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;It demonstrates:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;End-to-end encrypted chat&lt;/li&gt;
&lt;li&gt;Hybrid PQC encryption&lt;/li&gt;
&lt;li&gt;WebAuthn biometric unlock&lt;/li&gt;
&lt;li&gt;Secure key storage&lt;/li&gt;
&lt;li&gt;Full-stack integration&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Stack:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;React&lt;/li&gt;
&lt;li&gt;NestJS&lt;/li&gt;
&lt;li&gt;Docker&lt;/li&gt;
&lt;li&gt;TypeScript&lt;/li&gt;
&lt;/ul&gt;




&lt;h1&gt;
  
  
  Looking for contributors
&lt;/h1&gt;

&lt;p&gt;This project is still early, and there is a lot to build.&lt;/p&gt;

&lt;p&gt;I am currently looking for contributors interested in:&lt;/p&gt;

&lt;h2&gt;
  
  
  Security
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Cryptographic review&lt;/li&gt;
&lt;li&gt;Threat modeling&lt;/li&gt;
&lt;li&gt;Side-channel analysis&lt;/li&gt;
&lt;li&gt;Security auditing&lt;/li&gt;
&lt;li&gt;Protocol analysis&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Engineering
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;WebAssembly optimization&lt;/li&gt;
&lt;li&gt;Browser compatibility&lt;/li&gt;
&lt;li&gt;Performance improvements&lt;/li&gt;
&lt;li&gt;DX improvements&lt;/li&gt;
&lt;li&gt;Test coverage&lt;/li&gt;
&lt;li&gt;API design&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Research &amp;amp; experimentation
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Additional PQC algorithms&lt;/li&gt;
&lt;li&gt;Better entropy collection&lt;/li&gt;
&lt;li&gt;Secure memory handling&lt;/li&gt;
&lt;li&gt;Hardware integration&lt;/li&gt;
&lt;li&gt;Advanced WebAuthn flows&lt;/li&gt;
&lt;/ul&gt;




&lt;h1&gt;
  
  
  Why contribute?
&lt;/h1&gt;

&lt;p&gt;PQC is going to become one of the defining security challenges of the next decade.&lt;/p&gt;

&lt;p&gt;JavaScript applications will eventually need:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Quantum-resistant encryption&lt;/li&gt;
&lt;li&gt;Browser-native secure key management&lt;/li&gt;
&lt;li&gt;Better client-side cryptography&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The ecosystem around this is still very small.&lt;/p&gt;

&lt;p&gt;This is an opportunity to help shape what post-quantum cryptography tooling looks like for the web.&lt;/p&gt;

&lt;p&gt;All contributors will be publicly credited.&lt;/p&gt;




&lt;h1&gt;
  
  
  Final thoughts
&lt;/h1&gt;

&lt;p&gt;I believe the future of web security will require:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Hybrid cryptography&lt;/li&gt;
&lt;li&gt;Hardware-backed authentication&lt;/li&gt;
&lt;li&gt;Better entropy systems&lt;/li&gt;
&lt;li&gt;Developer-friendly APIs&lt;/li&gt;
&lt;li&gt;Open-source collaboration&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Paranoia.ts is an attempt to explore that future.&lt;/p&gt;

&lt;p&gt;If this sounds interesting to you, feel free to contribute, review the code, open issues, or simply share feedback.&lt;/p&gt;

&lt;p&gt;Repositories:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://github.com/mateocallec/paranoia.ts" rel="noopener noreferrer"&gt;https://github.com/mateocallec/paranoia.ts&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://www.npmjs.com/package/paranoia-ts" rel="noopener noreferrer"&gt;https://www.npmjs.com/package/paranoia-ts&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://www.npmjs.com/package/paranoia-cli" rel="noopener noreferrer"&gt;https://www.npmjs.com/package/paranoia-cli&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I’d love to hear thoughts from other developers and security researchers working in this space.&lt;/p&gt;

</description>
      <category>opensource</category>
      <category>security</category>
      <category>showdev</category>
      <category>typescript</category>
    </item>
  </channel>
</rss>
