# Patent

## Title
Using digital certificates to facilitate enforcement of product licenses

## Abstract

One embodiment of the present invention provides a system that uses digital certificates to facilitate enforcing licensing terms for applications that manipulate documents. During operation, the system obtains a credential, wherein the credential includes a private key and a digital certificate containing a corresponding public key. This digital certificate also contains a profile specifying allowed operations which can be performed on documents signed with the credential. Next, the system digitally signs a document using the credential, so that the resulting signed document is signed with the private key and includes a copy of the digital certificate with the profile specifying the allowed operations. The certificate issuer can subsequently revoke the digital certificate (which effectively revokes the license) if terms of a license agreement associated with the digital certificate are violated.

## Background
BACKGROUND
1. Field of the Invention
The present invention relates to techniques to facilitate licensing for software products. More specifically, the present invention relates to a method and an apparatus that uses digital certificates to facilitate enforcement of licensing terms for a software product after the software product is delivered.
2. Related Art
A software product is often distributed to customers in a number of possible configurations, which provide differing levels of functionality. The specific configuration which is shipped to a customer is generally determined by the specific requirements of the customer, and the amount that the customer is willing to pay for an associated software license. Different product configurations are typically associated with different stock-keeping units (SKUs), wherein SKUs are unique numeric identifiers which identify specific product configurations.
Conventionally, different product SKUs of a product line are generated by: (1) producing different packagings of the code (for example, by removing code related to unsupported features), or (2) through product license keys, which are commonly entered by a user to enable a program to operate.
Producing different packagings of the code is a cumbersome process, which can greatly complicate the task of distributing software. Furthermore, in either of the above-described approaches, if a customer violates the terms of the licensing agreement, there is no easy way to stop the customer from using the software product.
Hence, what is needed is a method and an apparatus that facilitates distributing different configurations of a software product in a manner that allows the distributor to enforce terms of a licensing agreement for the software product.
SUMMARY
One embodiment of the present invention provides a system that uses digital certificates to facilitate enforcing licensing terms for applications that manipulate documents. During operation, the system (which for example can be located at a server) obtains a credential, wherein the credential includes a private key and a digital certificate containing a corresponding public key. This digital certificate also contains a profile specifying allowed operations which can be performed on documents signed with the credential. Next, the system digitally signs a document using the credential, so that the resulting signed document is signed with the private key and includes a copy of the digital certificate with the profile specifying the allowed operations. The certificate issuer can subsequently revoke the digital certificate (which effectively revokes the license) if terms of a license agreement associated with the digital certificate are violated.
In a variation on this embodiment, another application (which for example can be located at a client) receives the signed document. Upon receiving the signed document, the other application validates the digital signature on the signed document. If the digital signature is valid, the other application examines the profile contained in the digital certificate to determine which operations are allowed on the document, and enables the allowed operations to be performed on the document (and disables other operations). On the other hand, if the digital signature is not valid, the other application is disabled from performing operations on the document.
In a further variation, validating the digital signature involves ensuring that the digital certificate is not expired or revoked.
In a variation on this embodiment, the a credential issuer can revoke the digital certificate if terms of a license associated with the digital certificate are violated, wherein revoking the digital certificate causes operations to be disabled for all documents signed with the digital certificate. This can involve disabling all operations on all documents ever created by the system, disabling documents created after a particular date, or suspending operations for all of the documents temporarily. Furthermore, when the certificate is revoked, the system (at the server) may also stop functioning.
Note that this capability to disable all operations on all documents ever created by the system is a completely new capability, which no existing system can provide. Furthermore, this capability can be used to facilitate enforcement of licensing terms, because the digital certificate can be revoked if terms of a license agreement for the system are violated.
In a variation on this embodiment, prior to signing the document with the credential, the system: configures a user interface (UI) based upon the allowed operations specified in profile; and allows an administrator to select a subset of the allowed operations through the UI. In this variation, digitally signing the document involves incorporating information which identifies the selected subset into the document. In this way, different system configurations (SKUs) associated with different allowed operations can be effectively created without having to create customized code for each different configuration.
In a variation on this embodiment, obtaining the credential involves obtaining the credential from a credential issuer. This credential issuer generates the credential by: generating the private key and the corresponding public key; generating the profile so that the profile specifies allowed operations which are consistent with terms of a licensing agreement; generating the digital certificate containing the profile; and signing the digital certificate with the private key.
In a variation on this embodiment, the allowed operations on the document can include: saving the document; modifying the document; adding comments to the document; digitally signing the document; and submitting the document as a form.



