The problem mostly can come from your tooling.
I mean lots of people use and used MessageDigest.isEqual in Java however that class had a huge issue in Java 6 until Java 6 - 17 which could attackers use time attacks against your authentication scheme.<p>Also it&#x27;s not really easy to prevent against such security things with small teams if you can&#x27;t rely on the tooling inside your language. Building Crypto things is really hard. So People needing to rely on.
Today I&#x27;ve rewritten a authentication &#x2F; authorization layer for one of our internal Apps, now the App is hardended against csrf, timing attacks and many more things.
The only things that I used was the internal PBKDF2HmacSha256 for Passwords of Java Sha256Pnrg for Salts
and I copied behaviors of the Auth0 JWT Library (i just used  another json implementation which the app already had) and i have something like 200 Lines of Code. It&#x27;s secure as long as MessageDigest and the PBKDF2 Code of Java is secure and that&#x27;s something people can&#x27;t avoid. Especially in small teams.