I'm using Service Stack Server Event to push notification to the clients, but one customer need to host Server Stack apphost behind a Citrix Netscaler. In this scenario all connection seems to be aborted by the cliet and sse does not work.
In the post SSE with ServiceStack not working with netscaler mythz suggest to setup citrix in order to prevent the backend Server from Sending Chunked Responses.
Does anyone know if it works?
Note that if I point directly to the apphost instead of the netloader sse works perfectly.
You can use the solution that you linked, disable chunks https://support.citrix.com/article/CTX121948 or, expanding on mythz, you can use either SSL_BRIDGE or just TCP vserver and service types, so that the netscaler does not perform HTTP inspection.
The only other thing I'd add to the linked answer that could help is using SSL which would prevent deep packet inspection and potentially any interference by any middleware.
Related
I have a c# app that runs as "server" for a client app (Electron).
The c# does the data crunching and serves the data over HTTP to the JS client.
The webendpoint is implmented using Microsoft Owin and WebAPI.
It works very well, however, I do not want the port to be bound on the network interface at all, only on the "loopback".
The binding is done as described in owin docs as
WebApp.Start<MyConfig>("http://localhost:10000");
I choose a high port number to avoid being Admin.
This works well, however, the port is open from outside too, albeit, http requests from outside are rejected with bad request (which is good for me), but i dont want to bind at all.
I cant seem to find anyway to do this, any idea ?
In an attempt to utilize my web-connected security system with Home-Assistant (home-assistant.io), I did some research on it’s web interface, and it looks like it uses websockets to imitate keypad presses.
I would like Home-Assistant, which typically functions as a Websockets server itself to be able to monitor/control the security system by acting as the client(?), but it seems like all the documentation seems to show HA as the server and not as the client.
Thank You!
Have you looked at the HASS websocket documentation. You can send commands to services and also subscribe to the websocket server. This should give you the ability to talk to HASS by sending a service call to any of the registered components (such as zwave door sensors or siren). Does that make sense?
https://home-assistant.io/developers/websocket_api/
I'm able to get an unsecured FTP Client/Server system going, but when I try throwing in the SSL io handlers, setting up both apps to use sslvTLSv1, it shows Connected for the Client status then eventually times out (the only Server message I get is Socket Error # 10060).
After many trials and tribulations trying to resolve this issue, I've determined that there are serious problems with enabling a certificate-less security system; meaning that, if you want it secured (with the current Indy code), you need to use certificates. Perhaps there are some settings in the SSL component that need to be made, but there just isn't specific enough info (working examples of certificate-less SSL) to make this work. Hopefully this deadlock will be resolved in a future release of Indy ;)
I developed one application which connects to couchdb and done CRUD operations. For I have used node-couchdb plugin. So, internally it is using smtp protocal. Now my question is If I host couchdb in some other server and If run nodejs file in my system, will it connect to that 3rd party server?
Any suggestions and explanation would be appreciated.
I think you mean HTTP where you wrote SMTP (as that’s what CouchDB uses). Since HTTP is a networking protocol, it will work the way you describe. You only need the URL to the remote CouchDB and pass it into node-couchdb.
I set up a Node.js HTTP server. It listens to path '/' and returns an empty HTML template on a get request.
This template includes Require.js client script, which creates Socket.IO connection with a server.
Then all communication between client and server is provided by Web Sockets.
On connection, server requires authentication; if there are authentication cookies then client sends them to server for validation, if no cookies then client renders login view and waits for user input, etc.
So far everything works, after validating credentials I create a SID for user and use it to manage his access rights. Then I render main view and application starts.
Questions:
Is there a need to use HTTPS instead of HTTP since I'm only using HTTP for sending script to the client? (Note: I'm planning to use Local Storage instead of cookies)
Are the any downfalls in using pure Web Sockets without HTTP?
If it works, why nobody's using that?
Is there a need to use HTTPS instead of HTTP since I'm only using HTTP
for sending script to the client? (Note: I'm planning to use Local
Storage instead of cookies)
No, HTTP/HTTPS is required for handshake for websockets. Choice of HTTP or HTTPS is from security point of view. If you want to use it for simply sending script then there is no harm. If you want to implement user login / authentication in your pages then HTTPS should be used.
Are the any downfalls in using pure Web Sockets without HTTP?
Web sockets and HTTP are very different. If you use pure Web Sockets you will miss out on HTTP. HTTP is the preferred choice for cross-platform web services. It is good for document traversal/retrieval, but it is one way. Web socket provides full-duplex communications channels over a single TCP connection and allows us to get rid of the workarounds and hacks like Ajax, Reverse Ajax, Comet etc. Important thing to note is that both can coexist. So aim for web sockets without leaving out HTTP.
If it works, why nobody's using that?
We live in the age of HTTP, web sockets are relatively new. In the long term, web sockets will gain popularity and take up larger share of web services. Many browsers until recently did not support web sockets properly. See here, IE 10 is the latest and only version in IE to support web sockets. nginx, a wildly popular server did not support web sockets until Feb-March 2013. It will take time for web sockets to become mainstream but it will.
Your question is pretty similar to this one
Why use AJAX when WebSockets is available?
At the end of the day they were both created for different things although you can use web sockets for most, if not everything which can be done in normal HTTP requests.
I'd recommend using HTTPS as you do seem to be sending authentication data over websockets (which will also use the SSL, no?) but then it depends on your definition of 'need'.
Downfalls - Lack of support for older browsers
It's not used this this in many other situations because it's not necessary and it's still 'relatively new'.