Nuke binary plugins  14.0.8
DD::Image::License Class Reference

Public Attributes

unsigned system_id
 
const char * name
 
const char * version
 
SecurityEnvelope * security
 

Static Public Attributes

static unsigned this_system_id
 

Detailed Description

Object describing licensing restrictions for a Description object. If the licensing fails, the Description (and thus the plugin) will not work.

The system_id field must be set to DD::Image::License::this_system_id or you will get a license failure error when loading the plugin, and the program will act as though the Description containing this license does not exist. If you use any of the more advanced features then failure of them will also cause the same result. For better security, you should also check your License instance and Description at various points in the code, to make sure some cracker has not altered them. Also check any local data you have showing that your copy protection test really worked.

There are three types of security features available to plugins from Nuke:

  1. The first is simply the unique ID in this_system_id that any plugin or script has access to. It provides no security other than giving the developer something unique to key their own licensing code to. Your test can indicate success by copying this_system_id into the system_id field, or zero or any other value to indicate failure.
  2. The second is a check for a "feature" line added to Nuke's FLEXlm license file. The name and version, if not null, indicate a "feature" line to be looked up in the FLEXlm license file. If the feature is not there with at least the given version number, you will get a license failure error. The Foundry can generate such feature lines for you.
  3. The third type is the security structure. Currently this is unsupported, but is reserved for future use.

If DDImage is not being used by Nuke, than any Description with a License where either the system_id or name are not zero will fail as though the Description does not exist.

Member Data Documentation

unsigned DD::Image::License::this_system_id
static

This is a 32-bit value that is unique for each customer site. In the case of a node-locked license, each workstation has a different ID. In the case of a license server, the license server has a unique ID. Any plugin can examine this value, and tcl code can also get it with $this_system_id. Attempts to alter it are caught by Nuke and cause all plugins to stop working.

Simple protection is achieved by checking this_system_id against a list of known systems and setting system_id in a License to the first matching one, or zero if none. To populate this list you can ask your client to report the result of the Nuke tcl variable "$this_system_id" and then compile it in. Or you can do some trick whereby an unknown system_id does some web query or asks the user a question and if the results are ok it adds it to some internal encrypted list. If your plugin is supposed to work at exactly one site you can simply set license->system_id to the one for that site, and the plugin will not work anywhere else.

This value is zero if DDImage is being used by some program other than Nuke. If you want your plugin to work in such cases you must set the license pointer to zero if this value is zero.

unsigned DD::Image::License::system_id

Will not work unless this == this_system_id

const char* DD::Image::License::name

If not null, run license check for this

const char* DD::Image::License::version

Version number for license check

SecurityEnvelope* DD::Image::License::security

If not null, this structure is filled with secret stuff.



©2024 The Foundry Visionmongers, Ltd. All Rights Reserved.
www.foundry.com