RCFour
in package
Com\Tecnick\Pdf\Encrypt\Type\RCFour
RC4 is the standard encryption algorithm used in PDF format
Tags
Table of Contents
Constants
- VALID_CIPHERS = ['RC4', 'RC4-40']
- List of valid openssl cyphers for RC4 encryption.
Methods
- encrypt() : string
- Encrypt the data using the RC4 (Rivest Cipher 4, also known as ARC4 or ARCFOUR) algorithm.
Constants
VALID_CIPHERS
List of valid openssl cyphers for RC4 encryption.
public array<string|int,
string> VALID_CIPHERS = ['RC4',
'RC4-40']
Methods
encrypt()
Encrypt the data using the RC4 (Rivest Cipher 4, also known as ARC4 or ARCFOUR) algorithm.
public encrypt(string $data,
string $key[,
string $mode
= ''
]) : string
RC4 is one of the standard encryption algorithm used in PDF format. If possible, please use AES encryption instead as this is insecure.
Parameters
- $data : string
-
Data string to encrypt
- $key : string
-
Encryption key
- $mode : string = ''
-
Cipher
Return values
string —encrypted text