3 ms·
One thought is that it puts the computational load of verifying user-provided passwords in your database tier, rather than in your application tier, where it ex
by bhauer 11y ago
One thought is that it puts the computational load of verifying user-provided passwords in your database tier, rather than in your application tier, where it exists today. Let's say that right now, you have a 200ms computation necessary to verify a bcrypt-secured password. If you have that in your application tier, you can easily scale that horizontally with more CPUs if necessary. It may be a bit more difficult to scale CPU capacity in the database tier.
However, another approach would be extension of the database's client-server protocol and driver(s) such that the hash verification occurs within the application tier (as part of the driver). Or, moving further along that path, the field could be annotated in your ORM, exposing special set and verify methods. But at that point, you're very close to the current condition, where the hashing occurs within your web application framework.
Or hashing could be done on the client side.
- nly 11y ago> Or hashing could be done on the client side. Only if you use a proper PAKE. A vanilla password hash is still a bearer token on the wire.