Labs64 / NetLicensing-Community

NetLicensing Community Support
https://netlicensing.io
MIT License
5 stars 1 forks source link

Combine Subscription and Node-Locked models in one product #58

Closed r-brown closed 1 year ago

r-brown commented 1 year ago

Question

We would like to map the following license models in the same product:

  • Subscription model (7 days free, then 1 year for a license fee)
  • Node-locking (customer can install our program on 1 or 2 computers (e.g. identified by CPU serial number) during the subscription period).

Is it possible to map this model in NetLicensing? If so, is there a way to uninstall a node via API, for example, if the customer uninstalls our software on a computer?

r-brown commented 1 year ago

Configuration

The above scenario can be configured in NetLicensing using two licensing models - Node-Locked and Subscription.

Screenshot 2022-12-30 at 08 42 47

where the Subscription model can specify the default package (e.g. 7 days) to be automatically assigned for every new customer:

01

... and Node-Locked model can specify 1 default node:

02

Validation

Customer validation request will request both product modules at once:

curl -X POST -H "Authorization: Basic ..." -H "Accept: application/xml" \
  -H "Content-type: application/x-www-form-urlencoded" \
  -d "dryRun=true&productModuleNumber=M7ARR47QI&nodeSecret=device-fingerprint0" \
  https://go.netlicensing.io/core/v2/rest/licensee/CUSTOMER-ID-01/validate

... and deliver the below response:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ns2:netlicensing xmlns="http://www.w3.org/2000/09/xmldsig#" xmlns:ns2="http://netlicensing.labs64.com/schema/context" ttl="2023-01-06T07:43:09.232Z">
 <ns2:infos/>
 <ns2:items>
   <ns2:item type="ProductModuleValidation">
     <ns2:property name="productModuleNumber">M7ARR47QI</ns2:property>
     <ns2:property name="valid">true</ns2:property>
     <ns2:property name="productModuleName">Servers</ns2:property>
     <ns2:property name="warningLevel">GREEN</ns2:property>
     <ns2:property name="licensingModel">NodeLocked</ns2:property>
   </ns2:item>
   <ns2:item type="ProductModuleValidation">
     <ns2:property name="productModuleNumber">MQQ9MC6HJ</ns2:property>
     <ns2:property name="valid">true</ns2:property>
     <ns2:property name="expires">2023-11-18T14:23:34.952Z</ns2:property>
     <ns2:property name="productModuleNumber">MQQ9MC6HJ</ns2:property>
     <ns2:property name="productModuleName">ABO</ns2:property>
     <ns2:property name="warningLevel">GREEN</ns2:property>
     <ns2:property name="licensingModel">Subscription</ns2:property>
   </ns2:item>
 </ns2:items>
</ns2:netlicensing>

valid parameters from both ProductModuleValidationsections need to be parsed and product behaviour is driven accordingly.

r-brown commented 1 year ago

Question 2

is there a way to uninstall a node via API, for example, if the customer uninstalls our software on a computer?

Option 1 - API

It is possible to release node locking via API - as described at #30

Option 2 - Customer Portal

It is also possible to allow customers to maintain their licenses by themselves via NetLicensing Customer Portal. So, customers can release paired nodes without involving the vendor's customer support.