public class OctetLicenseCreator extends Object implements ILicenseCreator
| Constructor and Description |
|---|
OctetLicenseCreator()
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
protected byte[] |
combine(int prefix,
byte[] signature)
Builds the combined license key (raw bytes).
|
String |
createLicenseKey(ILicenseContext context,
ILicense license)
Generates a key from the given license.
|
static String |
group(String s)
Groups a string into 8-character blocks.
|
protected byte[] |
sign(ILicenseContext context,
byte[] bytes)
Signes the given byte array.
|
public String createLicenseKey(ILicenseContext context, ILicense license)
createLicenseKey in interface ILicenseCreatorcontext - the licensing context.license - the license to be created.protected byte[] sign(ILicenseContext context, byte[] bytes) throws SigningException, NoSuchAlgorithmException, DecryptionException
bytes - the bytes to be signedSigningExceptionNoSuchAlgorithmExceptionDecryptionExceptionprotected byte[] combine(int prefix,
byte[] signature)
prefix - the integer prefix basically containing the expiry time in seconds since epoch timesignature - teh signatureIOExceptionCopyright © 2014. All rights reserved.