Tags · Functions · Objects
Lucee Function Reference
Choose a function:


Implementation of Password-Based Key-Derivation Function (PBKDF).


generatepbkdfkey(string algorithm,string passphrase,string salt,[numeric iterations,[numeric keySize]]):string


The arguments for this function are set. You can not use other arguments except the following ones.
Name Type Required Default Value Description
algorithm string  Yes   Hashing algorithm used for generating key
Example Values:
  • PBKDF2WithHmacSHA1
  • PBKDF2WithSHA1
  • PBKDF2WithSHA224
  • PBKDF2WithSHA256
  • PBKDF2WithSHA384
  • PBKDF2WithSHA512  
  • passphrase string  Yes   Passphrase used for the key. KEEP THIS SECRET.  
    salt string  Yes   A random salt.  
    iterations numeric  No 4096 The number of PBKDEF iterations to perform. A minimum recommended value is 1000.  
    keySize numeric  No 128 The length in bytes of the key to generate.