Class LicensePublisher
Publishes signed licenses to LicenseClient.
Inheritance
Implements
Inherited Members
Namespace: DevZest.Licensing
Assembly: DevZest.Licensing.dll
Syntax
public abstract class LicensePublisher : ILicensePublisher
Remarks
ILicensePublisher interface is the service contract between LicensePublisher and LicenseClient. LicensePublisher class implements ILicensePublisher interface throught the public Publish(Int32, String, String, String, String, String, String, String, String) method. The service class derived from LicensePublisher can be hosted as traditional ASP.Net web service, or WCF (Windows Communication Foundation) service.
The LicensePublisher class, together with LicenseClient class, handles license signing, data serialization/deserialization, data encryption/descryption, and exception handling. Sensitive data communicated between LicenseClient and LicensePublisher, such as license key and published license, are encrypted so that no SSL is required.
LicensePublisher derived service class must override GetLicense(CultureInfo, String, Version, LicenseKey, String, String, String, String, String) and GetPrivateKeyXml(String) methods. The overrided GetPrivateKeyXml(String) must return the same private key used to sign the coresponding product assembly, to sign the published license.
Constructors
Name | Description |
---|---|
LicensePublisher() | Initializes a new instance of the LicensePublisher class that caches the private key. |
LicensePublisher(Boolean) | Initializes a new instance of the LicensePublisher class, given a value indicating whether the private key should be cached. |
Methods
Name | Description |
---|---|
GetLicense(CultureInfo, String, Version, LicenseKey, String, String, String, String, String) | Gets the requested license. |
GetPrivateKeyXml(String) | Gets the private key XML string for the specified product. |
PrivateKeyXmlFromSnkFile(Stream) | Gets the private key XML string from Strong Name Key (.snk) stream. |
PrivateKeyXmlFromSnkFile(String) | Gets the private key XML string from Strong Name Key (.snk) file. |
Publish(Int32, String, String, String, String, String, String, String, String) | Gets the requested license. |