Search Postgresql Archives

Re: Force ssl connection

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Jul 9, 2013 at 11:21 PM, Jeff Janes <jeff.janes@xxxxxxxxx> wrote:
> From your original email:
> db.setHostName("localhost");
>
> So localhost is probably matching "127.0.0.1/32" or "::1/128", which
> are explicitly allowed.

I'm using this and still able to connect without SSL

    db.setHostName("192.168.0.74");
    db.setPort(5433);
    // set requiressl=1 to enable SSL
    db.setConnectOptions("requiressl=0");
    db.setDatabaseName("testDB");
    db.setUserName("postgres");
    db.setPassword("****");
    if (!db.open())
        qDebug() << "Unable to connect!";
    else
        qDebug() << "connected.";


--
Best Regards
Muhammad Bashir Al-Noimi


-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux