Source language: Translate to:

Read encrypted ini file.

General questions about NeoBook

Moderator: Neosoft Support

Read encrypted ini file.

Postby ebear » Sat May 31, 2014 11:55 am

Hello All,

I'm working on a application which need to read variables out of a .ini file. This is of cause no problem.
For security reasons the ini file has to be Encrypted, also no problem with the perfect npCiph from Dec.

The problem is that when I want to read the Encrypted ini file I have to Decrypt the file on the users hard disk, read it and delete it again.
This makes the ini file for a moment insecure and with this it will be possible to read the file.

My question is if there is a way to read an Encrypted ini file without Decrypt them????

Best regards,

Eric
http://www.lunarsoftware.eu - Lunar Software ERP database Development. Manufacturing processes, Document management, QMS, Stock management. Standalone solutions or connected to Helios Orange and other ERP systems.
User avatar
ebear
 
Posts: 270
Joined: Wed Jan 18, 2012 3:12 am
Location: Vrchlabi - Czech republic

Re: Read encrypted ini file.

Postby dec » Sat May 31, 2014 12:13 pm

Hello Eric,

If you only need to read the INI file a possible solution can be to embed such INI file in your publication: the npConf plugin allows you to read embedded INI files, so the file no need to be extracted from your publication at all. ;)
.
Enhance your NeoBook applications!
.
58 plugins, 1131 actions and 233 samples
.
NeoPlugins website: www.neoplugins.com
.
User avatar
dec
 
Posts: 1663
Joined: Wed Nov 16, 2005 12:48 am
Location: Spain

Re: Read encrypted ini file.

Postby ebear » Sat May 31, 2014 12:28 pm

Haha David,

I was already convinced you would react..... ;-)

The problem is that the ini file cannot be embedded, it's a license file that will need to be changed outside of the application.
I'm trying to find the best solution to protect my applications...

Regards,

Eric
http://www.lunarsoftware.eu - Lunar Software ERP database Development. Manufacturing processes, Document management, QMS, Stock management. Standalone solutions or connected to Helios Orange and other ERP systems.
User avatar
ebear
 
Posts: 270
Joined: Wed Jan 18, 2012 3:12 am
Location: Vrchlabi - Czech republic

Re: Read encrypted ini file.

Postby dec » Sat May 31, 2014 12:37 pm

Hello,

ebear wrote:The problem is that the ini file cannot be embedded, it's a license file that will need to be changed outside of the application.
I'm trying to find the best solution to protect my applications...


Take caution with this Eric: you can view yourself spending time and efforts which never be recompensate. Think that if anyone have interest in your application and do not want to pay, and have the appropaite knowledge, no matter what do you try... probably the aplication become "cracked" anyway. So follow the general recomendation in these cases: spend the time in your publication and your customers, and forget people who simply do not want to pay, because maybe don't know the time, effort and work needed to develop an application.

On the other hand... what if you save encrypted values into the INI file? Not to encrypt the entire INI file, but just some text values. Then you can read it with encrypted and proceed to decrypt in your publication. Think also in the Windows Registry. You know the npConf plugin allow you to works with them too plus INI files.
.
Enhance your NeoBook applications!
.
58 plugins, 1131 actions and 233 samples
.
NeoPlugins website: www.neoplugins.com
.
User avatar
dec
 
Posts: 1663
Joined: Wed Nov 16, 2005 12:48 am
Location: Spain

Re: Read encrypted ini file.

Postby ebear » Sat May 31, 2014 12:50 pm

David,

It's not about not paying for the software because I don't sell my applications, but I found that some people are interested to take it and use it somewhere else (of cause for free ;-).
I'm already thinking a long time to create a (at least) basic protection for my applications, and I had this weekend some spare time so I started.....

But your idea is very good to Encrypt the values in the INI file instead of the file it self. It's even so good that O think I found the solution....

Regards,


Eric
http://www.lunarsoftware.eu - Lunar Software ERP database Development. Manufacturing processes, Document management, QMS, Stock management. Standalone solutions or connected to Helios Orange and other ERP systems.
User avatar
ebear
 
Posts: 270
Joined: Wed Jan 18, 2012 3:12 am
Location: Vrchlabi - Czech republic

Re: Read encrypted ini file.

Postby dec » Sat May 31, 2014 1:04 pm

Hello,

May we can get into problems if the encrypted is bad set or get.

So you need to try it and find if can be a solution for you at all.

But I can remember in the past I take this kind of solution, so... ;)
.
Enhance your NeoBook applications!
.
58 plugins, 1131 actions and 233 samples
.
NeoPlugins website: www.neoplugins.com
.
User avatar
dec
 
Posts: 1663
Joined: Wed Nov 16, 2005 12:48 am
Location: Spain

Re: Read encrypted ini file.

Postby Wrangler » Sun Jun 01, 2014 10:22 am

A good trick is to encrypt it with npciph. When time to decrypt, create a temp subfolder in the users temp folder. Name the subfolder using a long number: Example: 658754823698774. You can even generate a random number for the subfolder right before decrypting. Then decrypt the file into that folder. Read what you need then delete it and the subfolder.

The chances of a user finding and reading the file in the very short time it is open is almost impossible. It's not 100%, but it keeps the honest people honest and will make it very difficult for a cracker.
Wrangler
--------------
"You never know about a woman. Whether she'll laugh, cry or go for a gun." - Louis L'Amour

Windows 7 Ultimate SP1 64bit
16GB Ram
Asus GTX 950 OC Strix
Software made with NeoBook
http://highdesertsoftware.com
User avatar
Wrangler
 
Posts: 1507
Joined: Thu Mar 31, 2005 11:40 pm
Location: USA

Re: Read encrypted ini file.

Postby ebear » Sun Jun 01, 2014 1:36 pm

Hello Wrangler,

Yes this works perfect. I was trying another way to archive it but we had a little problem with it see: http://www.neosoftware.com/community/viewtopic.php?f=3&t=20531.
For the time being i will use your approach, i think this works fine and is on the moment enough for me.

David... This approach doesn't give the problem....

Thanks a lot.

Regards,

Eric
http://www.lunarsoftware.eu - Lunar Software ERP database Development. Manufacturing processes, Document management, QMS, Stock management. Standalone solutions or connected to Helios Orange and other ERP systems.
User avatar
ebear
 
Posts: 270
Joined: Wed Jan 18, 2012 3:12 am
Location: Vrchlabi - Czech republic


Return to General NeoBook Discussions

Who is online

Users browsing this forum: No registered users and 2 guests