Re: SSL connection between PHP4 & PostgreSQL ??? - Mailing list pgsql-general

From Mike Nolan
Subject Re: SSL connection between PHP4 & PostgreSQL ???
Date
Msg-id 200410052107.i95L7aBg031912@gw.tssi.com
Whole thread Raw
In response to SSL connection between PHP4 & PostgreSQL ???  ("Mike Morris" <mike@musicplace.com>)
List pgsql-general
> >From PHP4, how can I get the pg_connect function to negotiate an SSL connection?
>
> I gather from researching the issue that pg_connect uses the same libraries as psql, so that
> this should be possible. But I've tried every syntax I can think of... the "options" parameter to
> pg_connect is not well documented.
>
> I've played with all varieties of "requiressl" or "ssl", alone or as a boolean, e.g.,
> "requiressl=true", etc...

First, are you sure that SSL is linked into PHP?  Use phpinfo() if you're
not sure.

Second, what are you using for a connect statement?

Here's a sanitized version of one that works for me:

DB::connect("pgsql://foobar:mypassword@tcp+99.99.99.99/dbnm?requiressl=true");
--
Mike Nolan


pgsql-general by date:

Previous
From: "Mike Morris"
Date:
Subject: SSL connection between PHP4 & PostgreSQL ???
Next
From: "Joshua D. Drake"
Date:
Subject: Re: SSL connection between PHP4 & PostgreSQL ???