BRIEF DESCRIPTION OF THE FIGURES
FIG. 1 illustrates a system that uses a digital certificate to facilitate enforcement of licensing terms in accordance with an embodiment of the present invention.
FIG. 2 illustrates the structure of a credential in accordance with an embodiment of the present invention.
FIG. 3 presents a flow chart illustrating how a credential is generated in accordance with an embodiment of the present invention.
FIG. 4 presents a flow chart illustrating how a subset of the allowed operations is selected by an administrator in accordance with an embodiment of the present invention.
FIG. 5 presents a flow chart illustrating how a document is digitally signed in accordance with an embodiment of the present invention.
FIG. 6 presents a flow chart illustrating how operations on a document are enabled in accordance with an embodiment of the present invention.



DETAILED DESCRIPTION
The following description is presented to enable any person skilled in the art to make and use the invention, and is provided in the context of a particular application and its requirements. Various modifications to the disclosed embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be applied to other embodiments and applications without departing from the spirit and scope of the present invention. Thus, the present invention is not limited to the embodiments shown, but is to be accorded the widest scope consistent with the principles and features disclosed herein.
The data structures and code described in this detailed description are typically stored on a computer-readable storage medium, which may be any device or medium that can store code and/or data for use by a computer system. This includes, but is not limited to, magnetic and optical storage devices, such as disk drives, magnetic tape, CDs (compact discs) and DVDs (digital versatile discs or digital video discs), and computer instruction signals embodied in a transmission medium (with or without a carrier wave upon which the signals are modulated). For example, the transmission medium may include a communications network, such as a LAN, a WAN, or the Internet.
System
FIG. 1 illustrates a system 100 that uses digital certificates to facilitate enforcement of licensing terms in accordance with an embodiment of the present invention.
This system includes a credential issuer 102, which issues a credential 104 (such as an X.509 credential) to a server. As illustrated in FIG. 2, this credential includes a private key 202 and a digital certificate 204. Like a conventional digital certificate (such as an X.509 certificate), digital certificate 204 includes a certificate chain 206 and a public key 208. In addition to these standard components, digital certificate 204 includes a profile 210, which specifies operations that are allowed to be performed on a document signed with this digital certificate.
Referring back to FIG. 1, credential 104 is communicated to a server application 106, which displays the allowed operations specified in the profile to an administrator 115. Server application 106 then allows the administrator 115 to select a subset of the allowed operations to be enabled for a document 110.
Note that the term “document” as used in this specification and the appended claims generally refers to any digital output from an application. For example, a document can include: a textual document, a digital image, a digital sound file, a digital video clip or computer software. For example, if the application is a compiler, the document can include an executable file, or if the application is an image editing system, the document can include a digital image.
Server application 106 then digitally signs document 110. During this signing process, the system attaches information identifying the subset of allowed operations 111 and a copy of digital certificate 204 to document 110, and then digitally signs the document (and attached information) using private key 202 to produce digital signature 112.
When a client application 114, such as a document editor, receives document 110, client application 114 validates the digital signature on the signed document. If the digital signature is valid, client application 114 examines the profile 210 contained in the digital certificate 204 (as well as the information identifying the selected subset of allowed operations 111) to determine which operations are allowed on the document.
Next, client application 114 enables the allowed operations to be performed on document 110 (and disables other operations). This enables user 118 to perform operation on document 110 through UI 116. On the other hand, if the digital signature is not valid, the user 118 is disabled from performing operations on document 110.
Note that the allowed applications can generally include any type of operation that can be performed on a document. For example, the allowed operations can include: saving the document; modifying the document; adding comments to the document; digitally signing the document; and submitting the document as a form.
Also note that client application 114 and server application 106 can reside on any type of computing device, such as computing device a based on a microprocessor, a mainframe computer, a digital signal processor, a portable computing device, a personal organizer, a device controller, an embedded system and a computational engine within an appliance.
Credential Generation
FIG. 3 presents a flow chart illustrating how a credential (such as a credential defined under the X.509 standard) is generated in accordance with an embodiment of the present invention. At the start of this process, two parties (a software distributor and a customer) form a licensing agreement for some software (step 302). Next, a credential issuer 102 associated with the software distributor generates a credential 104 which contains a digital certificate with a profile 210 specifying operations that are allowed under the licensing agreement (step 304). Credential issuer 102 then delivers this credential 104 along with associated software to the customer (step 306). Note that the credential issuer 102 can alternatively be a third party (or intermediary) who does not actually generate the credential, but instead obtains the credential from a credential generator and then delivers the credential to a customer.
Operation Selection by Administrator
FIG. 4 presents a flow chart illustrating how a subset of the allowed operations is selected by an administrator in accordance with an embodiment of the present invention. First, a server application validates the credential (step 402). This typically involves ensuring that the digital signature and the certificate chain are valid, and that the credential has not expired or has not been revoked. Note that testing for revocation can involve looking up the credential in a certificate revocation list (CRL). Note that this type of lookup is in a CRL well-known for digital certificates.
Also note that the server application can possibly be newly installed software received from the software distributor. Hence, by controlling the allowed operations in the certificate, the software distributor can effectively control the capabilities of the server application without having to generate a customized software configuration for each different set of server application capabilities.
Next, the server application examines the profile within the credential to determine which operations are allowed on documents under the licensing agreement (step 404). The server application then configures a UI based on the allowed operations (step 406). This enables the administrator to select a subset of the allowed operation to be enabled in documents signed by the server application (step 408).
Digital Signing Process
FIG. 5 presents a flow chart illustrating how a document is digitally signed in accordance with an embodiment of the present invention. First the server application generates (or otherwise obtains) the document (step 502). Next, the server application includes the digital certificate (with the profile) and the information identifying the selected subset with the document and then signs the document (step 504).
Enabling Operations on a Document
FIG. 6 presents a flow chart illustrating how operations on a document are enabled in accordance with an embodiment of the present invention. First, a client application receives the signed document (step 602). Next, the client application attempts to validate the digital signature to ensure the digital signature has not expired or been revoked (step 604). If the digital signature is not successfully validated, the client application disables operations from being performed on the document (step 612).
In this way, if the credential issuer revokes the certificate, this revocation can: disable all operations on all documents ever created by the system, disable documents created after a particular date, or suspend operations for all of the documents temporarily. Furthermore, when the certificate is revoked, the server application may also stop functioning.
Otherwise, if at step 604, the digital signature is successfully validated, the client application examines the profile (and selected subset information) to determine which operations are allowed on the document (step 608). The client application then enables the allowed operations on the document (step 610).
The foregoing descriptions of embodiments of the present invention have been presented only for purposes of illustration and description. They are not intended to be exhaustive or to limit the present invention to the forms disclosed. Accordingly, many modifications and variations will be apparent to practitioners skilled in the art. Additionally, the above disclosure is not intended to limit the present invention. The scope of the present invention is defined by the appended claims.

