Topic: How To Encrypt And Open By MVD Only

I will to encrypt  lock
sqlite.db or settings.ini or script.pas
and open by MVD only how to edit code ?

My Visual Database : I Love You
Easy For Beginner Student For Me

Re: How To Encrypt And Open By MVD Only

Hello prahousefamily,


I'm not sure you can do that (you'll have to wait for Dmitry's answer to make sure).


You can use StrToMD5 to encrypt password for example, but you can not decrypt it afterwards. You can only compare a password typed in by the user on wich you apply MD5 with the already MD5 password in database.


You don't need to distribute the script.pas file with your exe file once compiled, it can be deleted before distributing.

I'm a very good housekeeper !
Each time I get a divorce, I keep the house

Zaza Gabor

Re: How To Encrypt And Open By MVD Only

Ummm....
script.pas can delete after compiled ?

i will my student  cannot see script.pas because protect copy code
i hope my student think and analyze by yourself
Thank you very much mathmathou.

My Visual Database : I Love You
Easy For Beginner Student For Me

Re: How To Encrypt And Open By MVD Only

prahousefamily
You can't encrypt sqlite.db but you can delete script.pas, after that project will work but user can't open project in MVD to see code.

Dmitry.

5 (edited by abouyahya527911 2015-12-10 05:26:28)

Re: How To Encrypt And Open By MVD Only

DriveSoft wrote:

prahousefamily
You can't encrypt sqlite.db but you can delete script.pas, after that project will work but user can't open project in MVD to see code.


Dmitry are working on this ? is been many users asking about encrypt sqlite.db if cant encrypt sqlife him self any good idea to protect code and data , and import and export data too  in clean way ( PS :  in vote was in this form i think was made by u  the most  option to add it been voted  )
  i love my MVD i will love it more if i have this 2 add to it wink

Thanks keep it up

Re: How To Encrypt And Open By MVD Only

Because I'm curious and I wanted to test this, I made some research and came up with a little something for you.


This does not protect you database with password
This does not prevent people from opening your database with an editor and looking inside


What it does is transpose and transform strings into others, making them readable in a database editor, but not understandable. There is not salt, or hash or encryption with key, because those function are not yet implemented in MVD and we can not make calls to external resources.


The encrypt et decrypt function is the same and, to keep the code simple for you, I did not use DataSets (so you will see an awful double query  line 44:)  )


Anyway have fun with this


Cheers



Mathias

Post's attachments

Attachment icon Encryption.zip 335.84 kb, 594 downloads since 2015-12-10 

I'm a very good housekeeper !
Each time I get a divorce, I keep the house

Zaza Gabor