Show / Hide Table of Contents

Property LocalMachineData

| Improve this Doc View Source

LocalMachineData

Gets the data for local machine.

Declaration
public static string LocalMachineData { get; }
Property Value
Type Description
System.String

A System.String value containing the data for local machine.

Remarks

When publishing an MachineLicense, the Data property should be set as the string value returned by LocalMachineData, otherwise the validation will always fail.

MachineLicense uses DPAPI to encrypt a known GUID as its Data property. The validation is to decrypt the Data property, compare it with the known GUID. It requires System.Security.Permissions.DataProtectionPermission. If your application or component is target partial trust environment without System.Security.Permissions.DataProtectionPermission, use UserLicense instead.

  • Improve this Doc
  • View Source
Back to top Copyright © Weifen Luo | DevZest