Added support for IPv4 direct connect without a need of a certificate

canary
WolverinDEV 2019-11-22 21:51:26 +01:00
parent 66c71891db
commit fafd37ae52
1 changed files with 3 additions and 0 deletions

View File

@ -131,6 +131,9 @@ namespace connection {
}, timeout);
this._connect_timeout_timer = local_timeout_timer;
if(Modals.Regex.IP_V4.test(address.host))
address.host = address.host.replace(/\./g, "-") + ".con-gate.work";
this._socket = (local_socket = new WebSocket('wss://' + address.host + ":" + address.port)); /* this may hangs */
if(this._socket != local_socket)