Page 1 of 1

How do use unlocked sections

Posted: Thu Nov 09, 2023 4:01 am
by mosker
hi administrator:
How do I use this <unlocked sections> attribute? Is there a demo or a detailed description?
see.png

Re: How do use unlocked sections

Posted: Tue Nov 14, 2023 10:11 am
by Enigma
Hi, unlocked sections allow to embed some information inside the key and then extract this information in a program.
Let say you have few unique features inside the application, that should be enabled depending on a license, so in application you can extract unlocked sections array and change program behavior depending on this.

There are two ways how to use unlocked sections.
1. Using Enigma API functions. Call EP_RegLoadAndCheck key to make sure the key is valid, then EP_RegLoadKey to take license name and key, then EP_RegKeyInformation to extract sections array.
2. Using Markers, RegCrypt or UnregCrypt. The code inside RegCrypt markers is being decrypted if the section allow it. I.e. if license key unlocks section #1, then the code inside the marker RegCrypt1 will be decrypted and executed. If key does not have this section, the code inside this marker will be just skipped.