[html-formfu] Password hash gives different results each time

Carl Franks fireartist at gmail.com
Fri May 1 07:18:33 GMT 2009


2009/4/30 Ascii King <tech at swattermatter.com>:
> I have a password field that I am trying to encrypt using some code provided
> by David Schmidt. It seems to work, except that it returns a different value
> each time, even if the passwords are the same.

> sub hashit {
>   my ( $self, $value, $params ) = @_;
>   return sha1_hex($value);
> }

The Callback doesn't receive a $self object:

    my ( $value, $params ) = @_;

"if in doubt, dump it out" :)

    warn Dumper( @_ );

Cheers,
Carl



More information about the HTML-FormFu mailing list