I have made an application in which I want that the application should expire after say 180 Days but the problem is that if I take the system date, anyone could just change it and get going and I cannot also take the internet date because many times the user will be working offline. So how do I make it trial after which it self destructs itself? I cannot put any other DRM as I have read that checking MAC address is a very bad DRM and after going through Making commercial Java software (DRM) I realised I have to make it somewhat simple. So the idea I have in mind is that I put a count that how many times has the application being started, but where do I store the value in registry? (I have already read: read/write to Windows Registry using Java)

I have also read Create a trial version of a Java application, with limited functionality and How to create a trial version of a Java program but the answers given there were not satisfactory. Because:
1. In one answer it is given that use "Rampart" but that is a paid application and I do not want to use it.
2. In another answer they checked with system date but as I told earlier I do not want to use that either.
3. One Question and Answer was related to functionality which is not what I want to reduce
4. and further many of them require internet but my customers may not be using it all the time

I know that there is no perfect DRM and everyone of them can be cracked. What I am asking here is what is my best shot? (Note: I have limited number of users, I will not sell this application online)

Update: This question I believe is not off topic because what I really am asking is just how do I make my software go trial... I am just asking how? I know it can be cracked easily but just tell me what is the best way to set up a trial in java

有帮助吗?

解决方案

Ship a data file with the package containing:

  1. The name of the customer in full.
  2. The date it was shipped.
  3. The date it should expire.
  4. A checksum of the whole file so it cannot be edited.

Every time you run:

  1. Check that the checksum is still valid.
  2. Check that the file mod date does not suggest that the file has been tampered with.
  3. Display the customer name in a splash screen.
  4. Make sure the mod date on the file is not later than the expiry date.
  5. "Touch" the file to make sure it's mod-date changes to current date.
  6. Make sure the "Touch" worked.

This way:

  1. It is difficult to make a copy as the mod date will change.
  2. It is difficult to distribute copies to others as the source is easily available.
  3. It should be possible to detect most inexpert tampering.

Obviously - without adding hardware - it is impossible to cover all bases but I have found this scheme works well.

其他提示

If internet connection is not available, there is one method left behind if end-users are in a company network and using windows with active directory (most companies have active directory if clients are windows), use active directory server as a time server. Most users may change clock time on their client windows, but they don't want to change time on their servers due to other affecting software (mail server etc). License4J can find and check date/time on a local active directory server.

(Disclosure: I work for License4J)

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top