Other [B4A] Invalid salt revision error using BCrypt

Status
Not open for further replies.

snich

Member
I'm having an issue checking BCrypt hashed passwords using this library: BCrypt - Create salted Hashes (compatible with PHP).
This error occurs when I'm checking the password.
B4X:
(Exception) java.lang.Exception:  java.lang.IllegalArgumentException: Invalid salt revision

I created an online store (web/PHP) for a school project, now I'm assigned to make an app for it using B4A and I'm stuck with this problem.
The password is 'closa' and here is the hash:
B4X:
$2y$10$H1rGh3KLC3bhjpIGUYbkveZ2XmkNVjTqx2Mx6QPpOgbBwqSqde8Oa

The password was created using PHP's password_hash using PASSWORD_DEFAULT which is BCRYPT according to this link:
https://www.php.net/manual/en/function.password-hash.php

My PHP version is 7.4.26.


I'm sorry if I made a mistake creating this thread, I'm very new here.
 
Status
Not open for further replies.
Top