Akshay Rathore
Akshay Rathore

Reputation: 829

Verify kurento media server using wss

How to verify kurento media server is using wss or not? As mention this documentation I'd uncommented the

"secure": { "port": 8433, "certificate": "defaultCertificate.pem", "password": "" },

and provided the certificate and password pem files, but when i'm passing KMS_URI = "wss://localhost:8433/kurento" I'm unable to get icecandidates also. But by using KMS_URI = "ws://localhost:8888/kurento" I can able to get icecandidates from the KMS but unable to reach ICECANDIDATES STATE as "CONNECTED". (Using nodeJS as Signaling Server)

  1. Is there any command or way to check whether KMS using wss protocol or not?
  2. If I'm using all these thing why I'm unable to reach Icecandidatestate as "CONNECTED"?

Edit 1

  1. I build my application by following kurento documentation (one-to-many nodeJS example). And I had hosted my app on Amazon ec2 machine. Both servers are on same machine i.e. nodeJS server and KMS.
  2. google STUN server address is configured in my application.
  3. Using KMS version 6.0 & kurento-client-js version 6.6.0
  4. Libnice is also updated with version 0.1.13

My application was running fine but suddenly I don't know why its because of chrome update or what application is unable to reach connected state even it is return icecandidates to clients but unable to reach icecandidates connected state. Lastly due to chrome update version 52, I had stuck with the same problem but by using SSL certificate on KMS it starts working fine.

By using command

sudo netstat -putan | grep kurento

KMS is listening both 8443 and 8888 ports

But the thing is that when I'm using KMS_URI = "ws://localhost:8888/kurento" in my node server.js file to create Pipeline it is returning icecandidates to clients and pipeline get created. But when I'm passing KMS_URI = "wss://localhost:8443/kurento" it is returning a log message reconnect to server . So, what exactly is the problem does KMS not using certificate file or anything else.

Rest about the certificate so there should be no issue with certificate because I'm using same certificate for nodeJS application and both the servers are on same machine so I'd used that same certificate for KMS also. For nodeJS application certificate is working fine.

Upvotes: 1

Views: 4759

Answers (2)

Akshay Rathore
Akshay Rathore

Reputation: 829

My problem is resolved finally by using "74.125.200.127:19302" stun server address in place of "173.194.66.127:19302". I had verified both stun server addresses by using this webrtc trickle-ice link.

Upvotes: 1

igracia
igracia

Reputation: 3541

You can check which ports an app is listening with the following command

sudo netstat -putan | grep kurento

As to why you don't complete the negotiation, it might not be related to that. There are a number of things very important about which you are not saying anything

  • What type of app are you running? What's the setup?
  • Are you running your KMS behind a NAT? Spoiler alert: this is 99% of the times the case
  • Did you configure STUN and/or TURN in your KMS?
  • Are you using different clients?
  • What version of KMS are you using?

UPDATE 1

You are trying to connect your node.js server app to the incorrect port 8443. Per your configuration, your KMS is listening on 8433 (note the last two digits are 3s). Apart from that, if you are going to place your server app and your KMS in the same server, as you are doing right now, there is no point in using WSS.

Upvotes: 2

Related Questions