diff options
author | Dries Buytaert <dries@buytaert.net> | 2010-05-01 08:12:23 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2010-05-01 08:12:23 +0000 |
commit | 71713081a2b79b0baa024742cdbb4af536f77f4b (patch) | |
tree | e9bc0d309856beb05a6fae67fdbdd75c59ccef9f /modules/book | |
parent | 2a2f4cc0be547f515ccd4212e9aeca7765a4968b (diff) | |
download | brdo-71713081a2b79b0baa024742cdbb4af536f77f4b.tar.gz brdo-71713081a2b79b0baa024742cdbb4af536f77f4b.tar.bz2 |
- Patch #723802 by pwolanin, grendzy: convert to sha-256 and hmac from md5 and sha1.
Diffstat (limited to 'modules/book')
-rw-r--r-- | modules/book/book.admin.inc | 2 | ||||
-rw-r--r-- | modules/book/book.module | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/modules/book/book.admin.inc b/modules/book/book.admin.inc index 02a45b24c..8d67dc323 100644 --- a/modules/book/book.admin.inc +++ b/modules/book/book.admin.inc @@ -154,7 +154,7 @@ function _book_admin_table($node, &$form) { $tree = book_menu_subtree_data($node->book); $tree = array_shift($tree); // Do not include the book item itself. if ($tree['below']) { - $hash = sha1(serialize($tree['below'])); + $hash = drupal_hash_base64(serialize($tree['below'])); // Store the hash value as a hidden form element so that we can detect // if another user changed the book hierarchy. $form['tree_hash'] = array( diff --git a/modules/book/book.module b/modules/book/book.module index ab09be7c7..f7f2219e8 100644 --- a/modules/book/book.module +++ b/modules/book/book.module @@ -1273,7 +1273,7 @@ function book_menu_subtree_data($link) { $data['node_links'] = array(); menu_tree_collect_node_links($data['tree'], $data['node_links']); // Compute the real cid for book subtree data. - $tree_cid = 'links:' . $item['menu_name'] . ':subtree-data:' . md5(serialize($data)); + $tree_cid = 'links:' . $item['menu_name'] . ':subtree-data:' . hash('sha256', serialize($data)); // Cache the data, if it is not already in the cache. if (!cache_get($tree_cid, 'cache_menu')) { |