Giter VIP home page Giter VIP logo

Comments (2)

sandeepk84 avatar sandeepk84 commented on June 10, 2024

by changing the hosts file like this - 127.0.0.1 localhost abc.com I am able to start the socket server but still the client isn't able to connect. Tried with { secure: true, reconnect: true, rejectUnauthorized : false } options too. My server side configuration code looks like this:

Configuration configuration = new Configuration();
configuration.setHostname("abc.com");
configuration.setPort(10443);
configuration.setKeyStorePassword("mypassword");
InputStream stream = getClass().getClassLoader().getResourceAsStream("keystore.jks");
configuration.setKeyStore(stream);

The jks file was created for the same domain as given in setHostname. Please let me know if anything else should be done for this. Request any help.

from netty-socketio-demo.

sandeepk84 avatar sandeepk84 commented on June 10, 2024

Got the solution! I had not mentioned that the domain was set up on cloudflare. Here the issue was with
the port I used - 10443. It's not supported by cloudflare. Changed it to 8443 and it worked!

For those who come across this, please find here the list of supported ports that Cloudflare work with. May save much of your time unlike me.

Also, please note that I used my public IP as hostname so that I don't need anything added in my hosts file. Then gave the actual domain name with https on client side to connect to the server. That's it. Thank you.

Sandeep

from netty-socketio-demo.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.