It is slow by design to resist brute-force attacks.
BCrypt is a hash function designed to be computationally expensive, which makes it more resistant to brute-force attacks. Over time, as computing power increases, you can increase the 'work factor' to maintain its effectiveness. In Java, you can use the BCryptPasswordEncoder from the Spring Security framework to hash passwords securely.