Re: A solution to the SSL customizing problem
От | Ulrich Meis |
---|---|
Тема | Re: A solution to the SSL customizing problem |
Дата | |
Msg-id | 200410150648.03220.kenobi@halifax.rwth-aachen.de обсуждение исходный текст |
Ответ на | Re: A solution to the SSL customizing problem (Oliver Jowett <oliver@opencloud.com>) |
Ответы |
Re: A solution to the SSL customizing problem
|
Список | pgsql-jdbc |
On Friday 15 October 2004 05:35, Oliver Jowett wrote: >... > getSSLSocketFactory() doesn't need to be duplicated. Just pass the > connection properties to makeSSL and construct the factory from there. done > Use of SSL-specific code needs to be conditionally compiled or the > driver will not build if JSSE is not present. This is easy to do if you > move getSSLSocketFactory() into Driver.java.in. I see...it's all in makeSSL now and prefixed by @SSL@ > This doesn't look right, what is '&urlServer&'? > > > + Object[] args = { info.getProperty("&urlServer&"), > > info.getProperty("sslfactoryargs") }; In parseURL I added a line to set that property to the connection url string without parameters. It's the easiest way I am aware of to get the exact url down to makeSSL. Since parseURL simply splits parameters upon & and doesn't convert escaped &s, I used the &s to make absolutely sure that this property never clashes with a real url parameter - also that wouldn't actually matter. If nothing else, it makes it obvious that this is internal. An alternative would be to reconstruct the url via the parameters. I didn't choose that approach for two reasons: 1. A lot more lines of code 2. For implementors of a SSLSocketFactory, it would break the approach of simply comparing the received string with the original connection url provided because it might slightly differ(in case for instance). Uli
Вложения
В списке pgsql-jdbc по дате отправления: