title: How to limit usage of my licensed software for customers with closed networks?
body: <p>I have developed a linux desktop application which has a variable cost depending on how many "widgets" the user intends to create with my software. If they exceed that amount they need to purchase access to create more widgets.</p>
  
  <p>This all has to be done offline as the widgets are highly confidential and the customers tend to close off their networks to the outside world.</p>
  
  <p>I plan on providing the customer an encrypted license key which will embed usage info regarding how many widgets they have purchased.</p>
  
  <p>The problem I still have is how to keep a tally of the number of widgets created as they are created. And how do I make that tally tamper proof.</p>
  
  <p>What I don't want to happen is to save the number of created widgets to a file and then when the customer hits their purchased limit they just set the file back to an older state and continue creating widgets.</p>
  
  <p>Any ideas for offline, tamper-proof usage tracking? My desktop app currently only targets linux.</p>
  
  <p>An on premise license server would be alright but not sure how to protect against database tampering?</p>