Replying to Avatar Alex Gleason

nip04 encrypt: 5,000 iter/s

aes-cbc without a shared secret encrypt: 40,000 iter/s

aes-gcm and nip44 basically the same.

The point is if you're encrypting a message to only yourself, it's 10x faster to not do this diffie-hellman thing and just BYO secret.

Please note that I don't actually understand all these words, I just ran a few benchmarks, and decided to encrypt secrets in my database with aes-gcm and just one key instead of nip44/nip04.

Avatar
Tim Bouma 1y ago

Interesting. I am currently using NIP-44 to encrypted private events. What you are suggesting is that if I have a properly-seeded secret, with aes I can get 10× performance.

Reply to this note

Please Login to reply.

Discussion

No replies yet.