Security
Digitally Signing PDF Documents
12
Security Policies
Security policies are common specifications that include the type of encryption, the
permission settings, and the password or public key to be used. You may create folder-level
scripts containing objects that reflect these policies. Security policies may be customized
through the use of
securityPolicy
objects, which may be accessed and managed by
the
security
object’s
getSecurityPolicies
and
chooseSecurityPolicy
methods, as well as the
doc
object’s
encryptUsingPolicy
and
encryptforAPS
methods.
Secure Forms
You can lock form fields by creating a script containing a call to the
signature
field’s
setLock
method, and passing that script as the second parameter to the
signature
field’s
setAction
method.
In addition, you may sign an embedded FDF data object by invoking its
signatureSign
method, and subsequently validate the signature by invoking its
signatureValidate
method.
Digitally Signing PDF Documents
A digital signature contains identifying information about the person signing the
document. When applying an author signature (the first time a signature is applied to a
document), it is also possible to certify the document. This involves providing a legal attest
with regard to the document’s contents and specifying the types of changes allowed for
the document in order for it to remain certified.
Signing a PDF Document
To sign a document, create a signature field, choose a security handler, and invoke the
field’s
signatureSign
method, which accepts the following parameters:
●
●
●
●
●
oSig
: the security handler object
oInfo
: a
signatureInfo
object
cDIPath
: the device-independent path to which the file will subsequently be saved
bUI
: whether the security handler will display a user interface when signing
cLegalAttest
: a string explaining legal warnings (for author signatures only)
The creation and usage of these parameters are explained below in the following sections:
and
Applying the Signature.
Acrobat JavaScript Scripting Guide
205