Is there a way to add another JDBCAuthProvider.PasswordType of encrypt()?

I’am trying to use the table of my mail-server database for user authentication . There’s only one problem now. Cause the password encryption method in the tables is the"encrypt()" function of mysql. But what openfire support is plain,md5 and sha1 , so is there a way to add another JDBCAuthProvider.PasswordType of encrypt().

Hi aries,

I don’t think that’s possible. There may be a way however if you don’t mind hacking the source for JDBCAuthProvider.java. The ‘plain’ type can maintain, but you need to do SELECT PASSWORD(‘userPassword’) first, the resulting value of which you pass as userPassword somewhere in:

if (!password.equals(userPassword)) {
            throw new UnauthorizedException();
        }