API.txt

  1. cis7 sites/all/modules/ulmus/pathauto/API.txt
  2. cis7 sites/all/modules/ulmus/security_review/API.txt
  3. cis7 sites/all/modules/elmsln_contrib/outline_designer/API.txt
  4. cis7 sites/all/modules/elmsln_contrib/nodereference_highlight/API.txt
  5. cis7 sites/all/modules/ulmus/ctools/API.txt
  6. cis7 sites/all/modules/ulmus/context/API.txt
  7. cis7 sites/all/modules/ulmus/aes/API.txt
  8. cis7 sites/all/modules/ulmus/media/API.txt
  9. cis7 sites/all/modules/ulmus/features/API.txt
  10. cle7 sites/all/modules/ulmus/security_review/API.txt
  11. cle7 sites/all/modules/ulmus/features/API.txt
  12. cle7 sites/all/modules/ulmus/media/API.txt
  13. cle7 sites/all/modules/ulmus/pathauto/API.txt
  14. cle7 sites/all/modules/ulmus/context/API.txt
  15. cle7 sites/all/modules/ulmus/ctools/API.txt
  16. cle7 sites/all/modules/elmsln_contrib/nodereference_highlight/API.txt
  17. cle7 sites/all/modules/elmsln_contrib/outline_designer/API.txt
  18. cle7 sites/all/modules/ulmus/aes/API.txt
  19. cle7 sites/all/modules/local_contrib/votingapi/API.txt
  20. ecd7 sites/all/modules/ulmus/aes/API.txt
  21. ecd7 sites/all/modules/ulmus/ctools/API.txt
  22. ecd7 sites/all/modules/ulmus/security_review/API.txt
  23. ecd7 sites/all/modules/ulmus/context/API.txt
  24. ecd7 sites/all/modules/elmsln_contrib/nodereference_highlight/API.txt
  25. ecd7 sites/all/modules/ulmus/media/API.txt
  26. ecd7 sites/all/modules/ulmus/features/API.txt
  27. ecd7 sites/all/modules/elmsln_contrib/outline_designer/API.txt
  28. ecd7 sites/all/modules/ulmus/pathauto/API.txt
  29. elmsmedia7 sites/all/modules/ulmus/security_review/API.txt
  30. elmsmedia7 sites/all/modules/ulmus/aes/API.txt
  31. elmsmedia7 sites/all/modules/ulmus/features/API.txt
  32. elmsmedia7 sites/all/modules/ulmus/ctools/API.txt
  33. elmsmedia7 sites/all/modules/elmsln_contrib/outline_designer/API.txt
  34. elmsmedia7 sites/all/modules/ulmus/media/API.txt
  35. elmsmedia7 sites/all/modules/elmsln_contrib/nodereference_highlight/API.txt
  36. elmsmedia7 sites/all/modules/ulmus/pathauto/API.txt
  37. elmsmedia7 sites/all/modules/ulmus/context/API.txt
  38. harmony7 sites/all/modules/elmsln_contrib/nodereference_highlight/API.txt
  39. harmony7 sites/all/modules/ulmus/features/API.txt
  40. harmony7 sites/all/modules/ulmus/context/API.txt
  41. harmony7 sites/all/modules/ulmus/media/API.txt
  42. harmony7 sites/all/modules/ulmus/pathauto/API.txt
  43. harmony7 sites/all/modules/ulmus/ctools/API.txt
  44. harmony7 sites/all/modules/ulmus/aes/API.txt
  45. harmony7 sites/all/modules/ulmus/security_review/API.txt
  46. harmony7 sites/all/modules/elmsln_contrib/outline_designer/API.txt
  47. icor7 sites/all/modules/ulmus/security_review/API.txt
  48. icor7 sites/all/modules/ulmus/context/API.txt
  49. icor7 sites/all/modules/ulmus/pathauto/API.txt
  50. icor7 sites/all/modules/elmsln_contrib/outline_designer/API.txt
  51. icor7 sites/all/modules/elmsln_contrib/nodereference_highlight/API.txt
  52. icor7 sites/all/modules/ulmus/ctools/API.txt
  53. icor7 sites/all/modules/ulmus/features/API.txt
  54. icor7 sites/all/modules/ulmus/media/API.txt
  55. icor7 sites/all/modules/ulmus/aes/API.txt
  56. meedjum_blog7 sites/all/modules/elmsln_contrib/outline_designer/API.txt
  57. meedjum_blog7 sites/all/modules/elmsln_contrib/nodereference_highlight/API.txt
  58. meedjum_blog7 sites/all/modules/ulmus/aes/API.txt
  59. meedjum_blog7 sites/all/modules/ulmus/security_review/API.txt
  60. meedjum_blog7 sites/all/modules/ulmus/ctools/API.txt
  61. meedjum_blog7 sites/all/modules/ulmus/context/API.txt
  62. meedjum_blog7 sites/all/modules/ulmus/pathauto/API.txt
  63. meedjum_blog7 sites/all/modules/ulmus/media/API.txt
  64. meedjum_blog7 sites/all/modules/ulmus/features/API.txt
  65. mooc7 sites/all/modules/ulmus/aes/API.txt
  66. mooc7 sites/all/modules/ulmus/ctools/API.txt
  67. mooc7 sites/all/modules/elmsln_contrib/outline_designer/API.txt
  68. mooc7 sites/all/modules/ulmus/security_review/API.txt
  69. mooc7 sites/all/modules/ulmus/context/API.txt
  70. mooc7 sites/all/modules/ulmus/pathauto/API.txt
  71. mooc7 sites/all/modules/ulmus/media/API.txt
  72. mooc7 sites/all/modules/ulmus/features/API.txt
  73. mooc7 sites/all/modules/elmsln_contrib/nodereference_highlight/API.txt
