Class LicenseKey
This class contains information stored in a license key and is responsible for creating and decoding license keys.
Inherited Members
Namespace: ArmDot.Api.Keys
Assembly: ArmDot.Api.Keys.dll
Syntax
public class LicenseKey
Properties
ExpirationDate
Stores the expiration date that is stored in the license key.
Declaration
public DateTime? ExpirationDate { get; }
Property Value
Type | Description |
---|---|
DateTime? |
HardwareId
Stores the hardware id that is stored in the license key.
Declaration
public string HardwareId { get; }
Property Value
Type | Description |
---|---|
string |
Key
Stores the license key
Declaration
public string Key { get; }
Property Value
Type | Description |
---|---|
string |
MaximumBuildDate
Stores the maximum build date that is stored in the license key.
Declaration
public DateTime? MaximumBuildDate { get; }
Property Value
Type | Description |
---|---|
DateTime? |
RegistrationEMail
Stores the registration email that is stored in the license key.
Declaration
public string RegistrationEMail { get; }
Property Value
Type | Description |
---|---|
string |
RegistrationName
Stores the registration name that is stored in the license key.
Declaration
public string RegistrationName { get; }
Property Value
Type | Description |
---|---|
string |
UserData
Stores the user date that is stored in the license key.
Declaration
public byte[] UserData { get; }
Property Value
Type | Description |
---|---|
byte[] |
Methods
Create(byte[], byte[], string, string, DateTime?, DateTime?, byte[], string)
Creates a new license key
Declaration
public static LicenseKey Create(byte[] modulus, byte[] privateExponent, string registrationName, string registrationEmail, DateTime? expirationDate, DateTime? maximumBuildDate, byte[] userData, string hardwareId)
Parameters
Type | Name | Description |
---|---|---|
byte[] | modulus | A modulus that is used for license key generation |
byte[] | privateExponent | A private exponent that is used for license key generation |
string | registrationName | A registration name that is used for license key generation |
string | registrationEmail | A registration email that is used for license key generation |
DateTime? | expirationDate | An expiration date that is used for license key generation |
DateTime? | maximumBuildDate | A maximum build date that is used for license key generation |
byte[] | userData | A user data that is used for license key generation |
string | hardwareId | A hardware id that is used for license key generation |
Returns
Type | Description |
---|---|
LicenseKey |
Create(string, string, string, string, DateTime?, DateTime?, byte[], string)
Creates a new license key
Declaration
public static LicenseKey Create(string modulus, string privateExponent, string registrationName, string registrationEmail, DateTime? expirationDate, DateTime? maximumBuildDate, byte[] userData, string hardwareId)
Parameters
Type | Name | Description |
---|---|---|
string | modulus | A modulus that is used for license key generation |
string | privateExponent | A private exponent that is used for license key generation |
string | registrationName | A registration name that is used for license key generation |
string | registrationEmail | A registration email that is used for license key generation |
DateTime? | expirationDate | An expiration date that is used for license key generation |
DateTime? | maximumBuildDate | A maximum build date that is used for license key generation |
byte[] | userData | A user data that is used for license key generation |
string | hardwareId | A hardware id that is used for license key generation |
Returns
Type | Description |
---|---|
LicenseKey |
Decode(string, byte[], byte[])
Decodes a license key
Declaration
public static LicenseKey Decode(string key, byte[] modulus, byte[] publicExponent)
Parameters
Type | Name | Description |
---|---|---|
string | key | A license key |
byte[] | modulus | A modulus that has been used for license key generation |
byte[] | publicExponent | A public exponent that has been used for license key generation |
Returns
Type | Description |
---|---|
LicenseKey |