users@tyrus.java.net

Re: Support for Proxy in WebSocket API

From: Mark Thornton <mthornton_at_optrak.co.uk>
Date: Fri, 4 Apr 2014 12:09:30 +0100

I can't see that working for any of the more complex authentication schemes
(anything other than basic).
The proxies we have struggled with recently do not allow basic
authentication.

Mark


On Friday, 4 April 2014, Pavel Bucek <pavel.bucek_at_oracle.com> wrote:

> We recently introduced feature which allows you to modify proxy request
> headers, so then you can add auth info if required. See
> https://java.net/jira/browse/TYRUS-204 for more details.
>
> I know this is more like a workaround than ideal solution, but you should
> not be required to fallback to long polling..
>
> Regards,
> Pavel
>
> On 04/04/14 12:17, Mark Thornton wrote:
>
> Though most of the proxies we have encountered recently have been Windows
> IIS with domain based authentication (variously SPEGNO, Kerberos, NTLM) and
> a requirement to use a clients cached credentials.
>
> I have to fall back to long polling in these cases.
>
> Mark Thornton
>
> On Friday, 4 April 2014, Pavel Bucek <pavel.bucek_at_oracle.com<javascript:_e(%7B%7D,'cvml','pavel.bucek_at_oracle.com');>>
> wrote:
>
>> Hello Priya,
>>
>> WebSocket spec does not support that in any way, but Tyrus implementation
>> does.
>>
>> If you are using system-wide proxy settings (-Dhttp.proxyHost
>> -Dhttp.proxyPort), it should be picked up automatically or you can use
>> Tyrus specific approach to set it up:
>>
>> final ClientManager client = ClientManager.createClient();
>> *client.getProperties().put("org.glassfish.tyrus.client.proxy",
>> "http://**my.proxy.com <http://my.proxy.com>**:80");*
>> final Session session = client.connectToServer(...);
>>
>> if you are on WLS, the property structure is little bit different; you'll
>> need to use weblogic.websocket.client.PROXY_HOST and
>> weblogic.websocket.client.PROXY_PORT.
>>
>> Regards,
>> Pavel
>>
>>
>> On 03/04/14 23:53, priyam80us_at_gmail.com wrote:
>>
>> Does WebSocket Support setting proxy while opening up a connection with
>> WebSocket EndPoint and while establishing handshake request.
>>
>> If so can you please point me to a sample ?
>>
>>
>>
>>
>>
>