Programming: Mostly A Hate Story
I wanted to do digital signatures validation, preferably ed25519, inside PostgreSQL triggers. Here is how it went:
pgcrypto must be supporting it, right? Most Postgres cloud hosting providers already support pgcrypto so this would be perfect. Right?
Well, pgcrypto only supports PGP and that too excludes digital signatures. Let's give PGP a try anyway and see how far can we go.
gpg to generate the keys and the experience is less than pleasant. Sometimes it gets stuck at the passphrase prompt. The keys are too big, but still I can make pgcrypto's
pgp_pub_decrypt methods work. Just remeber to convert keys in ASCII to binary and vice-versa using
dearmor(). I hate the big key size in RSA, even though GPG defaults to 2048-bit keys and not the more secure 4096-bit ones. Let's look into ed25519 now.