You are here

function encrypt_install in Encrypt 7

Same name and namespace in other branches
  1. 6 encrypt.install \encrypt_install()
  2. 7.3 encrypt.install \encrypt_install()
  3. 7.2 encrypt.install \encrypt_install()

Implementation of hook_install().

File

./encrypt.install, line 15
This file holds the functions for the installing and enabling of the encrypt module.

Code

function encrypt_install() {

  // Check for mcrypt and make default if found
  if (function_exists('mcrypt_get_iv_size') && function_exists('mcrypt_create_iv') && function_exists('mcrypt_encrypt')) {
    variable_set('encrypt_default_method', 'mcrypt_rij_256');
    drupal_set_message(st('Mcrypt functions found, setting as default encryption method.'));
  }
  else {
    drupal_set_message(st('Mcrypt functions not found, setting basic mathematical method as default encryption method.'));
  }
}