Login

Tag "drupal7"

Snippet List

A more complete Drupal 7 compatible password hasher

Use this class to authenticate against Drupal 7 password strings. When importing passwords from Drupal, the database values should be prefixed with "drupal$". In contrast to the two present solutions, this class also works with passwords which were imported to Drupal 7 (e.g. from Drupal 6 or phpBB) and with passwords with variable iteration numbers. It is possible to use this class for encoding passwords, but due to questionable design decisions in Drupal (like truncating the non-standard base64 encoded hash at 43 characters) I'd recommend to do this this only if you really need to be able to migrate back to Drupal.

  • drupal
  • drupal7
Read More

drupal7 password check

Completely based on [snippet 2729](http://djangosnippets.org/snippets/2729/) (see that snippet for useful comments!). The above snippet did not work for me (something with MemoryError), so I looked at the Drula source code and reimplemented...

  • password
  • hash
  • drupal7
Read More

2 snippets posted so far.