I'm trying to implement offline activation and I have the following problem.
When user enters both Activation Key and Computer Key, I'm passing them to the generated LicenseValidator.ValidateLicense(…) method. If this method returns true, I consider the license keys valid and store them. What I've found is that Activation Key can be completely unrelated to the Computer Key, LicenseValidator.ValidateLicense(…) completely skips Activation Key check when Computer Key is present.
The problem is that stored Activation Key is used by LicenseValidator at startup for license revocation and subscription reactivation checks, so I need a valid Activation Key in order for this to work.
How do I check that both Activation Key and Computer Key are correct? If I pass only Activation Key without Computer Key (string.Empty or null) to LicenseValidator.ValidateLicense(…) and then vice versa and then combine the results, will I achieve the desired outcome or this does not guarantee that key pair is valid?
Please sign in to leave a comment.