You are here

function encrypt_get_encryption_method in Encrypt 7.3

Same name and namespace in other branches
  1. 7.2 encrypt.module \encrypt_get_encryption_method()

Fetch metadata on a specific encryption method plugin.

Parameters

mixed $method: Name of an encryption method. If no $method is specified, this function will return info about the default encryption method.

Return value

array An array with information about the requested encryption method.

3 calls to encrypt_get_encryption_method()
encrypt_config_form_submit in includes/encrypt.admin.inc
Form submission handler for encrypt_config_form().
encrypt_requirements in ./encrypt.install
Implements hook_requirements().
_encrypt_decrypt in includes/encrypt.encrypt.inc
Private internal function to Encrypt and Decrypt text.

File

./encrypt.module, line 397
Main Encrypt Drupal File

Code

function encrypt_get_encryption_method($method = NULL) {

  // If the method was not specified, use the method
  // from the default configuration.
  if (empty($method)) {
    $config = encrypt_get_default_config();
    $method = $config['method'];
  }
  ctools_include('plugins');
  return ctools_get_plugins('encrypt', 'encryption_methods', $method);
}