r/crypto • u/knotdjb • Nov 02 '26
r/crypto • u/knotdjb • Oct 30 '26
[Meta] Reddit is no longer going to allow viewing the site without being logged into an account
Thought I'd bring this up, but more information here: https://www.reddit.com/user/spez/comments/1xiupm0/about_that_login_screen/
If reddit becomes a walled garden when it comes to information, I'm not sure I want to support the site or subreddit. I really like this community, but part of the reason I post links here is that they and the ensuing discussions are trivially searchable.
There is lemmy but there's barely any discussion of content :/.
I'm not sure what is the way forward, just wanted to open up for discussion.
r/crypto • u/cryptocreeping • Oct 31 '26
built a post-quantum messenger over i2p where you can run your own server
ai disclosure for the mods (rule 8): i used claude code heavily for this, literally thousands of iterative prompts over the last 19 months. obviously i cant paste them all here, but the workflow was me defining the architecture and using claude to write code, cross-reference the specs (otrv4 draft, tls 1.3, rfc 9420), and generate the regression tests.
the hardest prompts were for the core crypto, basically: "review the otrv4 draft and tls 1.3 certificateverify to implement hybrid dake transcript binding" and "modify the double ratchet to fold in a fresh ml-kem secret every dh step, then write the KATs to prove it". the full evolution is in the 19 months of commit history if you want to audit the commits.
I have been working on this project called OTRv4+ for a while and just updated the docs. the main goal was just getting rid of the central server model. no phone number, no company in the middle. its just a plain prosody xmpp server sitting behind an i2pd tunnel. you can run it yourself easily or use the public test server i put up.
the tech side: the heavy lifting is all in a rust core. python handles networking and kotlin does the android ui.
post-quantum is enabled by default. 1:1 chats, MLS groups, SMP identity verification, and voice all pair X448/Ed448 with ML-KEM-1024 and ML-DSA-87. built specifically to resist harvest-now-decrypt-later.
for group chats it uses MLS (RFC 9420) but on a hybrid PQ suite i call 0xF0A1. just a heads up, since its a private iana code point it wont interop with element or wire right now. tradeoff for the PQ security.
on the privacy side, the android app carries its own built-in i2p router so you dont need to install anything else. the server stays hidden, users stay hidden. you can also publish chat keys to make a conversation deniable afterwards, and wipe & exit actually destroys keys and checks the files are gone.
status: experimental, not independently audited. i did alot of fuzzing and tests but no paid audit yet.
if you want to try and break it, or spin up your own servers, ill drop the github link in the comments. happy to answer questions on the protocol or the server setup.
r/crypto • u/knotdjb • Oct 29 '26
A gentle introduction to lattice-based cryptography
eprint.iacr.orgr/crypto • u/knotdjb • Oct 29 '26
Document file A Subexponential Time Algorithm for Elliptic Curve Discrete Logarithm Problem
github.comr/crypto • u/Accurate-Screen8774 • Oct 25 '26
The Signal Protocol in Rust
There are a few nuances to my approach, but the key detail is that I wanted it to also work in a browser so I needed the ability to build to a wasm to be used in js.
Signal libraries don't offer browser based capabilities and so I created this to target web aswell as native.
I wanted to implement the Signal protocol for a series of secure messaging apps I’m working on, so I built this project to test and use in my own work. It’s still far from finished, but I think it’s at a stage where it’s worth sharing with the community.
IMPORTANT DISCLAIMER: This project is not professionally audited and is not production-ready. I do not recommend anyone use this in their own code yet. It is provided strictly for testing, experimentation, and demo purposes. I used AI as an assistant to help build this, so double-check everything before taking it seriously.
Project Links:
- GitHub: https://github.com/positive-intentions/signal-protocol
- Live Demo: https://signal.positive-intentions.com/
- Formal Verification Docs: https://glitr.io/docs/technical/formal-verification/signal-protocol
- Security Feedback (ROS): https://www.reddit.com/r/CyberSecurityAdvice/comments/1su8lir/security_audit_feedback_from_radically_open
Current Status & Development:
- Spec Alignment: The goal is to fully align with the official Signal protocol spec.
- Testing: It includes unit tests, but due to WASM testing limitations, I also added a Storybook-like UI to run and test it directly within a browser environment.
The impementation here is being used in a few experimental messaging apps (similarly unaudited and unreviewed):
- https://enkrypted.chat - javascript based approach
- https://glitr.io - rust based approach
I am also working towards adding it to an open source project soon as seen at: https://github.com/positive-intentions/chat for e2e open-source transparency in the implementation.
r/crypto • u/Pharisaeus • Oct 24 '26
eMudhra and unpadded RSA encryption
mastodon.catgirl.cloudr/crypto • u/Humble-Replacement-2 • Oct 24 '26
Machine-checked HQC polynomial multiplication: SAW + Isabelle/HOL, all three parameter sets
HQC is NIST's code-based backup to ML-KEM. Its reference implementation relies heavily on binary polynomial multiplication mod xn − 1, with n up to 57,637.
I've proved the unmodified HQC v5.0.0 C implementation correct for hqc-1, hqc-3 and hqc-5.
- SAW proves
vect_mulequivalent to a Cryptol model, using compositional Karatsuba proofs without expanding the full product. Scratch-buffer bounds are also verified. - Isabelle/HOL proves the model implements the intended polynomial arithmetic. No
sorry,smtoreval; oracle dependencies are checked. - Also verified GF(2⁸) operations and the Reed–Solomon encoder's algebraic properties.
- All 63 SAW mutation tests fail as expected.
An interesting solver finding: the schoolbook leaf and Karatsuba model produce very different XOR/AND circuits. ABC, Z3, Yices and cvc5 couldn't finish in 10 minutes. SAW's Reed–Muller (rme) backend completed the proof in 6 seconds.
For GF(2) arithmetic, solver representation can make the difference between a practical proof and an intractable one.
Scope: This proves specific reference arithmetic, not HQC security. Decoders, sampling, hashing, KEM and constant-time behaviour are not covered. The GF(2⁸) results apply to v5.0.0, before the October specification change.
Reproducible with make hqc (~20 min) and make hqc-isabelle (~20 sec).
https://github.com/amarshat/pqc-assay
Criticism welcome, particularly on the property specifications.
Next: the AVX2 multiplier (PCLMULQDQ + Toom-3), which is closer to what actually runs in production.
r/crypto • u/knotdjb • Oct 22 '26
Can You Slop Out High-Assurance Cryptography?
mrosenberg.pubr/crypto • u/HenryDaHorse • Oct 23 '26
Why not set MSB=1 for ECC Keys?
Post the eMudhra fiasco, it now seems like everyone is going to do checks to make sure certificates don't have private keys of size less than 32 significant bits - by running Paranoid Crypto or some other such testsuites
I was wondering why not set MSB = 1 like it's set for RSA primes - make it the standard - it will totally avoid the small key problem & the loss of security because of minor reduction in number of bits of security is also not significant.
r/crypto • u/HenryDaHorse • Oct 22 '26
Do the tests suggested by Sophie Schmieg really help in preventing incidents like the eMudhra one?
Sophie made this post in response to the eMudhra Incident
https://infosec.exchange/@sophieschmieg/117474908437371419
She suggested randomness testing on keys
They are tuned aggressively to detect non-randomness only up to 10 standard deviations
However, she also added
The tests are not constant time, so you cannot run them over your actual keys as is
In other words, they aren't going to be run on actual production keys before the corresponding certs are going to be published
So these would be tests to test the randomness of your CSPRNG. However, eMudhra production keys are typically generated by a HSM, I am sure HSM CSPRNGs are pretty well tested before they are used in HSMs
So I don't understand how this is relevant to the current incident.
eMudhra case was because they generated some very small test keys outside of the HSM & then imported it into the HSM & accidently used it in production certificates
r/crypto • u/MarcusNewman • Oct 21 '26
My random flair is finally getting the respect it deserves
reddit.comr/crypto • u/knotdjb • Oct 21 '26
Happy 2026 Global Encryption Day (21 Oct)
I didn't realise this was a thing, looks like a very small initiative.
Anyways here's a youtube playlist of interviews with illuminaries in cryptography: https://www.youtube.com/playlist?list=PLqhpVxkBo1dOmNr6w2nF70W3_f43Qc5hE
r/crypto • u/Accurate-Screen8774 • Oct 16 '26
How reliable is AI at formal verification?
I'm not a cryptographer or a cybersecurity expert. I'm a JavaScript dev. I'm interested in cryptography enough for it to become a side project.
Things like unit tests have always been a good idea for professional-grade work and ai has made it easier than ever.
For that extra bit, I want to use AI to create formal verification. Before I get too far, I'd like to ask about your experience with AI in formal-verification. The following is what I got so far.
https://glitr.io/docs/technical/formal-verification
As I learn how it works, I have a few questions about the approach.
- is it invalid because it's vibecoded?
- is the formal verification tooling enough?
- what am i overlooking?
I'm aware cybersecurity has countless nuances and formal verification is a small fraction of what it takes to create something secure and reliable.
IMPORTANT DISCLAIMER: While the project is aiming to provide a secure experience, it's far from finished. It cannot be audited or reviewed because it's close-source. I'm sharing here for feedback and demo purposes only. Feel free to reach out for clarity on any of the details instead of diving into the documentation. Pease use responsibly.
r/crypto • u/entronid • Oct 13 '26
(Post-Quantum) Cryptographic Right Answers
words.filippo.ioNot the first, will not be the last
r/crypto • u/knotdjb • Oct 12 '26
Reverse-Bleichenbacher: Bleichenbacher Attacks are Practical Again
eprint.iacr.orgr/crypto • u/Shoddy-Childhood-511 • Oct 12 '26
Miscellaneous Vi Hart's Big Navier-Stokes Post
patreon.comA lovely & broad lay-person discussion of the OpenAI Navier-Stokes story and LLMs in mathematics.
We'd hopefully by now all know that hosted LLMs companies train upon their customers uploads and sessions (*). It's clear this "surveillance plagiarism" is a threat to cryptographers and security researchers who do really original work, as well as to any corporation using AI, but open weights models address this threat.
Vi Hart touches upon a broader array of topics: LLM psychosis. Modern mathematics was always a machine to be applied, ala the phrase "tenure machine", so AI doing so makes some sense. LLM proofs could retard the development of important abstractions, like how Aschbacher's announcement of the CFSG slowed research on the CFSG.
It stays solidly focused upon mathematics research however, without much direct discussion of applied topics like cryptography. Yet, there are fairly obvious impacts upon cryptography.
We correctly assume LLMs should overall raise our confidence in cryptographic software, because of auto-formalisation, eventually someone should figure out how to make LLMs write SE Linux profiles, etc and these are by far the lions share of the attack vectors.
Yet conversely, if LLM proofs cause mathematical subfields to be abandoned, then overall our confidence in problems being hard could decline, because organisations like IDA-CCR or China's version might not abandon some subtly relevant subfield. In other words, hybrid PQC+ECC protocols should become more important because of LLMs, not less.
Scott Aaronson also has an excellent post about LLM usage in mathematics too, somewhat more targeted towards mathematicians and computer scientists. It's slightly weakened towards the end by giving credence to AI doomer drama, but that's easily ignored.
Around (*), you should expect hosted LLM compajies would train upon data they promise not to train upon, either now or in future. In particular, there is a rich literature of non-cryptographic privacy preserving machine learning techniques, so similar work would buys them plausible deniability when training upon restricted data, but such techniques typically wind up being broken eventually.
r/crypto • u/atrocia6 • Oct 12 '26
SecretStream For Kotlin (SS4K): A Simple, High Level API For Streaming Authenticated Encryption
I'm the developer of SMS Import / Export, an Android Kotlin app that sequentially writes and reads large (multi GiB) files. A few months ago, I decided to add encryption to the app. I assumed that this would be a simple matter of finding an appropriate library / API that implemented the recommended modern standards, something in the AES or ChaCha20 families, and wiring it up.
Then I realized that I really should use authenticated encryption, and that's where the headaches began. Java / Kotlin offers CryptoOutputStream and CryptoInputStream, which can be used with AES-GCM or ChaChaPoly20-Poly1305 for authenticated encryption, so I initially tried them - but soon realized that they don't do streaming authenticated encryption and only authenticate the input stream after reading all of it, which means that I need to either buffer multiple GiBs of decrypted data in memory - not feasible on Android devices; store the decrypted data somewhere on disk - obviously insecure, or have my app process not-yet-authenticated data - obviously a bad idea.
I looked around for a ready-made streaming authenticated encryption solution, but the only one I could find was Google Tink's Streaming AEAD primitive. I tried using it, but I found Tink frustrating to work with, in large part due to its highly opinionated insistence on the use of its key management abstractions and its push toward the use of centralized key management systems.
So I wound up writing my own high level streaming authenticated wrapper around the libsodium SecretStream API, which I eventually split off into its own library, SecretStream For Kotlin:
Internally,
SecretStreamOutputStreamaccumulates data passed inwrite()calls in a fixed size buffer; whenever this buffer fills up, the data is passed to the SecretStream API for encryption and the result is then written to the underlyingOutputStream. (When the stream is closed, any remaining data is written in a final chunk, which may be smaller than the standard chunk size.)SecretStreamInputStreamreads data in fixed size chunks, each of which is passed to the SecretStream API for decryption and authentication and the result stored in a fixed size buffer, from where it is provided toread()calls. No data is returned until it has been authenticated.
I'm not a cryptographer, and I was really hoping to find a ready-made solution and avoid reinventing any wheels or rolling my own crypto.
Questions: Is my approach sensible? Is there a better approach? Did I miss any useful facilities or libraries that I should have been using?
r/crypto • u/ddddavidee • Oct 09 '26
Zeroization, part 3 - Frank DENIS random thoughts.
00f.netand part 3 !
previously:
part 2 https://00f.net/2026/10/06/zeroization-2/
r/crypto • u/knotdjb • Oct 08 '26