Inherited Variables
Inherited Constants
Inherited Methods
Class Details
A class to encrypt a PDF file and add security permissions to a PDF file.
This class can be used stand alone or as a helper class to encrypt and digitally sign PDF files that have been created using HTML_ToPDF. See the README and examples for more information.
Tags:
- copyright - The PHP License
- version - 3.3
- author - Jason Rust <jrust@rustyparts.com>
[ Top ]
Class Variables
$allowAssembly = false
[line 106]
Should we allow assembly?
Type: bool
Overrides:
[ Top ]
$allowCopy = false
[line 88]
Should we allow the copy command?
Type: bool
Overrides:
[ Top ]
$allowDegradedPrinting = false
[line 118]
Should we allow degraded printing?
Type: bool
Overrides:
[ Top ]
$allowFillIn = false
[line 112]
Should we allow fill in?
Type: bool
Overrides:
[ Top ]
$allowModifyAnnotations = false
[line 94]
Should we allow modify annotations?
Type: bool
Overrides:
[ Top ]
$allowModifyContents = false
[line 82]
Should we allow the contents to be modified?
Type: bool
Overrides:
[ Top ]
$allowPrinting = false
[line 76]
Should we allow printing?
Type: bool
Overrides:
[ Top ]
$allowScreenReaders = false
[line 100]
Should we allow screen readers?
Type: bool
Overrides:
[ Top ]
$author =
[line 154]
The author (meta-data)
Type: string
Overrides:
[ Top ]
$creator = 'PDFEncryptor'
[line 160]
The creator (meta-data)
Type: string
Overrides:
[ Top ]
$encryptionStrength = 128
[line 124]
The encryption strength (128 or 40)
Type: int
Overrides:
[ Top ]
$encryptPdfPath =
[line 70]
The path to the encrypt_pdf java class
Type: string
Overrides:
[ Top ]
$iTextPath =
[line 64]
The path to the iText jar file
Type: string
Overrides:
[ Top ]
$javaPath = '/usr/bin/java'
[line 58]
The path to the java binary
Type: string
Overrides:
[ Top ]
$keywords =
[line 166]
The keywords (meta-data)
Type: string
Overrides:
[ Top ]
$ownerPassword = ''
[line 136]
The owner password
Type: string
Overrides:
[ Top ]
$pdfFile = ''
[line 46]
The full path to the PDF we are encrypting
Type: string
Overrides:
[ Top ]
$subject =
[line 142]
The subject (meta-data)
Type: string
Overrides:
[ Top ]
$title =
[line 148]
The title (meta-data)
Type: string
Overrides:
[ Top ]
$tmpDir = '/tmp'
[line 52]
The temporary directory to save intermediate files
Type: string
Overrides:
[ Top ]
$userPassword = ''
[line 130]
The user password
Type: string
Overrides:
[ Top ]
Class Methods
PDFEncryptor
void PDFEncryptor(
string
$in_pdfFile)
[line 179]
Initializes the class
Tags:
- access - public
Parameters:
- string $in_pdfFile - (optional) The full path to the pdf file to encrypt.
[ Top ]
encrypt
mixed encrypt(
)
[line 535]
Encrypt the PDF file, add meta-data, and set permissions
Tags:
- return - True on success, pear error on problem
- access - public
Parameters:
[ Top ]
setAllowAssembly
void setAllowAssembly(
bool
$in_value)
[line 341]
Set should we allow assembly?
Tags:
- access - public
Parameters:
- bool $in_value - The value
[ Top ]
setAllowCopy
void setAllowCopy(
bool
$in_value)
[line 293]
Set should we allow the copy command?
Tags:
- access - public
Parameters:
- bool $in_value - The value
[ Top ]
setAllowDegradedPrinting
void setAllowDegradedPrinting(
bool
$in_value)
[line 373]
Set should we allow degraded printing?
Tags:
- access - public
Parameters:
- bool $in_value - The value
[ Top ]
setAllowFillIn
void setAllowFillIn(
bool
$in_value)
[line 357]
Set should we fill in?
Tags:
- access - public
Parameters:
- bool $in_value - The value
[ Top ]
setAllowModifyAnnotations
void setAllowModifyAnnotations(
bool
$in_value)
[line 309]
Set should we allow modify annotations?
Tags:
- access - public
Parameters:
- bool $in_value - The value
[ Top ]
setAllowModifyContents
void setAllowModifyContents(
bool
$in_value)
[line 277]
Set should we allow the contents to be modified?
Tags:
- access - public
Parameters:
- bool $in_value - The value
[ Top ]
setAllowPrinting
void setAllowPrinting(
bool
$in_value)
[line 261]
Set should we allow printing?
Tags:
- access - public
Parameters:
- bool $in_value - The value
[ Top ]
setAllowScreenReaders
void setAllowScreenReaders(
bool
$in_value)
[line 325]
Set should we allow screen readers?
Tags:
- access - public
Parameters:
- bool $in_value - The value
[ Top ]
setAuthor
void setAuthor(
string
$in_value)
[line 474]
Set the author (meta-data)
Tags:
- access - public
Parameters:
- string $in_value - The value
[ Top ]
setCreator
void setCreator(
string
$in_value)
[line 490]
Set the creator (meta-data)
Tags:
- access - public
Parameters:
- string $in_value - The value
[ Top ]
setEncryptionStrength
void setEncryptionStrength(
int
$in_value)
[line 389]
Set the encryption strength (128 or 40)
Tags:
- access - public
Parameters:
- int $in_value - The value
[ Top ]
setEncryptPdfPath
void setEncryptPdfPath(
string
$in_value)
[line 245]
Set the path to the encrypt_pdf java class
Tags:
- access - public
Parameters:
- string $in_value - The value
[ Top ]
setITextPath
void setITextPath(
string
$in_value)
[line 229]
Set the path to the iText jar file
Tags:
- access - public
Parameters:
- string $in_value - The value
[ Top ]
setJavaPath
void setJavaPath(
string
$in_value)
[line 213]
Set the path to the java binary
Tags:
- access - public
Parameters:
- string $in_value - The value
[ Top ]
setKeywords
void setKeywords(
string
$in_value)
[line 506]
Set the keywords (meta-data)
Tags:
- access - public
Parameters:
- string $in_value - The value
[ Top ]
setOwnerPassword
void setOwnerPassword(
string
$in_value)
[line 426]
Set the owner password
Tags:
- access - public
Parameters:
- string $in_value - The value
[ Top ]
setPdfFile
void setPdfFile(
string
$in_value)
[line 197]
Set the full path to the PDF we are encrypting
Tags:
- access - public
Parameters:
- string $in_value - The value
[ Top ]
setSubject
void setSubject(
string
$in_value)
[line 442]
Set the subject (meta-data)
Tags:
- access - public
Parameters:
- string $in_value - The value
[ Top ]
setTitle
void setTitle(
string
$in_value)
[line 458]
Set the title (meta-data)
Tags:
- access - public
Parameters:
- string $in_value - The value
[ Top ]
setTmpDir
void setTmpDir(
string
$in_path)
[line 522]
Set the temporary directory path
Tags:
- access - public
Parameters:
- string $in_path - The full path to the tmp dir
[ Top ]
setUserPassword
void setUserPassword(
string
$in_value)
[line 410]
Set the user password
Tags:
- access - public
Parameters:
- string $in_value - The value
[ Top ]
_getProperty
string _getProperty(
string
$in_key, string
$in_value)
[line 617]
Gets a property if it has been set
Tags:
- return - The key value pair
- access - public
Parameters:
- string $in_key - The key property
- string $in_value - The value of the key
[ Top ]