connect EtimedOut <proxy server>:port nodejs using axios - node.js

I am facing an issue, where I am trying to call our own application web apis hosted on azure from nodeJS using axios and getting below error:
Error: connect ETIMEDOUT :443

Related

Node js Axios Get Error: getaddrinfo ENOTFOUND

I have a code to connect to a server to get an image. It is working fine on the local host, but when I host my web app to azure and try to call the same server, I get this Error: getaddrinfo ENOTFOUND error. If I change the host name in the url to ip address, I am getting a certificate error. Any inputs would be of great help

Axios request getting network error on Expo

I have an expo mobile application running on an Android emulator and I'm trying to make a request to a local Node.js API. The request is through HTTPS protocol so I created self-signed certificates to be able to try the application.
Every time I try to make a request to the API Axios throws a Network error.
Network Error
Stack trace:
http://192.168.1.35:19001/node_modules%5Cexpo%5CAppEntry.bundle?platform=ios&dev=true&hot=false&minify=false:168381:25 in createError
http://192.168.1.35:19001/node_modules%5Cexpo%5CAppEntry.bundle? platform=ios&dev=true&hot=false&minify=false:168285:26 in handleError
node_modules\event-target-shim\dist\event-target-shim.js:818:20 in EventTarget.prototype.dispatchEvent
node_modules\react-native\Libraries\Network\XMLHttpRequest.js:600:10 in setReadyState
node_modules\react-native\Libraries\Network\XMLHttpRequest.js:395:6 in __didCompleteResponse
node_modules\react-native\Libraries\vendor\emitter\EventEmitter.js:189:10 in emit
node_modules\react-native\Libraries\BatchedBridge\MessageQueue.js:416:4 in __callFunction
node_modules\react-native\Libraries\BatchedBridge\MessageQueue.js:109:6 in __guard$argument_0
node_modules\react-native\Libraries\BatchedBridge\MessageQueue.js:364:10 in __guard
node_modules\react-native\Libraries\BatchedBridge\MessageQueue.js:108:4 in
callFunctionReturnFlushedQueue
[native code]:null in callFunctionReturnFlushedQueue
...
I tried the following:
Configuring the API IP on the mobile application as 10.0.2.2 as suggested in the GitHub issue and didn't work.
Testing the application without HTTPS, which works perfectly fine.
Testing my application on an iOS device, but it has the same behaviour as the Android emulator, it works with HTTP but it does not with HTTPS.
Accessing the HTTPS URL from the emulator's browser, which also works.
My HTTPS server is configured as follows:
const httpsServer = https.createServer(Certificate.getCertificate(), app);
httpsServer.listen(Environment.PORT, "0.0.0.0");
Logger.logInfo(`Listening on port ${Environment.PORT} under HTTPS protocol.`);
In order to create the self-signed certificates, I followed the Heroku guide

Error during WebSocket handshake: Unexpected response code: 400 on https

I am getting below error when I installed the ssl certificate for my domain. So I have changed websocket URL begin with ws:// to wss:// but I am getting this error.
I am using Amazon Linux, docker with jenkins. Backend is in Node JS. Front is Angular JS (1).
Anyone can help us on that?

socket.io-client-cpp does not connect to node app on Heroku via https

socket.io-client.cpp does not connect to node app on Heroku while Node JS socket.io-client does without any problem. Error is:
[2018-12-11 19:32:43] [connect] Successful connection
[2018-12-11 19:32:43] [error] handle_read_http_response error: websocketpp.transport:7 (End of File)
[2018-12-11 19:32:43] [info] Error getting remote endpoint: system:107
Changed URL from https to http://myapp.heroku.com - works now. Is it possible to connect via https as well? JS socket.io-client connects via secure connection without any problem.
Have built socket.io-client-cpp app with SIO_TLS in DEFINES (compiler flag: -DSIO_TLS) - connects via https fine now! This enables TLS support as mentioned here:
https://github.com/socketio/socket.io-client-cpp/pull/137

mern project deployment on live ssl

I want to deploy a mern project on ssl. Currently it is running on server with ip address but when I deploy it on ssl it is not running. It is working fine on http.
I have change on node modules transport-node and make it http to https.
1-I am using nginx as proxy server
When I deploy on ssl it give error:-
1-emitter.js?8a6f:50 OPTIONS https://privateIp:port/ net::ERR_SSL_PROTOCOL_ERROR
2-websocket.js?0f24:6 WebSocket connection to 'ws://privateip/sockjs-node/831/bocznd0p/websocket' failed: Error during WebSocket handshake: Unexpected response code: 400
3- your request is http,while it is require https.(handshake problem)

Resources