-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can socket.io-client use https? #1233
Comments
Hi @ikuratakashi ! |
//--------------------------------------------- // socket.io-client クラス定義 //--------------------------------------------- naoetu.clsClient = function(){return this.initialize.apply(this,arguments);}; naoetu.clsClient.prototype = {
} var client = new naoetu.clsClient("https://exmple.com:99999/namespace"); |
This is important. options = { Thank you. |
@ikuratakashi It helps! ありがとうございました! |
Good reference here: |
Close ticket? |
@ikuratakashi Yes, you can. |
I don't know who are you but the only thing that I know is I love you, ikura takashi. Hontoni arigato gozaimasu. |
Example added here: https://socket.io/docs/v3/client-initialization/#Node-js-specific-options Client const fs = require("fs");
const socket = require("socket.io-client")("https://example.com", {
ca: fs.readFileSync("./cert.pem")
}); Server const fs = require("fs");
const server = require("https").createServer({
cert: fs.readFileSync("./cert.pem"),
key: fs.readFileSync("./key.pem")
});
const io = require("socket.io")(server); |
Here is full example of setup with https for those who are still searching for solution / fix |
Can socket.io-client use https?
connect does not run.
Is option missing?
The text was updated successfully, but these errors were encountered: