OpenSSL
Implements CipherInterfaceJoomla cipher for encryption, decryption and key generation via the openssl extension.
since |
2.0.0 |
---|---|
package |
Joomla Framework |
Methods
__construct
Instantiate the cipher.
__construct(string iv, string method) : mixed
since |
2.0.0 |
---|
Arguments
- iv
string
The initialisation vector to use- method
string
The encryption method to use
Response
mixed
decrypt
Method to decrypt a data string.
decrypt(string data, \Joomla\Crypt\Key key) : string
since |
2.0.0 |
---|---|
throws |
|
Arguments
- data
string
The encrypted string to decrypt.- key
\Joomla\Crypt\Key
The key object to use for decryption.
Response
string
The decrypted data string.
encrypt
Method to encrypt a data string.
encrypt(string data, \Joomla\Crypt\Key key) : string
since |
2.0.0 |
---|---|
throws |
|
Arguments
- data
string
The data string to encrypt.- key
\Joomla\Crypt\Key
The key object to use for encryption.
Response
string
The encrypted data string.
generateKey
Method to generate a new encryption key object.
generateKey(array options = []) : \Joomla\Crypt\Key
since |
2.0.0 |
---|---|
throws |
|
Arguments
- options
array
Key generation options.
Response
\Joomla\Crypt\Key
isSupported
Check if the cipher is supported in this environment.
isSupported() : bool
since |
2.0.0 |
---|
Response
bool
Properties
iv
Initialisation vector for key generator method.
since |
2.0.0 |
---|
Type(s)
string
method
Method to use for encryption.
since |
2.0.0 |
---|
Type(s)
string