I'm trying smartfoxbits and I've implemented a custom login with the extension. I just have a little problem with the password because we have MD5 hashed password in our database. So the problem is that I have to hash the password the user inputs before it's sent to the extension because then the password it is crypted and, on the extension side, I can't have it back in plain format to md5 it before check it against the db.
I quite resolved this intercepting the MouseEvent.MOUSE_DOWN of the loginButton in this way
Code: Select all
private function onLoginButtonMouseDown(evt:MouseEvent):void {
evt.preventDefault();
_sfs.send(new LoginRequest(_loginBox.usernameTextInput.text, MD5.hash(_loginBox.passwordTextInput.text)));
}
but the problem remains when user press Enter on the keyboard...
Do you have any suggestion?
There is a way to prevent this problem?
Thank you