An overview of how floating licenses can be implemented in Cryptolens
IsOnRightMachine
check is similar to the one in the node-locking example, only differing in isFloatingLicense
, which is set to true.
FloatingTimeInterval specifies how long back in history of activations we should go, in order to decide whether a machine is still using the software or not (specified in seconds). MaxOverdraft specifies how many more devices than specified in maximum number of machines can use the software concurrently.Note, in comparison to node-locking, where key verification for most applications can occur once during startup, floating licensing requires continuous key verifications. The smaller FloatingTimeInterval, the more key verifications have to occur.
As a rule of thumb, if you plan to verify a license every 10 minutes, the FloatingTimeInterval should be no less than 600 (600s = 10min) if you want to ensure that your customers never exceed the maximum number of machines. However, if you can allow the customers to exceed this boundary in eg. 5 minutes, you could reduce FloatingTimeInterval to 300 (300s = 5min).
FloatingTimeInterval
). However, you can manually release a floating license by using Key.Deactivate with Floating=True
, as shown below:
Metadata=true
. A helper method, GetFloatingLicenseInformation can be used to extract this information.