Here's a brief and simple run-through of the functions which might be interesting from a developers point of view. Most (see exceptions below) of the functions are implementation independant, so behaviour should be consistent regardless of which implementation (mcrypt or phpseclib) is used.

Implementation independence exceptions:

1. aes_make_iv is mute when using phpseclib since that implementation handle its own IV internally.

2. The $custom_cipher and $custom_iv arguments to aes_encrypt and aes_decrypt are ignored when using phpseclib, since that implementation doesn't support changing these values. Passing these arguments as anything else than null will generate warnings in the watchdog when using phpseclib.

---------------------------------------------------------------------------------
Function:
string|false aes_encrypt($string, $base64encode = true, $custom_key = null, $custom_cipher = null, $custom_iv = null, $custom_implementation = null)

Description:
Encrypts a string.

Arguments:
string $string The string to encrypt.
(optional) bool $base64encode Whether to return the string base64 encoded (recommended for database insertion).
(optional) string $custom_key Use this as the key rather than the stored one for this operation.
(optional) string $custom_cipher Use this cipher rather than the default one. (only with Mcrypt - ignored with phpseclib)
(optional) string $custom_iv Use this initialization vector instead of the default one.
(optional) string $custom_implementation Can be "phpseclib" or "mcrypt". Warning: Does not check if the requested implementation actually exists.

Returns:
The encrypted string on success, false on error.

---------------------------------------------------------------------------------
Function:
string|false aes_decrypt($string, $base64encoded = true, $custom_key = null, $custom_cipher = null, $custom_iv = null, $custom_implementation = null)

Description:
Decrypts a string of encrypted data.

Arguments:
string $string The string to decrypt.
(optional) bool $base64encode Whether this encrypted string is base64 encoded or not.
(optional) string $custom_key Use this as the key rather than the stored one for this operation.
(optional) string $custom_cipher Use this cipher rather than the default one. (only with Mcrypt - ignored with phpseclib)
(optional) string $custom_iv Use this initialization vector instead of the default one.
(optional) string $custom_implementation Can be "phpseclib" or "mcrypt". Warning: Does not check if the requested implementation actually exists.

Returns:
The decrypted string on success, false on error.

---------------------------------------------------------------------------------
Function:
bool aes_password_exists($uid)

Description:
Checks if a users password exists.

Arguments:
int $uid The user ID.

Returns:
True or false.

---------------------------------------------------------------------------------
Function:
string|false aes_get_password($uid, $decrypt = false)

Description:
Gets a users password, in plain text, or in it's encrypted form.

Arguments:
int $uid The user ID.
(optional) bool $decrypt Whether to decrypt the password before returning it, or not. Defaults to false.

Returns:
The password on success, false on failure.

---------------------------------------------------------------------------------
Function:
string aes_get_key()

Description:
Gets the current key used for the encryption system. If there's currently no key defined, this function will generate one, store it, and return it.

Arguments:
none

Returns:
The key.

---------------------------------------------------------------------------------
Function:
bool aes_store_key($key)

Description:
Stores the key given by writing it to the storage method currently used (database or file).

Arguments:
string $key The key.

Returns:
True on success, false on failure.

---------------------------------------------------------------------------------
Function:
void aes_delete_key($storage_method)

Description:
Deletes the encryption system key.

Arguments:
string $storage_method The storage method used to store the key. "Database" or "File".

Returns:
nothing

---------------------------------------------------------------------------------
Function:
string aes_make_key()

Description:
Generates a new key.

Arguments:
none

Returns:
The newly generated key.

---------------------------------------------------------------------------------
Function:
void aes_make_iv($ignore_implementation = false)

Description:
Generates a new initialization vector and stores it (overwrites old IV!). NOTE: Only use this with the Mcrypt implementation, phpseclib has its own IV management.

Arguments:
(optional) bool $ignore_implementation Forces aes_make_iv to create and store a new IV even if the phpseclib implementation is used.

Returns:
nothing

File

