Class Wcap_Aes_Ctr
Abandoned Cart Pro for WooCommerce
AES counter (CTR) mode implementation in PHP
-
Wcap_Aes
-
Wcap_Aes_Ctr
Methods summary
public static
text
|
#
encrypt( plaintext $plaintext, password $password, nBits $nBits )
Encrypt a text using AES encryption in Counter mode of operation. Unicode multi-byte character safe
Encrypt a text using AES encryption in Counter mode of operation. Unicode multi-byte character safe
Parameters
- $plaintext
- source text to be encrypted
- $password
- the password to use to generate a key
- $nBits
- number of bits to be used in the key (128, 192, or 256)
Returns
text $ciphertext encrypted text
Since
3.0
|
public static
text
|
#
decrypt( ciphertext $ciphertext, password $password, nBits $nBits )
Decrypt a text encrypted by AES in counter mode of operation
Decrypt a text encrypted by AES in counter mode of operation
Parameters
- $ciphertext
- source text to be decrypted
- $password
- the password to use to generate a key
- $nBits
- number of bits to be used in the key (128, 192, or 256)
Returns
text $plaintext decrypted text
Since
3.0
|
public static
string
|
#
base64url_encode( string $data )
Encoding for base64 encoded strings
Encoding for base64 encoded strings
Parameters
- $data
- base64 encoded string
Returns
string URL Friendly string
|
public static
string
|
#
base64url_decode( string $data )
Encoding for base64 encoded strings
Encoding for base64 encoded strings
Parameters
- $data
- URL Friendly string
Returns
string base64 encoded string
|