## Justification of the Proposed Scheme

To justify the proposed scheme, we present a brief outline of the advantages, as well as a brief summary of alternatives that were ruled out for various reasons.

### Advantages of the Scheme:

- Convenience for web authors - while a sophisticated authoring tool could make the design-time process completely invisible for web authors, even a simple design-time utility could make creation of .LPK files quite easy for authors that write HTML directly using tools such as Notepad.
- Extra convenience for web sites - a site with many web pages and many licensed controls could easily create one .LPK license package file containing all the licenses for all the pages on the site. After the one-time creation of this .LPK file, it is easy to refer to it from all pages on the site.
- Inconvenience for pirates - the average web developer cannot accidentally pirate licensed controls without realizing that they are breaking copyright laws. Although intentional piracy is not impossible, it is rather inconvenient and requires knowledge of the .LPK file format.

### Other Licensing Alternatives that Were Considered

- Tying the .LPK file to a particular site(s) - one could achieve additional security by tying a license package to the site at which it would be used (for example, by including a list of URL prefixes or an X.509 certificate in the .LPK). However, the additional security is not worth the inconvenience to web authors, especially for publishers that host many sites, or for HTML-designer contractors that write HTML pages for many different publishers.
- Tying the .LPK to a particular HTML page - it is possible to use CRC digests to link a .LPK to a particular .HTML page. This was widely rejected as being too difficult at design time, and impossible for dynamically generated content.
- Using digital certificates for foolproof security - although in the future Microsoft intends to pursue 100% foolproof solutions to the licensing probleme, for short-term needs (Internet Explorer 3.0) a simpler solution is much more practical.

### HTML Syntax for Referencing .LPK Files

License packages must be inserted in HTML files using the existing <OBJECT> tag (element). The license package is interpreted by a License Manager object that is used to hand licenses to other Controls on the HTML page. The license package object must be embedded in the HTML page before any other objects that require licensing. The specific syntax for embedding license packages in HTML is as follows:

    <OBJECT CLASSID = "clsid:5220cb21-c88d-11cf-b347-00aa00a28331">
         <PARAM NAME="LPKPath" VALUE="relative URL to .LPK file">
    </OBJECT>

Note Internet Explorer 3.0 will only honor the first license package in an HTML page. If controls on this page require licenses that are not inlcuded in this license package, then they will afil to instantiate.

### License Package File Format

The .LPK license package file is a plain text file, and must be labeled by servers with the MIME type text/plain. Any binary data in the file is uuencoded. This allows the file to be viewable by web browsers, so that anyone trying to copy the file would clearly notice the copyright statement at the top of the file. The contents of the file are as defined below. This file will be interpreted by a License Manager object.

.LPK Header | This header identifies the file type: "LPK License Package"
Copyright text or other legal statement | "Legalese" to dissuade casual copying of .LPKs.
LPK version GUID | In plain-text on a line by itself. This GUID is used to mark the beginning of the real license package data, and it is also used to identify the LPK file format version: "{5220cb21-c88d-11cf-b347-00aa00a28331}"

Uuencoded(Base64) license package:

    struct {
        UUID uuidLPKFile;   // unique per LPK
        DWORD dwLicenses;   // number of licenses in the file
        LICENSEPAIR aLicenses[]; // array of license pairs
    } LICENSEPACKAGE;

    struct {
        CLSID clsid;        // clsid of object
        DWORD cchLic;       // Number of characters in the license
        WCHAR ach[];        // License (saved as UNICODE characters)
    } LICENSEPAIR;

### Authoring Tools

HTML authoring tools will make it easy to create HTML pages with embedded ActiveX Controls. Such tools should be responsible for creating the .LPK license package for licensed controls used on a page or on a web site. Since there may be a one-to-many mapping between LPKs and HTMs, this may be more difficult for pagebased authoring tools as opposed to web-based authoring tools (e.g. Microsoft FrontPage).

Clearly, tool support is necessary for Notepad HTML authors as well. The solution is a simple GUI tool that lists all controls that are installed on a machine with design-time licenses. The tool allows a user to create a .LPK license package by selecting which Controls should be included in the package. A second tool could parse HTML pages an create a .LPK file for all the controls that require licensing.

### NCompass support for licensing ActiveX Controls

It is crucial that the licensing scheme described above works in other ActiveX-enabled web browsers, particularly in the NCompass ActiveX Plug-in. Because the plug-in specification only allows plug-ins to be specified using the <EMBED> syntax, therefore pages authored to work with both Internet Explorer 3.0 and NCompass will need to use syntax similar to the following:

    <OBJECT CLASSID = "clsid:5220cb21-c88d-11cf-b347-00aa00a28331">
        <PARAM NAME="LPKPath" VALUE="relative URL to .LPK file">

        <EMBED SRC = "FOO.LPK">
    </OBJECT>

© 1996 Microsoft Corporation