sites/all/modules/ulmus/aes/API.txt
View source
  1. Here's a brief and simple run-through of the functions which might be interesting from a developers point of view. Most (see exceptions below) of the functions are implementation independant, so behaviour should be consistent regardless of which implementation (mcrypt or phpseclib) is used.
  2. Implementation independence exceptions:
  3. 1. aes_make_iv is mute when using phpseclib since that implementation handle its own IV internally.
  4. 2. The $custom_cipher and $custom_iv arguments to aes_encrypt and aes_decrypt are ignored when using phpseclib, since that implementation doesn't support changing these values. Passing these arguments as anything else than null will generate warnings in the watchdog when using phpseclib.
  5. ---------------------------------------------------------------------------------
  6. Function:
  7. string|false aes_encrypt($string, $base64encode = true, $custom_key = null, $custom_cipher = null, $custom_iv = null, $custom_implementation = null)
  8. Description:
  9. Encrypts a string.
  10. Arguments:
  11. string $string The string to encrypt.
  12. (optional) bool $base64encode Whether to return the string base64 encoded (recommended for database insertion).
  13. (optional) string $custom_key Use this as the key rather than the stored one for this operation.
  14. (optional) string $custom_cipher Use this cipher rather than the default one. (only with Mcrypt - ignored with phpseclib)
  15. (optional) string $custom_iv Use this initialization vector instead of the default one.
  16. (optional) string $custom_implementation Can be "phpseclib" or "mcrypt". Warning: Does not check if the requested implementation actually exists.
  17. Returns:
  18. The encrypted string on success, false on error.
  19. ---------------------------------------------------------------------------------
  20. Function:
  21. string|false aes_decrypt($string, $base64encoded = true, $custom_key = null, $custom_cipher = null, $custom_iv = null, $custom_implementation = null)
  22. Description:
  23. Decrypts a string of encrypted data.
  24. Arguments:
  25. string $string The string to decrypt.
  26. (optional) bool $base64encode Whether this encrypted string is base64 encoded or not.
  27. (optional) string $custom_key Use this as the key rather than the stored one for this operation.
  28. (optional) string $custom_cipher Use this cipher rather than the default one. (only with Mcrypt - ignored with phpseclib)
  29. (optional) string $custom_iv Use this initialization vector instead of the default one.
  30. (optional) string $custom_implementation Can be "phpseclib" or "mcrypt". Warning: Does not check if the requested implementation actually exists.
  31. Returns:
  32. The decrypted string on success, false on error.
  33. ---------------------------------------------------------------------------------
  34. Function:
  35. bool aes_password_exists($uid)
  36. Description:
  37. Checks if a users password exists.
  38. Arguments:
  39. int $uid The user ID.
  40. Returns:
  41. True or false.
  42. ---------------------------------------------------------------------------------
  43. Function:
  44. string|false aes_get_password($uid, $decrypt = false)
  45. Description:
  46. Gets a users password, in plain text, or in it's encrypted form.
  47. Arguments:
  48. int $uid The user ID.
  49. (optional) bool $decrypt Whether to decrypt the password before returning it, or not. Defaults to false.
  50. Returns:
  51. The password on success, false on failure.
  52. ---------------------------------------------------------------------------------
  53. Function:
  54. string aes_get_key()
  55. Description:
  56. Gets the current key used for the encryption system. If there's currently no key defined, this function will generate one, store it, and return it.
  57. Arguments:
  58. none
  59. Returns:
  60. The key.
  61. ---------------------------------------------------------------------------------
  62. Function:
  63. bool aes_store_key($key)
  64. Description:
  65. Stores the key given by writing it to the storage method currently used (database or file).
  66. Arguments:
  67. string $key The key.
  68. Returns:
  69. True on success, false on failure.
  70. ---------------------------------------------------------------------------------
  71. Function:
  72. void aes_delete_key($storage_method)
  73. Description:
  74. Deletes the encryption system key.
  75. Arguments:
  76. string $storage_method The storage method used to store the key. "Database" or "File".
  77. Returns:
  78. nothing
  79. ---------------------------------------------------------------------------------
  80. Function:
  81. string aes_make_key()
  82. Description:
  83. Generates a new key.
  84. Arguments:
  85. none
  86. Returns:
  87. The newly generated key.
  88. ---------------------------------------------------------------------------------
  89. Function:
  90. void aes_make_iv($ignore_implementation = false)
  91. Description:
  92. Generates a new initialization vector and stores it (overwrites old IV!). NOTE: Only use this with the Mcrypt implementation, phpseclib has its own IV management.
  93. Arguments:
  94. (optional) bool $ignore_implementation Forces aes_make_iv to create and store a new IV even if the phpseclib implementation is used.
  95. Returns:
  96. nothing
Error | ELMSLN API

Error

×

Error message

  • Warning: Cannot modify header information - headers already sent by (output started at /var/www/html/elmsln_community/api.elmsln.org/includes/common.inc:2791) in drupal_send_headers() (line 1499 of /var/www/html/elmsln_community/api.elmsln.org/includes/bootstrap.inc).
  • Error: Call to undefined function apc_delete() in DrupalAPCCache->clear() (line 289 of /var/www/html/elmsln_community/api.elmsln.org/sites/all/modules/apc/drupal_apc_cache.inc).
The website encountered an unexpected error. Please try again later.