SSL Connection to remote DB

Creating desktop or client-server database solutions?

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
townsend
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 430
Joined: Sun Feb 13, 2011 8:43 pm

SSL Connection to remote DB

Post by townsend » Wed May 25, 2011 10:26 pm

Is it possible to establish a SSL connection to a PostgreSQL
or mySQL DB? Any references or examples would be appreciated.

jesse
Posts: 205
Joined: Thu Nov 11, 2010 6:32 pm

Re: SSL Connection to remote DB

Post by jesse » Thu May 26, 2011 2:02 pm

not fully tested but dont you just add SSL

put revOpenDatabase("MySQL",server.com,"databasename","username","password",useSSL)

From the documentation: determines whether a connection to a MySQL database uses SSL for the connection. If useSSL is not specified, the connection uses SSL. If the databaseType is not "MySQL", this parameter has no effect.

I'm beginning to wonder if the wording is backwards and it should say is useSSL is specified instead of is not specified.

I'd like to hear everyone elses feedback on this.
Deving on WinVista Home Prem. SP2 32 bit. Using LiveCode 4.6.1 Pro Build 1392

townsend
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 430
Joined: Sun Feb 13, 2011 8:43 pm

Re: SSL Connection to remote DB

Post by townsend » Thu May 26, 2011 6:13 pm

jesse wrote:I'd like to hear everyone elses feedback on this.
Me too!

Hey-- Where did you find that documentation?
There's nothing in the Dictionary for "useSSL".
Nothing in the User Guide. I even did a Google
search for "livecode useSSL". What documentation?

bangkok
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 937
Joined: Fri Aug 15, 2008 7:15 am

Re: SSL Connection to remote DB

Post by bangkok » Thu May 26, 2011 6:19 pm

jesse wrote: put revOpenDatabase("MySQL",server.com,"databasename","username","password",useSSL)

watch out. You have to put "true", not "useSSL).

From the doc : " When connecting to MySQL databases the databaseSpecificOption specifies whether to use SSL for the connection or not, the default is false"

jesse
Posts: 205
Joined: Thu Nov 11, 2010 6:32 pm

Re: SSL Connection to remote DB

Post by jesse » Thu May 26, 2011 11:22 pm

noted. thanks.
Deving on WinVista Home Prem. SP2 32 bit. Using LiveCode 4.6.1 Pro Build 1392

Post Reply