Programming: Mostly a hate story
gist.github.com
gist.github.com
But the bug will still be there, waiting for an actual attack.
Of course there's no problem if you do it right. It's just that guaranteeing you did it right is never possible with 100% certainty if you wrote the code, evaluated the code, and published the code.
More eyes means less mistakes. More hands makes less work. If you roll your own templating system, and you mess up, then some text on a page is displayed wrong. If you roll your own crypto to protect customer data and you mess up, whoops, that customer data is out there.
That said, I think there's still a major difference between roll-your-own-crypto and other "unless you do it right" topics. Securely storing passwords and preventing XSS are things that can look ok and be insecure unless you do it right, but I'm not (always) against people (carefully) handling those things themselves. Rolling your own signatures or encryption are infamous because a "best practices" list and good code review won't save you; even if you root out all the actual bugs, your process can still be cripplingly vulnerable. As Schneier said, anyone can create an alogorithm they can't compromise.
This system is minimal, is running almost perfectly and has > 100 happy users. There isn't sufficient justification to introduce custom code layer and break all the existing functionality.
pgcrypto already does support PGP encryption after all, just not ECDSA.
Isn't this the #1 anti-pattern in cryptography?
> I wanted digital signatures validation, preferably ed25519, inside PostgreSQL.
There should be some front-end server in front of PostgreSQL that can handle verification.
Why does the database need to be encrypted? Is the database entries encrypted with different keys based on the user? Why does the encryption need to happen in the database?
Because software is so easy to distribute, sometimes just waiting for a period of time will cause problems to go away. Why spend time to fix the issue when it might be fixed next month by someone else? This is kinda like deflation for the economy of money (why spend when your money may be worth more next month?).
On the other hand, the problem may need to be fixed right now, so it's a tradeoff between estimating (often guessing, if you don't have insight into upstream roadmaps) if someone upstream will fix the underlying issue and estimating (guessing, really) the effort to fix it locally.
I spent this time to find out exactly what all things are broken. It's just a rant for wasting a few hours of effort. In the end, we ended up de-prioritizing this feature request. :-)
While it is still quite risky to have your own implementation if the platform doesn't have one there must be a person that does it for the first time. Provided you do it correctly according to the paper and you don't have bugs and you do it in constant time and you know about a bunch of other stuff it might be ok.
On the other hand creating new cryptos and protocols is best left to guys with long beards and titles.
Edit for context: this was published right after Heartbleed went public.
Yes, but to create the image, you don't need to build it. Meet your new friend "docker commit".
It gets worse. But you eventually learn that it is just software and to not let it get to you.
That aside, man! this is relatable!