proxy problem.

Jun 26, 2014 at 6:27 AM
I have been asked to take over a project where the previous developer had used socketio4net,

hence I learnt of your project only now.

the problem my employer is facing is clients having proxy servers.

we have installed our product(client side) on clinics which uses socketio4net and websocket.
They all connect to our main azure server for sending data. In clinics without proxy,we are not facing any issues. but those with proxy server, our service is not even starting.

is there a way to set proxy server and port (like we do for webclient class in .net)?

if we have to implement the ssl process, it will be a big overhead for us .
Jun 26, 2014 at 4:30 PM
Guys, I really need help as business is being affected for this reason.

also how I upgrade to websocket? what is needed on client and server side to enable ws? the server is in node.js.

i am new to these topic and have a lot of questions unanswered at the moment.
Coordinator
Jun 27, 2014 at 2:31 AM
Edited Jun 27, 2014 at 2:32 AM
In my experience with proxies and school's in particular, the vast majority turned out to be a firewall based issue.
What port are you using, 80, 443 or something else? If that is the issue, the clinics would need to either whitelist your server ip, or allow the ip:port combo you've set.

For a quick test at the clinics that have issues - I would try these two sites (probably others sites you can find too):

http://websocketstest.com/ - tests for ports 80, 8080, 443 with and without ssl - do all or only some work?
(this site is also great for a end-user at the site to run for you, as you can get a results link - double bonus points!)

http://www.websocket.org/echo.html

Are both of the sites above able to connect?

Hope that helps...

Jim
Jun 27, 2014 at 8:12 AM
Hi jim,

Thanks for your response.

I am surre we are not using websocketss...I don't think our server is configured for ws.

our code has no knowledge of the proxy....it has the target host and port 80.

can proxy allow this to go through by just whitelisting?(iam no network admin)
my employer says they have already tried whitelisting.

in sockets, I have seen developers issue " get (resource) hostname:80" request to the proxy server itself which will forward the request and get response.

then from the proxy we read the response. is it possible here with socketio4net ? how?

we really need urgent help here.as you know its not easy to change to http classes after everything has been written.
Coordinator
Jun 27, 2014 at 4:07 PM
Even though I'm just some random guy on the internet, trust me - if you are using socket.io and socketio4net, you are most definitely using a websocket connection.
Socket.io provides the abstraction & goodness around ws, as well as fall back support (the dev version of socketio4net has long polling fallback but that's a different story).

Have you tried the above links from the sites that do not connect?
Jun 27, 2014 at 4:32 PM
Edited Jun 27, 2014 at 4:35 PM
Hi jim,

yes it was a newbie blooper. I trust you :)

the previous developer has implemented the code ..I have not spoken directly with him so far...hence my confusion on
the issue. the guys available are not full fledged developers to give me more than basic details.

I collected a few more info.

the clinics typically run squid proxy which has no support for socks4/sock5....so what does it imply for the issue?

the previous developer pointed to a socketio branch where xhrpolling is enabled to my client.

you think xhrpolling will help? is there anything to be done outside of code to ensure it works?
how can we enable it in node.js at the server?

Reg the tests, its not in my hands..as I do not have access to a live customer environment.
I have requested access.
Coordinator
Jun 28, 2014 at 1:52 AM
Firstly, there's no guarantee that websocket connections are going to work in every environment (without some fallback options or IT/network intervention). WSS/SSL might very well be just the ticket, I'm not sure - you'll just have to test & see what works best in your situation. I wouldn't see moving to WSS/SSL to be that terrible of a re-work job, but maybe in your case it is. Use the links I provided to help paint a picture of what does & doesn't work - SSL, 443 w/o cert, xhrpolling, and plan from there. You could also revisit poking a hole in proxy/firewall - maybe it was done incorrectly (I don't know much about squid proxy)?

If you have any specific questions on how this library uses events, namespaces and such, I try my best to answer those. Beyond that, honestly, it's up to you. I wish I could help solve every case - but remember, I'm just some random guy on the internet with a few OSS projects & a day job too! I wish there were more hours in the day to help, I truly do.