## Claims

1. A method for using digital certificates to facilitate enforcing licensing terms for applications that manipulate documents, comprising:
performing the following via a particular computing device:
obtaining a credential, wherein the credential includes a private key and a digital certificate containing a corresponding public key and a profile specifying allowed operations permitted to be performed on documents signed with the credential;
based on said allowed operations specified by the digital certificate, configuring features of a particular application residing on and executable by said particular computing device;
digitally signing a document with the credential, wherein said digitally signing comprises digitally signing the document with the private key and including a copy of the digital certificate within said document; and
providing to an other application residing on and executable by an other computing device, an indication of operations that the other application is permitted to perform on said document in accordance with said allowed operations specified by the digital certificate; wherein providing the indication comprises providing the digitally signed document to said other application.

2. The method of claim 1, further comprising:
receiving the signed document at said other application;
validating the digital signature on the signed document; and
if the digital signature is valid,
examining the profile contained in the digital certificate to determine which operations are allowed on the document, and
enabling the allowed operations to be performed on the document, and disabling other operations; and

if the digital signature is not valid, disabling operations from being performed on the document.

3. The method of claim 2, wherein validating the digital signature involves determining that the digital certificate is not expired or revoked.

4. The method of claim 3, further comprising revoking the digital certificate if terms of a license associated with the digital certificate are violated; wherein revoking the digital certificate causes operations to be disabled for all documents signed with the digital certificate.

5. The method of claim 1, wherein said configuring features of the particular application comprises:
configuring a user interface (UI) of said particular application based upon the allowed operations specified in the profile; and
receiving a selection of a subset of the allowed operations through the UI;
wherein digitally signing the document includes incorporating information which identifies the selected subset into the document; and
wherein said operations that the other application is permitted to perform include said subset of the allowed operations.

6. The method of claim 1,
wherein obtaining the credential involves obtaining the credential from a credential issuer; and
wherein the credential issuer generates the credential by,
generating the private key and the corresponding public key,
generating the profile so that the profile specifies allowed operations which are consistent with terms of a licensing agreement,
generating the digital certificate containing the profile, and
signing the digital certificate using the private key.

7. The method of claim 1, wherein the allowed operations on the document comprise one or more of:
saving the document;
modifying the document;
adding comments to the document;
digitally signing the document; and
submitting the document as a form.

8. A computer-readable storage device storing instructions that when executed by a computer cause the computer to perform a method for using digital certificates to facilitate enforcing licensing terms for applications that manipulate documents, the method comprising:
obtaining a credential, wherein the credential includes a private key and a digital certificate containing a corresponding public key and a profile specifying allowed operations permitted to be performed on documents signed with the credential;
digitally signing a document with the credential, wherein said digitally signing comprises digitally signing the document with the private key and including a copy of the digital certificate within said document; and
providing to an other application residing on and executable by an other computing device, an indication of operations that the other application is permitted to perform on said document in accordance with said allowed operations specified by the digital certificate; wherein providing the indication comprises providing the digitally signed document to said other application.

