Infralution Support Forum Index Infralution Support
Support groups for Infralution products
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Reading different sections from .lic files

 
Post new topic   Reply to topic    Infralution Support Forum Index -> Licensing Feature Requests
View previous topic :: View next topic  
Author Message
newyuppie



Joined: 07 Nov 2006
Posts: 12
Location: San Diego, CA, USA

PostPosted: Sun Nov 12, 2006 12:07 am    Post subject: Reading different sections from .lic files Reply with quote

hi,

i've been exploring a bit with Custom generating my licenses. I was hoping to achieve a hybrid between CustomLicensedApp and LicensedApp projects. meaning, i would like the functionality of having a license for a particular person, but storing all this info in a .lic file.

for example, i would love to have the .lic file say something like this:

#START .LIC FILE
[license]
9C38-9F3B-7DD5-36AB-907E-16F3-861C-755D
[name]
John Smith
#END FILE

this way, i would like to use code in my program like this for example:
Dim sProvider As New EncryptedLicenseProvider
Dim sLicense As EncryptedLicense = sProvider.GetLicense(LICENSE_PARAMETERS, LICENSE_FILE)

and get a valid sLicense (as it is now, because it reads the whole .lic file, i get an invalid license file).

and why i want this? well, if the .lic file is divided into sections, i could now check the stored parameters in the license, and check the Name i generated in the stored parameter, against the name stored in the .lic file in the [name] section. Otherwise, i would have no way of checking the license stored name against anything, unless i provide a textbox each time the user logs into my application and types in his name.

I know it could be done as in the CustomLicensedApplication example, where you store the name in a Settings file. My approach described above would be a workaround to that. And would provide the user a way to simply copy the .lic file around and have the app work anyways. otherwise, he would have to copy the .lic file, and the app settings file, and this would be an extra step which could be avoided.

Obviously if we embrace this approach, there is also the possibility of storing the license and other parameters (which you will check against the ones in the license number) in a XML file. if this were so, we could store a lot of info in the XML file very easily as there are a lot of methods in VB to read and store from XML files.

thanks ans sorry for the length of this post.
PA
Back to top
View user's profile Send private message Visit poster's website
Infralution



Joined: 28 Feb 2005
Posts: 5027

PostPosted: Sun Nov 12, 2006 10:31 pm    Post subject: Reply with quote

The approach used in the CustomLicensedApp allows you to store both the key and other information (eg the name) in the one file. Since we don't know what other information you may wish to store in this file it is probably better that reading/writing this type of file remains under the application control. This means that you can also choose the format of the file (XML, plain text etc).
_________________
Infralution Support
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    Infralution Support Forum Index -> Licensing Feature Requests All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group