[Jdbc-commits] pgjdbc: Send initial connection startup parameters in UTF-8 rather than

User Jurka jurka at pgfoundry.org
Fri Sep 19 22:50:38 UTC 2008


Log Message:
-----------
Send initial connection startup parameters in UTF-8 rather than
US-ASCII.  The initial connection encoding is poorly defined as
"whatever encoding the database is in" which we don't know until
after the authentication phase is complete.  UTF-8 supports
everything ascii did and will now allow database names, user names,
and passwords to contain non-ascii characaters as long as their
database is in UTF-8, which is the most common case.

It's now easy to expose this further as a URL parameter for
initialConnectionEncoding, because MD5Digest and UnixCrypt have
been refactored to avoid having any encoding knowledge of their
own.  I haven't created a URL parameter at this point because
I don't know how many people it would be useful for and it's a pain
to expose this to the Datasource and docs and ...

Modified Files:
--------------
    pgjdbc/org/postgresql/core/v2:
        ConnectionFactoryImpl.java (r1.15 -> r1.16)
        (http://cvs.pgfoundry.org/cgi-bin/cvsweb.cgi/jdbc/pgjdbc/org/postgresql/core/v2/ConnectionFactoryImpl.java.diff?r1=1.15&r2=1.16)
    pgjdbc/org/postgresql/core/v3:
        ConnectionFactoryImpl.java (r1.16 -> r1.17)
        (http://cvs.pgfoundry.org/cgi-bin/cvsweb.cgi/jdbc/pgjdbc/org/postgresql/core/v3/ConnectionFactoryImpl.java.diff?r1=1.16&r2=1.17)
    pgjdbc/org/postgresql/util:
        MD5Digest.java (r1.11 -> r1.12)
        (http://cvs.pgfoundry.org/cgi-bin/cvsweb.cgi/jdbc/pgjdbc/org/postgresql/util/MD5Digest.java.diff?r1=1.11&r2=1.12)
        UnixCrypt.java (r1.9 -> r1.10)
        (http://cvs.pgfoundry.org/cgi-bin/cvsweb.cgi/jdbc/pgjdbc/org/postgresql/util/UnixCrypt.java.diff?r1=1.9&r2=1.10)


More information about the Jdbc-commits mailing list