9. The computer-readable storage device of claim 8, wherein the method further comprises:
receiving the signed document at said other application;
validating the digital signature on the signed document; and
if the digital signature is valid,
examining the profile contained in the digital certificate to determine which operations are allowed on the document, and
enabling the allowed operations to be performed on the document, and disabling other operations; and

if the digital signature is not valid, disabling operations from being performed on the document.

10. The computer-readable storage device of claim 9, wherein validating the digital signature involves determining that the digital certificate is not expired or revoked.

11. The computer-readable storage device of claim 10, wherein the method further comprises revoking the digital certificate if terms of a license associated with the digital certificate are violated; wherein revoking the digital certificate causes operations to be disabled for all documents signed with the digital certificate.

12. The computer-readable storage device of claim 8, wherein said configuring features of the particular application comprises:
configuring a user interface (UI) of said particular application based upon the allowed operations specified in the profile; and
receiving a selection of a subset of the allowed operations through the UI;
wherein digitally signing the document includes incorporating information which identifies the selected subset into the document; and
wherein said operations that the other application is permitted to perform include said subset of the allowed operations.

13. The computer-readable storage device of claim 8,
wherein obtaining the credential involves obtaining the credential from a credential issuer; and
wherein the credential issuer generates the credential by,
generating the private key and the corresponding public key,
generating the profile so that the profile specifies allowed operations which are consistent with terms of a licensing agreement,
generating the digital certificate containing the profile, and
signing the digital certificate using the private key.

14. The computer-readable storage device of claim 8, wherein the allowed operations on the document comprise one or more of:
saving the document;
modifying the document;
adding comments to the document;
digitally signing the document; and
submitting the document as a form.

15. A computer that uses digital certificates to facilitate enforcing licensing terms for applications that manipulate documents, comprising:
a storage device storing code executable on the computer to implement:
a receiving mechanism configured to receive a credential, wherein the credential includes a private key and a digital certificate containing a corresponding public key and a profile specifying allowed operations permitted to be performed on documents signed with the credential;
based on said allowed operations specified by the digital certificate, configuring features of a particular application residing on and executable by said particular computing device;
a document-signing mechanism configured to digitally sign a document with the credential, wherein said digitally signing comprises digitally signing the document with the private key and including a copy of the digital certificate within said document; and
providing to an other application residing on and executable by an other computing device, an indication of operations that the other application is permitted to perform on said document in accordance with said allowed operations specified by the digital certificate; wherein providing the indication comprises providing the digitally signed document to said other application.

16. The computer of claim 15:
wherein said other application receives the signed document;
wherein the application includes a validation mechanism for validating the digital signature on the signed document; and
wherein the application includes an operation-enabling mechanism, wherein if the digital signature is valid, the operation enabling mechanism is configured to,
examine the profile contained in the digital certificate to determine which operations are allowed on the document, and to
enable the allowed operations to be performed on the document, and disabling other operations;

wherein if the digital signature is not valid, the operation-enabling mechanism is configured to disable operations from being performed on the document.

17. The computer of claim 16, wherein the validation mechanism is configured to determine that the digital certificate is not expired or revoked.

18. The computer of claim 17, wherein the code is executable to implement a revocation mechanism configured to revoke the digital certificate if terms of a license associated with the digital certificate are violated; wherein revoking the digital certificate causes operations to be disabled for all documents signed with the digital certificate.

19. The computer of claim 18, wherein the code is executable to implement an operation-selection mechanism, wherein before the document-signing mechanism signs the document with the credential, the operation-selection mechanism is configured to:
configure a user interface (UI) based upon the allowed operations specified in profile; and to
receive a selection of a subset of the allowed operations through the UI;
wherein the document-signing mechanism is configured to incorporate information which identifies the selected subset into the document; and
wherein said operations that the other application is permitted to perform include said subset of the allowed operations.

20. The computer of claim 15,
wherein the receiving mechanism is configured to receive the credential from a credential issuer; and
wherein the credential issuer is configured to generate the credential by,
generating the private key and the corresponding public key,
generating the profile so that the profile specifies allowed operations which are consistent with terms of a licensing agreement,
generating the digital certificate containing the profile, and
signing the digital certificate using the private key.

21. The computer of claim 15, wherein the allowed operations on the document comprise one or more of:
saving the document;
modifying the document;
adding comments to the document;
digitally signing the document; and
submitting the document as a form.