SQLCipher ported to Harbour (Windows)

Moderator: Rathinagiri

Post Reply
User avatar
bpd2000
Posts: 1207
Joined: Sat Sep 10, 2011 4:07 am
Location: India

Re: SQLCipher ported to Harbour (Windows)

Post by bpd2000 »

BPD
Convert Dream into Reality through HMG
User avatar
esgici
Posts: 4543
Joined: Wed Jul 30, 2008 9:17 pm
DBs Used: DBF
Location: iskenderun / Turkiye
Contact:

Re: SQLCipher ported to Harbour (Windows)

Post by esgici »

bpd2000 wrote:It is here...[/url]
Thank Dave and Dany :)

It seem has a few dangerous features ( disk / RAM edit ) :?

Anyway I will try.

Happy HMG :D
Viva INTERNATIONAL HMG :D
User avatar
Hazael
Posts: 109
Joined: Thu Jun 24, 2010 11:37 am
Location: France

Re: SQLCipher ported to Harbour (Windows)

Post by Hazael »

Hello Friends,

Przemek just updated Harbour to use SQLite 3.8.2 (the newest to date):

2014-02-02 19:22 UTC+0100 Przemyslaw Czerpak (druzus/at/poczta.onet.pl)
* contrib/3rd/sqlite3/*
* sqlite3 update 3.7.16.2. -> 3.8.2
* contrib/3rd/sqlite3/sqlite3.hbp
+ enabled FTS3/FTS4 (full text search) in SQLite

* contrib/hbtinymt/3rd/tinymt/*
* updated tinymt to 1.0.3

best regards
Przemek


And SQLCipher is updated to 3.0.1 (06/DEC/2013)
The problem is that this version is for SQLite 3.8.0.2
Here is SQLCipher link: http://sqlcipher.net/blog/2013/12/6/sql ... lease.html" onclick="window.open(this.href);return false;


How to have Harbour x SQLite x SQLCipher on the same pace to be able to have the best of 3?

Thanks for any help.
Harbour | GTWVT | MingW | Visual Studio Code
User avatar
Rathinagiri
Posts: 5471
Joined: Tue Jul 29, 2008 6:30 pm
DBs Used: MariaDB, SQLite, SQLCipher and MySQL
Location: Sivakasi, India
Contact:

Re: SQLCipher ported to Harbour (Windows)

Post by Rathinagiri »

Thanks a lot for the news Qatan.

I don't think that all the 3 will/can be integrated.

However, IMHO, even taking the lowest version of the three and integrate them is ok for our normal use.
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
User avatar
Hazael
Posts: 109
Joined: Thu Jun 24, 2010 11:37 am
Location: France

Re: SQLCipher ported to Harbour (Windows)

Post by Hazael »

Rathinagiri wrote:Thanks a lot for the news Qatan.

I don't think that all the 3 will/can be integrated.

However, IMHO, even taking the lowest version of the three and integrate them is ok for our normal use.
Right, but in the practice how I should do it?

Should I find and download:
  • SQLite 3.8.0.2
    SQL Cipher 3.0.0 (based on SQLITE 3.8.0.2)
    Harbour 3.2.0dev (r1403261330) [nightly build]
    ?
Well, as far as I remember you mentioned before that we have to disable the sqlite that comes with harbour and introduce the sqlcipher version instead.

Do you think it will work?

Sorry, I read the previous messages but I just want to make sure I understood it before trying...

Thanks for any help.
Harbour | GTWVT | MingW | Visual Studio Code
User avatar
Hazael
Posts: 109
Joined: Thu Jun 24, 2010 11:37 am
Location: France

Re: SQLCipher ported to Harbour (Windows)

Post by Hazael »

Hello Rathinagiri,

I am trying to build SQLCipher following your instructions but I am getting stuck with step 7...

I get this message:
Library crypto not found. Install openssl!

I have OpenSSL and I copied libeay32.a to C:\MingW\MSys\1.0 and tried with LDFLAGS="libeay32.a"
or even: ./configure --enable-tempstore=yes CFLAGS="-DSQLITE_HAS_CODEC" LDFLAGS="/C/OpenSSL/lib/MinGW/libeay32.a"

In any way I get that message or if it can't find the path I get this:
configure error: error: C compiler cannot create executables

Any idea of what could be wrong?

Thanks for your help.
Harbour | GTWVT | MingW | Visual Studio Code
User avatar
Rathinagiri
Posts: 5471
Joined: Tue Jul 29, 2008 6:30 pm
DBs Used: MariaDB, SQLite, SQLCipher and MySQL
Location: Sivakasi, India
Contact:

Re: SQLCipher ported to Harbour (Windows)

Post by Rathinagiri »

Qatan wrote:
Rathinagiri wrote:Thanks a lot for the news Qatan.

I don't think that all the 3 will/can be integrated.

However, IMHO, even taking the lowest version of the three and integrate them is ok for our normal use.
Right, but in the practice how I should do it?

Should I find and download:
  • SQLite 3.8.0.2
    SQL Cipher 3.0.0 (based on SQLITE 3.8.0.2)
    Harbour 3.2.0dev (r1403261330) [nightly build]
    ?
Well, as far as I remember you mentioned before that we have to disable the sqlite that comes with harbour and introduce the sqlcipher version instead.

Do you think it will work?

Sorry, I read the previous messages but I just want to make sure I understood it before trying...

Thanks for any help.
Sorry for the delay in giving this reply. I am just now seeing this message.

Yes, if we can successfully compile and create sqlcipher library then disabling the original sqlite library coming with harbour will work. But, still we need the bridge between sqlite and harbour. That can't be done away with.

ie, harbour\contrib\3rd\sqlite is not required.

but, harbour\contrib\hbsqlit3 is required.
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
User avatar
Rathinagiri
Posts: 5471
Joined: Tue Jul 29, 2008 6:30 pm
DBs Used: MariaDB, SQLite, SQLCipher and MySQL
Location: Sivakasi, India
Contact:

Re: SQLCipher ported to Harbour (Windows)

Post by Rathinagiri »

Qatan wrote:Hello Rathinagiri,

I am trying to build SQLCipher following your instructions but I am getting stuck with step 7...

I get this message:
Library crypto not found. Install openssl!

I have OpenSSL and I copied libeay32.a to C:\MingW\MSys\1.0 and tried with LDFLAGS="libeay32.a"
or even: ./configure --enable-tempstore=yes CFLAGS="-DSQLITE_HAS_CODEC" LDFLAGS="/C/OpenSSL/lib/MinGW/libeay32.a"

In any way I get that message or if it can't find the path I get this:
configure error: error: C compiler cannot create executables

Any idea of what could be wrong?

Thanks for your help.
Usually I copy openssl library files inside SQLCipher directory.
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
User avatar
Hazael
Posts: 109
Joined: Thu Jun 24, 2010 11:37 am
Location: France

Re: SQLCipher ported to Harbour (Windows)

Post by Hazael »

Rathinagiri wrote: Usually I copy openssl library files inside SQLCipher directory.
I did so but the error is still the same.
Maybe I got the wrong OpenSSL install.
I have "Win32OpenSSL-1_0_1f.exe" with 18MB but I couldn't find the so called lib "crypto"
Sorry if I am saying something unrelated or no-sense but I don't really understand the process yet.
I read some docs in SQLCiphher forum and the developer says the trickest thing under Windows is to link OpenSSL part... exact where I got stuck (but hope to go forward).

Thanks for your reply. It was pretty quick!
Harbour | GTWVT | MingW | Visual Studio Code
User avatar
Rathinagiri
Posts: 5471
Joined: Tue Jul 29, 2008 6:30 pm
DBs Used: MariaDB, SQLite, SQLCipher and MySQL
Location: Sivakasi, India
Contact:

Re: SQLCipher ported to Harbour (Windows)

Post by Rathinagiri »

Now, I am also struck up there.

This script is testing the environment and creating a MAKEFILE automatically.

Here I got libcrypto.a

http://www.wittfella.com/openssl-1.0.1c ... _mingw.zip" onclick="window.open(this.href);return false;" onclick="window.open(this.href);return false;

Even then, I could not solve the problem. Let us try to use libtomcrypt.
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
Post Reply