crypto
Module providing cryptography algorithms.This module is still in development.
methods
- listEncrypters()
lists all encoder names usable with String.encrypt(...).
return value:
An array of encrypter names. - listDecrypters()
lists all encoder names usable with String.decrypt(...).
return value:
An array of decrypter names.
exended classes
String
crypto extend the String class to provide string encryption/decryption.instance methods
- encrypt(crydec, key)
Encrypts a string using the specified encrypter/decrypter with the key. - decrypt(crydec, key)
Decrypts a string using the specified encrypter/decrypter with the key.
Encrypters/Decrypters
The following encrypters/decrypters are available:- rc4
For ARC4 encryption/decryption - xor
For a simple XOR encryption/decryption
where CrydecName is the name of your encrypter/decrypter.
calling "someString".encrypt(yourCrydecName) will call that crydec method and pass all additional parameters passed to encrypt/decrypt to that method.